Automation API - DigitalTriggerCaptureMode

Hello all,

I try to setup a triggerd data capture, but when I configure the capture like this:

 capture_configuration = automation.CaptureConfiguration(
        capture_mode=automation.DigitalTriggerCaptureMode(trigger_channel_index=1, 
        trigger_type=RISING, after_trigger_seconds=200e-6)
    )

i get this error message:

   capture_mode=automation.DigitalTriggerCaptureMode(trigger_channel_index=1, trigger_type=RISING,
                        ^^^^^^
NameError: name 'RISING' is not defined

Any help is appreciated.

Kind regards
Jens

Try using DigitalTriggerType.RISING instead of just RISING as the automation API documentation for DigitalTriggerCaptureMode.trigger_type:
https://saleae.github.io/logic2-automation/automation.html#saleae.automation.DigitalTriggerCaptureMode.trigger_type

… says:

trigger_type: DigitalTriggerType
Trigger type is RISING, FALLING, PULSE_HIGH, or PULSE_LOW, from the DigitalTriggerType enumeration.