A hopefully easy automation trigger question

No need to argue. :innocent: Each solution has its pros and cons. You choose what works for you. :wink:

Anyway, I have finally fixed my HA problem (it failed to update to the latest version due to a known problem).

Here is the Yaml code for the 2 triggers, 2 conditions solution, if you choose to use it:

alias: Latest of fixed time and sunset
description: ''
trigger:
  - platform: sun
    event: sunset
    offset: '0'
  - platform: time
    at: '19:00'
condition:
  - condition: state
    entity_id: sun.sun
    state: below_horizon
  - condition: time
    after: '19:00'
action:
  - type: turn_on
    device_id: (hidden for posting)
    entity_id: light.bedroom_light
    domain: light
mode: single

I think this is it. Not actually tested because too early in the day right now. :slight_smile:

1 Like