hello,
sorry for the most likely simple/silly question… but as beginner I need to start somewhere no?
I have set an automation, that with a Xiaomi Zigebee switch, if I click it once, I will toggle a group of lights…
as of not, I have listed all 4 lights in the automation (should I somehow group them?) and I have the challenge that if one of them is already on, when I clink the button, I will turn on the other 3, and off the one already on…
the first thing my automation should do is: check if any of the light is on (or more that one is no, e.g. 3 out of 4) and if anything is already on (BUT not all of them!) turn all of them on… how do I do this?
below my current automation
alias: Ambient Light in Livingroom
description: ''
trigger:
- platform: device
domain: mqtt
device_id: 00071fab1dc818c6a71bc5ac931ffc6f
type: action
subtype: single
discovery_id: 0x00158d0005484270 action_single
condition: []
action:
- type: toggle
device_id: 5dbd80e13444fa17c3579c6ef749a2eb
entity_id: switch.light_1
domain: switch
- type: toggle
device_id: a5393818e2fe4fbfe43b075576bc4700
entity_id: light.light_2
domain: light
- type: toggle
device_id: 05b575f72df2faf7c360c5f0d4a84ca5
entity_id: light.light_3
domain: light
mode: single
Thank you so much