trigger power state

trigger power state Structure: Trigger when the source of power changes.

trigger power state structure

Description

The trigger will fire when a power source's state changes. This change will occur when one of the power source's switches to AC/mains supply, to battery, goes off-line, or is disconnected.

There may be multiple power sources. The trigger can filter which power source's can trigger using the name field as a filter. By providing a previous and now state, the trigger can further filter the power source changes that initiate the trigger.

A trigger without either a before or now state, will trigger whenever the power source state changes. A trigger with one or both the before and now state, will trigger only when those values are matched by the changing power source's state.