Hi.
I was just wondering what your guys understanding of this automation is.
My understanding is that if there stairs motion sensor detects motion between 5am and 720am then the early lights scene runs. The scene should continue to run if it detects motion upto 720am. So i thought the latest the lights should be is 820am.
However they were still on later than this.
alias: Turn on lights with motion sensor
description: Turn on lights when motion is detected between 5:00AM and 7:20AM
trigger:
- platform: state
entity_id: binary_sensor.stairs_sensor_motion
from: "off"
to: "on"
condition:
- condition: time
after: "05:00:00"
before: "07:20:00"
action:
- service: light.turn_on
entity_id: light.early_lights
data:
brightness_pct: 50
- delay:
hours: 1
- service: light.turn_off
entity_id: light.early_lights
mode: restart
The lights tirned off at 08:48am