i have a automation for my lights to turn different colors while me and kids watch movies. The automation works great while we watch movies. The problem is when were done i press my aqara switch to turn it off. after a certain time they come back on on there own. any way to stop them from coming back on, on their own. Here is my Yaml: https://logpaste.com/cEYcsP8D
- repeat:
until:
- condition: state
entity_id: light.living_room_lights
state: "on"
sequence:
- service: automation.trigger
data:
skip_condition: true
target:
entity_id: automation.movie_time
Isn’t it repeat until off?
1 Like
Or make it;
repeat:
while:
- condition: state
entity_id: light.living_room_lights
state: "on"
i fixed it now
alias: Movie Time
description: ""
trigger:
- device_id: f6f3183dbaf03cfbb87479004a6f27e0
domain: deconz
platform: device
type: remote_button_double_press
subtype: turn_on
condition: []
action:
- service: automation.turn_off
data:
stop_actions: true
target:
entity_id:
- automation.night_light_after_dark
- automation.all_clear
- service: scene.turn_on
target:
entity_id: scene.movie_night
metadata: {}
- delay:
hours: 0
minutes: 3
seconds: 0
milliseconds: 0
- if:
- condition: state
entity_id: light.living_room_lights
state: "on"
then:
- service: scene.turn_on
target:
entity_id: scene.movie_night_barbie_pink
metadata: {}
- delay:
hours: 0
minutes: 3
seconds: 0
milliseconds: 0
- if:
- condition: state
entity_id: light.living_room_lights
state: "on"
then:
- service: scene.turn_on
target:
entity_id: scene.movie_night_cyan
metadata: {}
- delay:
hours: 0
minutes: 3
seconds: 0
milliseconds: 0
- if:
- condition: state
entity_id: light.living_room_lights
state: "on"
then:
- service: scene.turn_on
target:
entity_id: scene.movie_night_red
metadata: {}
- delay:
hours: 0
minutes: 3
seconds: 0
milliseconds: 0
- if:
- condition: state
entity_id: light.living_room_lights
state: "on"
then:
- service: scene.turn_on
target:
entity_id: scene.movie_night_yellow
metadata: {}
- delay:
hours: 0
minutes: 3
seconds: 0
milliseconds: 0
- if:
- condition: state
entity_id: light.living_room_lights
state: "on"
then:
- service: scene.turn_on
target:
entity_id: scene.movie_night_maroon
metadata: {}
- delay:
hours: 0
minutes: 3
seconds: 0
milliseconds: 0
- if:
- condition: state
entity_id: light.living_room_lights
state: "on"
then:
- service: scene.turn_on
target:
entity_id: scene.movie_night_orangered
metadata: {}
- repeat:
while:
- condition: state
entity_id: light.living_room_lights
state: "on"
sequence: []
mode: restart