I would like to set a “scene” triggered by a dashboard button, more precisely:
Set a Hue scene (“bright”)
Turn on the wardrobe light (regular switch)
I can achieve this with an automation, which is bound to a hardware button, no issues. But somehow, I am to stupid to do the same from the dashboard.
I tried two approaches:
Trigger the automation
I added the entity representation automation “Set bright”, which would achieve the two things above. However, the automation is not triggered when I press the dashboard button. Also the button has an “on/off” state then, which does not make sense in this variant.
Create a Home Assistant Scene
This would be my preferred variant, as it seems very clean and in the existing automation, I could then just set the same scene. However, I could not figure out how to set a Hue scene as part of a scene. Is it true that I can set details of a scene in Yaml only?
Thank you. This shows how to activate a scene, but it does not really solve my issue or am I missing something? I use exactly this in other rooms, where I have Hue lights only and therefore can only set a scene, but as I tried to describe, I have to control a switch, too.
Just create a script (not an automation) and call your actions there. Then, from your dashboard button, just call the script. As for your button, you’ll probably want to use a Tile instead as it can be set to be momentary.
As for your Hue scenes, you can just call it using the scene.turn_on service like any other scene. You cannot use scenes within scenes though (that was removed from HA a long time ago). But, you can create a script that will call scene.turn_on multiple times, thus giving the illusion of a single scene.