Basler Vision Connector Messaging: Setting Camera Parameters#
You can define enumeration parameter types using human-readable values. For example, you can set the pixel format using the Mono 8 value instead of the enumeration integer value.
For string and integer parameters, the Basler Vision Connector expects an exact match for the set value. For float parameters, a difference of no more than 1 % is allowed due to floating-point comparison. If the provided value is outside the expected range, the setting call returns an error.
The list of set values is returned in the response message.
The SetParameters
command is allocated to one of the following node maps:
@CameraDevice -> CInstantCamera::GetNodeMap
@CameraInstance -> CInstantCamera::GetInstantCameraNodeMap
@DeviceTransportLayer -> CInstantCamera::GetTLNodeMap
@StreamGrabber0 -> CInstantCamera::GetStreamGrabberNodeMap
@EventGrabber -> CInstantCamera::GetEventGrabberNodeMap
If no node map is defined, the @CameraDevice
default node map is used. This node map represents the camera parameters. All other commands only operate on the @CameraDevice
default node map.
The syntax for using the node maps is as follows:
For an explanation of node maps, see the pylon API documentation.
You can find documentation about the available node maps at:
- @CameraDevice or in your camera documentation
- @CameraInstance
- @DeviceTransportLayer
- @StreamGrabber0
- @EventGrabber
JSON Payload#
Field | Optional | Type | Description |
---|---|---|---|
TransactionID | Yes | String | Transaction identification |
Action | No | String | Method called. Fixed value: SetParameters |
DeviceID | No | String | Device identification |
ParameterList | No | Parameter Object Array | Object to encapsulate the parameters to be updated |
Parameter Object#
Field | Optional | Type | Description |
---|---|---|---|
Name | No | String | Unique parameter name |
Valuea | No | String/ Integer (64-bit signed)/ Float/ Bool | New value |
-
On enumerations, it can be the integer value or the symbolic name. See Retrieving Parameter List for further information.
{
"TransactionID": "123567",
"Action": "SetParameters",
"DeviceID": "548451887",
"ParameterList":[
{"Name": "@CameraDevice/Width", "Value": 800},
{"Name": "Height", "Value": 600},
{"Name": "PixelFormat", "Value": "Mono8"} //Setting using the human readable string. This could be also the correspondent enum integer.
]
}
Response Object#
Field | Optional | Type | Description |
---|---|---|---|
TransactionID | Yes | String | Transaction identification |
ReturnCode | No | Integer (32-bit unsigned) | Message code following Message Codes |
Message | Yes | String | Response message |
ParameterList | No | Parameter Object Array | Object to encapsulate the parameters to be updated |
Parameter Object#
Field | Optional | Type | Description |
---|---|---|---|
Name | No | String | Unique parameter name |
Value | No | String/ Integer (64-bit signed)/ Float/ Bool | New value |