Skip to main content

addGpioSignalEdgeMappings v6.0

Map signal edges to actions, see Actions, without replacing the other mappings in the I/O settings.

A mapping has no name, and is identified by all its fields. Adding a mapping that already exists does nothing. A new mapping only runs its action on a change of the signal after it was added, not because the signal is already in the mapped state.

A signal cannot be mapped to its own signal.<signal>.activate or signal.<signal>.deactivate action. If any of the mappings is rejected, none of them are added.

Parameter​

A mapping, or an array of mappings, each an object with the following keys:

KeyTypeDescription
signalstringSignal name.
edgestringRISING when the signal becomes active, or FALLING when it becomes inactive.
actionstringAction name, see listGpioActions.

Return value​

null

Example​

addGpioSignalEdgeMappings {"signal": "MySignal", "edge": "RISING", "action": "printer.Colorize.abort_print"}