Quantcast
Channel: Configuration - Home Assistant Community
Viewing all articles
Browse latest Browse all 106727

Scene runs in the morning; sometimes one light fails to turn on

$
0
0

Hi, I have a morning scene that turns on 3 Hue bulbs via a scene. Sometimes (once a week usually) one of the lights fails to turn on. I was hoping to have a check 1 minute after first activating the scene to see if any of the bulbs are off, and if so run the scene again.

Now I know what you’re going to say – just activate the scene again in 1 minute if the lights are flaky, which I will probably end up doing.

But since HA is fairly new to me I’m also learning about conditions and wondering why this particular one doesn’t work. I think it’s because it’s part of an action, but not sure. It won’t save the script properly when trying to use this code:

alias: 'Daily timed events: Morning lights on'
description: ''
trigger:
  - platform: time
    at: '05:30:00'
condition: []
action:
  - scene: scene.kitchen_island_fun
  - delay:
      hours: 0
      minutes: 1
      seconds: 0
      milliseconds: 0
  - condition:
    alias: "Check if any island lights failed to turn on"
    condition: or
    conditions:
      - condition: state
        entity_id: light.kitchen_island_left
        state: off
      - condition: state
        entity_id: light.kitchen_island_center
        state: off
      - condition: state
        entity_id: light.kitchen_island_right
        state: off
    - scene: scene.kitchen_island_fun
mode: single

I think it’s related to the “OR” condition but I’m not sure. Hoping for some tips here, thanks!

Dennis

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 106727

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>