Send Command¶
SendCommand¶
- Overview
This API function sends commands for controlling the device. This allows the user to control camera functions such as the shutter release. When stopping continuous shooting, use “CrCommandId_Release” with “CrCommandParam_Up”.
The function is asynchronous and returns to the user as soon as the SDK enqueues the requested action. The effects of sending a command can be confirmed by observing the actual device for the requested change.
- Definition
CrError SendCommand(CrDeviceHandle deviceHandle, CrInt32u commandId, CrCommandParam commandParam);
Input parameters
Type |
Explanation |
|---|---|
CrDeviceHandle |
deviceHandle |
CrInt32u |
commandId
This parameter is one of CrCommandId defined in CrCommandData.h.
|
CrCommandParam |
commandParam
This parameter is one of CrCommandParam defined in CrCommandData.h.
|
- Output parameters
None
Return value
Type |
Explanation |
|---|---|
CrError |
CrError_None If the command is sent out.
CrError_Init if the SDK is uninitialized
CrError_Generic_InvalidHandle If the deviceHandle is an invalid handle
Other than errors above, see Status code & Error
|
- Related API
- Special note (details)
Requests the SDK send a command to the device indicated by deviceHandle.
The command to send is identified by CrCommandId.