User Tools

Site Tools


commands:zone_commands:trigger_add

This is an old revision of the document!


trigger_add: <zone>.<variable> | <level> | string/rise/fall/both | oneshot/reset/<reset level> :: <command>

This sets a trigger on a variable

  • zone is the zone containing the variable
  • variable is the variable to have the trigger added to
  • level is the value at which the trigger will fire
  • string/rise/fall/both determines if the trigger works with strings, or if it's numeric, at which edge the trigger will fire1)
  • oneshot/reset/{reset level} is an optional field that determines what happens after the trigger has fired - if it's absent, the trigger will need to be rearmed manually; the flag “oneshot” will remove the trigger after firing once; the flag “reset” will cause trigger to go on firing every time the condition is met; placing a value in this field will require the variable to reach this value to re-arm the trigger2)
  • command is the command to be executed when the trigger is fired
1)
i.e. if it's set to fall, it will only fire if the variable's value falls past the trigger value
2)
this is to provide the option of hysteresis in a the trigger mechanism and prevent over-firing in a noisy system.
commands/zone_commands/trigger_add.1747146328.txt.gz · Last modified: (external edit)