GEV_STATUS GevGetCameraInterfaceOptions

(GEV_CAMERA_HANDLE handle,
 GEV_CAMERA_OPTIONS *options);

GEV_STATUS GevSetCameraInterfaceOptions

(GEV_CAMERA_HANDLE handle,
 GEV_CAMERA_OPTIONS *options);

Description

These functions are used to obtain and update the user configurable parameters that apply to the camera connection through the camera handle. The configurable options are contained in a data structure  of type GEV_CAMERA_OPTIONS and apply only to the camera accessed through the specific camera handle.

Parameters

handle

Pointer to a GEV_CAMERA_HANDLE type to receive the allocated handle, used to access the camera.

options

Pointer to a data structure of type GEV_CAMERA_OPTIONS, allocated by the caller, that contains the parameters associated with the underlying camera handle. This type is defined as

 

typedef struct

{

      UINT32 numRetries;
      UINT32 command_timeout_ms;
      UINT32 heartbeat_timeout_ms;
      UINT32 streamPktSize;
      UINT32 streamPktDelay
      UINT32 streamNumFramesBuffered;
      UINT32 streamMemoryLimitMax;
      UINT32 streamMaxPacketResends;

      UINT32 streamFrame_timeout_ms;
      INT32  streamThreadAffinity;
      INT32  serverThreadAffinity;
      UINT32 msgChannel_timeout_ms;

      UINT32 enable_passthru_mode;
} GEV_CAMERA_OPTIONS, *PGEV_CAMERA_OPTIONS;

 

Structure Description

 

 

numRetries

Number of times a command is retried before giving up on the command and generating an error. This is to allow some tolerance for collisions and added traffic on the network interface connecting the PC to the camera. (The default value is 3)

 

command_timeout_ms

Milliseconds the library waits for a response to a command before attempting to retry the command or, if the number of retries have been exhausted, failing the command. (The default value is 2000 msecs)

 

heartbeat_timeout_ms

Milliseconds the library and camera waits for contact between the application and the camera before the camera decides that the application is unresponsive and releases the connection. (The default value is 10000 msecs)

 

streamPktSize

Size, in bytes, of the data packets used for streaming data from the camera. This value is determined algorithmically when the camera is opened and can be overridden by setting a new value using this parameter. The new value must be less than the NIC MTU (maximum transmission unit) size.

 

streamPktDelay

Time delay, in  microsecond, between packets sent from the camera. It can be used to adjust the performance of the packet streaming on busy network segments. (The default is 0).

 

streamNumFramesBuffered

Sets the number of frames that can be buffered concurrently in an internal list. These frames remain in the list until their acquisition is completed either successfully, or with some error condition caused by problems encountered during the acquisition. With a good connection to the camera, the number of frames actually being buffered at any given time is one. The default is 4. The minimum is 2.

 

streamMemoryLimitMax

Maximum amount of memory to use (puts an upper limit on the number of frames to buffer).

 

streamMaxPacketResends

Maximum number of packet resends to allow for a frame (defaults to 100).

 

 

The time, in milliseonds, that a frame is active in the internal buffering list before it is completed with a timeout error. The time is measured from the reception of the first packet for the frame from the camera. The default is 1000 ms.

 

streamFrame_timeout_ms

Milliseconds, following the reception of the start of a frame, that the API waits for a frame to be completed. If this time is exceeded, the frame is delivered to the application with the status member of the GEVBUF_HEADER structure set to GEV_FRAME_STATUS_TIMEOUT.

 

streamThreadAffinity

CPU index (0 to 1023) used to specify a particular CPU on which to create the streaming packet receive thread when running a multi-CPU system. A value of “-1” allows the thread to be created on whatever default CPU the OS chooses. A value that is larger than the number of CPUs in a system is treated as if it is “-1”. (The default is -1)

 

serverThreadAffinity

CPU index (0 to 1023) used to specify a particular CPU on which to create the high performance packet server thread when running a multi-CPU system. The packet server thread reads packets from the PF_PACKET socket interface which intercepts network data before it is written into the systems network stack. A value of “-1” allows the thread to be created on whatever default CPU the OS chooses based on its (fairly reasonable) load balancing algorithm. A value that is larger than the number of CPUs in a system is treated as if it is “-1”. (The default is -1)

 

 

msgChannel_timeout_ms

Milliseconds that the asynchronous messaging thread waits during its periodic checks for asynchronous messages from the camera. (The default is 1 second)

 

enable_passthru_mode

Zero (default) to enable automatic unpacking of packed pixel formats and decoding of TurboDrive formats.

Non-zero for passthru mode.

Return Value

GEV_STATUS

 

Possible values are:

GEVLIB_OK
GEVLIB_ERROR_INVALID_HANDLE
GEV_STATUS_NULL_PTR

Related Topics

Member Function Descriptions