When switching from the basic automation blueprint to one with a sun condition, lights are not switching off anymore. Lights are KNX and sensor is Homematic
mode: restart
max_exceeded: silent
trigger:
platform: state
entity_id: binary_sensor.bewmelder_auffahrt
from: 'off'
to: 'on'
condition:
- condition: or
conditions:
- condition: sun
after: sunset
after_offset: 60
- condition: sun
before: sunrise
before_offset: 45
action:
- service: light.turn_on
target:
entity_id:
- light.lampe_auffahrt
- light.lampe_aufgang
- wait_for_trigger:
platform: state
entity_id: binary_sensor.bewmelder_auffahrt
from: 'on'
to: 'off'
- delay: 120
- service: light.turn_off
target:
entity_id:
- light.lampe_auffahrt
- light.lampe_aufgang
id: '1641295954243'
alias: Lampen Auffahrt durch BewMelder
description: