Light card configuration

light.led_light is a Smart LED light which is connected to a smart switch ‘switch.1000cd3449_1’. If the switch is OFF, the LED light should be off too. But, this light card’s state is always ON even the switch is off.

Can i put a condition coding in the light card configuration? if switch.1000cd3449_1 is off, then light.led_light will be off.

How to do it?

That’s weird. It should be ‘unavailable’ not ‘on’ if there is no power to the smart light.

Probably best to create a template light and show that in the frontend:

There is no power supply to light.led_light
Can u find any problem here?

It’s a group of lights. That’s not the same as

If any member of the group is on the group will be on. If any member of the group is available the group will be available.

You see the yaml file, i have grouped 2 lights. These 2 lights are always working together, meaning both of them will ON or OFF at the same time. This grouped light will be turned on if switch.1000cd3449_1 is ON because switch.1000cd3449_1 is the power source. Once switch.1000cd3449_1 is OFF, meaning no power supply to the 2 lights.