habean
January 22, 2017, 1:03pm
1
Please add the “for” option to the numeric state condition similar to the state condition . This would enable automations based on the duration time of certain values. For instance: “Turn off the device if it has consumed more than 100W for more than 10 minutes.”
Thank you!
You can use a template sensor instead
habean
January 22, 2017, 1:23pm
3
I will try the template sensor, but for this simple automation it will make the configuration more complex compared to the for option.
rpitera
(Robert Pitera)
January 22, 2017, 2:46pm
4
This is a duplicate of:
Would be great to trigger an automation if the numeric state has been above a value for a given time, like it is possible for the state-platform
For state trigger the following is valid:
automation:
trigger:
platform: state
entity_id: device_tracker.paulus, device_tracker.anne_therese
# Optional
from: 'not_home'
to: 'home'
# If given, will trigger when state has been the to state for X time.
for:
hours: 1
minutes: 10
seconds: 5
Is would be nice …
Please add your votes and comments there. Will be closing this thread.