#Automation trigger for "no change"
17 messages · Page 1 of 1 (latest)
from the docs:
In this example, the trigger fires if the state value of the entity remains the same for for the time specified, regardless of the current state value.
state trigger, don't specify from: or to:, and provide a for: duration
it has to start with a state change, though
states are strings
the first example here discusses for: with numeric_state triggers, if that's your question: https://www.home-assistant.io/docs/automation/trigger/#numeric-state-trigger
Ah, so the numeric state kindof converts the state to a number when needed? Is that how it works?
So your first linked (State change) will work fine for the temperature state of a temperature sensor
yes, numeric_state triggers and conditions evaluate the state as a numeric value
Ah cool, that's new info for me, never got that
states are stored as strings. A state trigger makes an exact string comparison
Thanks. Then maybe a final q... If I use this YAML (derived from UI automation)
trigger: state
entity_id:
- sensor.small_study_temperature
- sensor.big_study_temperature
for:
hours: 0
minutes: 30
seconds: 0
Is there a way to get the name of the sensor in my action? I think I can only add trigger IDs if I add each entity as a separater trigger right?
And it seems I can't use labels yet to identify entities in an automation