Spinnaker camera MultiFrame triggering

21 views
Skip to first unread message

Roger

unread,
Jan 25, 2026, 7:54:31 PM (12 days ago) Jan 25
to the labscript suite
spinnaker_camera.txt

Roger

unread,
Jan 25, 2026, 7:59:13 PM (12 days ago) Jan 25
to the labscript suite
I should have noted that the extra lines added were taken from the Spinnaker 4.2.0.88 Python example Trigger.py.
Trigger.py

dihm....@gmail.com

unread,
Jan 28, 2026, 7:52:03 PM (9 days ago) Jan 28
to the labscript suite
Roger,

I don't have much to add now since I haven't used a FLIR in quite some time. But my quick thought at the moment is to be mindful of changing definitions in the camera SDK. For whatever reason, camera manufacturers sometimes will alter the meaning of a setting between camera generations. It's infuriating. On a related note, sometimes camera generations change required order of operations, which is also infuriating. Looking at the code you posted, it appears 'FrameStart' may not set correctly unless TriggerMode is in the Off state. Last time I worked on FLIR cameras (many years ago), I do recall they suffered from a lot of incompatible settings combined with camera state being set instantly with every change. The result is that certain configurations would have very precise orders things had to be set in in order to prevent errors/invalid states during intermediate points.

Sorry I don't have more to add. Best of luck working out whatever is going on.
-David

Roger

unread,
Jan 31, 2026, 11:39:54 PM (5 days ago) Jan 31
to the labscript suite
Hi David,

Thanks for the advice regarding changing the order of which parameters are set in the connection table, doing so got the camera to trigger properly (without needing to use my hastily modified labscript-devices/labscript_devices/SpinnakerCamera/blacs_workers.py):

SpinnakerCamera('Camera_1',
    parent_device=PulseBlaster_0.direct_outputs,
    connection='flag 1',
    serial_number = 12345678,
    orientation = 'MOT',
    pixel_size = [3.45, 3.45],
    trigger_edge_type = 'rising',
    camera_attributes = {
        'AnalogControl::Gain':                      0.0,
        'AnalogControl::GainAuto':                  'Off',
        'AnalogControl::BlackLevel':                0.0,
        'AnalogControl::BlackLevelClampingEnable':  True,
        'AnalogControl::Gamma':                     1.0,
        'AnalogControl::GammaEnable':               False,
        'AnalogControl::SharpeningEnable':          False,
        'AnalogControl::SharpeningAuto':            False,
        'ImageFormatControl::Width':                Camera_1_ROI_Width_X,
        'ImageFormatControl::Height':               Camera_1_ROI_Width_Y,
        'ImageFormatControl::OffsetX':              Camera_1_ROI_Offset_X,
        'ImageFormatControl::OffsetY':              Camera_1_ROI_Offset_Y,
        'ImageFormatControl::PixelFormat':          'Mono16',
        'ImageFormatControl::AdcBitDepth':          'Bit12',
        'AcquisitionControl::AcquisitionMode':      'SingleFrame',
        'AcquisitionControl::ExposureMode':         'Timed',
        'AcquisitionControl::ExposureTime':         Camera_1_Exposure_Time_Buffered,
        'AcquisitionControl::ExposureAuto':         'Off',
        'AcquisitionControl::TriggerSource':        'Line0',
        'AcquisitionControl::TriggerActivation':    'RisingEdge',
        'AcquisitionControl::SensorShutterMode':    'Global',
        'AcquisitionControl::TriggerMode':          'Off',
        'AcquisitionControl::TriggerSelector':      'FrameStart',
        'AcquisitionControl::TriggerOverlap':       'ReadOut',
        'AcquisitionControl::TriggerMode':          'On'
        },
    manual_mode_camera_attributes = {
        'AcquisitionControl::ExposureMode':         'Timed',
        'AcquisitionControl::ExposureTime':         Camera_1_Exposure_Time_Manual,
        'AcquisitionControl::TriggerMode':          'Off'
        },
    saved_attribute_visibility_level='advanced',
    stop_acquisition_timeout=5)

I had also noticed that some parameters in the older GS3-U3-41C6M were either renamed or no longer present in the newer BFS-U3-31S4M, which was annoying. (FLIR also changed the gender of the Hirose connectors between the cameras...).

Roger Ding

Reply all
Reply to author
Forward
0 new messages