Hi, I was wondering if someone could help me understand how to get the light to only trigger and Sunset, and stay off during sunrise? I have tried adding Condition, but I’m not sure why it does’t trigger.
I have two seperate automation for On/Off, and I’d prefer if it was possible to condense into a single automation, and be compatibile with the UI.
Light On:
alias: WC On
description: ''
trigger:
- platform: state
entity_id: binary_sensor.wc_motion
to: 'on'
for:
hours: 0
minutes: 0
seconds: 0
milliseconds: 0
from: 'off'
condition: []
action:
- service: light.turn_on
target:
entity_id: light.wc_light
data:
brightness: 255
mode: single
Light Off:
alias: WC Off
description: ''
trigger:
- platform: state
entity_id: binary_sensor.wc_motion
to: 'off'
for:
hours: 0
minutes: 0
seconds: 10
milliseconds: 0
condition: []
action:
- service: light.turn_off
target:
entity_id: light.wc_light
mode: single