23
Event identification
When an event is notified to the application, the callback function that is executed indicates
the category of that event. The actual event that occurred is identified by a numerical ID, called
numid
, and defined in
include/GenTL_v1_5_EuresysCustom.h
:
enum EVENT_DATA_NUMID_CUSTOM_LIST
{
// EVENT_CUSTOM_IO_TOOLBOX
EVENT_DATA_NUMID_IO_TOOLBOX_LIN1
= ...
/* Line Input Tool 1 */
EVENT_DATA_NUMID_IO_TOOLBOX_LIN2
= ...
/* Line Input Tool 2 */
EVENT_DATA_NUMID_IO_TOOLBOX_MDV1
= ...
/* Multiplier/Divider
Tool 1 */
...
// EVENT_CUSTOM_CXP_INTERFACE
...
// EVENT_CUSTOM_CIC
EVENT_DATA_NUMID_CIC_CAMERA_TRIGGER_RISING_EDGE
= ...
/* Start of camera
trigger */
EVENT_DATA_NUMID_CIC_CAMERA_TRIGGER_FALLING_EDGE
= ...
/* End of camera
trigger */
EVENT_DATA_NUMID_CIC_STROBE_RISING_EDGE
= ...
/* Start of light
strobe */
EVENT_DATA_NUMID_CIC_STROBE_FALLING_EDGE
= ...
/* End of light strobe
*/
...
// EVENT_CUSTOM_DATASTREAM
EVENT_DATA_NUMID_DATASTREAM_START_OF_CAMERA_READOUT = ...
/* Start of camera
readout */
EVENT_DATA_NUMID_DATASTREAM_END_OF_CAMERA_READOUT
= ...
/* End of camera
readout */
...
};
For reference, the following tables list, for each module generating events and for each category
of events, the relationships with:
n
the name of the callback function
n
the data type passed to the callback function
n
the common
numid
prefix
A simple naming scheme is followed: a category of events named
some category
has a
callback function named
on
SomeCategory
Event
which takes as argument a
SomeCategory
Data
structure, and uses
EVENT_DATA_NUMID_
SOME_CATEGORY
_
as common
numid
prefix.
Callback function
Data type
numid
prefix
onNewBufferEvent
NewBufferData
-
Data stream module – New Buffer category
There is only one event in the
new buffer
event category, so we don't need a
numid
there.
5. Euresys::EGrabber
Coaxlink
Programmer Guide