Event Action Configuration (0x0C,0x2F)

Description

Configures various types of event actions.

Notes
Parameter Name Data Type Description
Field Length u8 6
Descriptor u8 0x2F
Function Selector u8 This command supports the following MIP function selectors:
Write Read Save Load Default [WRSLD]
Instance [WRSLD] u8 Action number. When function is SAVE, LOAD, or DEFAULT, this can be 0 to apply to all instances.
Trigger [W] u8 Trigger ID number.
Type [W] u8 enum Type of action to configure.
NameValueDescription
NONE0No action. Parameters should be empty.
GPIO1Control the state of a GPIO pin. See GpioParameters.
MESSAGE2Output a data packet. See MessageParameters.
[W]
Ack/Nack Reply See standard MIP ack/nack reply format.
Response Data Data Type Description
Response Length u8 5
Response Descriptor u8 0xB9
Instance u8 Action number. When function is SAVE, LOAD, or DEFAULT, this can be 0 to apply to all instances.
Trigger u8 Trigger ID number.
Type u8 enum Type of action to configure.
NameValueDescription
NONE0No action. Parameters should be empty.
GPIO1Control the state of a GPIO pin. See GpioParameters.
MESSAGE2Output a data packet. See MessageParameters.

Structures

GpioParams

Description

Parameter Name Data Type Description
Pin u8 GPIO pin number.
Mode u8 enum Behavior of the pin.
NameValueDescription
DISABLED0Pin state will not be changed.
ACTIVE_HIGH1Pin will be set high when the trigger is active and low otherwise.
ACTIVE_LOW2Pin will be set low when the trigger is active and high otherwise.
ONESHOT_HIGH5Pin will be set high each time the trigger activates. It will not be set low.
ONESHOT_LOW6Pin will be set low each time the trigger activates. It will not be set high.
TOGGLE7Pin will change to the opposite state each time the trigger activates.

MessageParams

Description

Parameter Name Data Type Description
Desc Set u8 MIP data descriptor set.
Decimation u16 Decimation from the base rate. If 0, a packet is emitted each time the trigger activates. Otherwise, packets will be streamed while the trigger is active. The internal decimation counter is reset if the trigger deactivates.
Num Fields u8 Number of mip fields in the packet. Limited to 12.
Descriptors u8[num_fields] List of field descriptors.