Hi im confused and would like some pointers
How the heck do i creat a button on my dash to turn all the lights off…seems like it should be very easy - but finding it very hard
Help
Hi im confused and would like some pointers
How the heck do i creat a button on my dash to turn all the lights off…seems like it should be very easy - but finding it very hard
Help
search and you will find…
Well easy and hard, depend on how you see it.
What does it mean all lights?
Yeah, to common people that means everything that is sparkling.
But not to a computer because you can have smart light switches that can be showed as switch or as a light, smart bulbs, smart relays… If you want to do something than that something should and must be precise for computer to execute.
You can use service switch turn off and add all switches that are controlling lights ie.
You could set up a group. I have several different groups that I control with my automations. Each group you can add to a dashboard. You can do all lights, then others like all kitchen lights, all office lights, all ___ lights. Your imagination.
In fact, with building automations, I have found using groups vastly decomplicates things. If I have to replace something, I just add it to the group rather than having to think about every automation that had that certain device and address it. I just add it to the group and remove the old and I don’t have to think about it.
Like @kahilzinger I find groups to be the most flexible with this. I have multiple groups for every room and section. For instance, one group would be every light in the family room, but another is what I call “core lights”, these are only the lights that are part of automations that turn off lights because the “Entire Room” group also includes some things I may wish to leave on when I leave the room or go to bed, such as floor fans or the humidifier, things I want to be able to turn off in the “Entire Room” group on occasion. Yes, this means you have to keep groups updated as you change devices, but it doesn’t take long and the flexibility of groups negates any inconvenience or potential pitfall of trying to write “logic” to do it for you that does more or less than intended and is a constant pain to dial in.
Heh essentially what i have done
Think what i am struggling with sharptools it was easy youd group the lights togetjer then have a flow of actions, on / off / dimm etc that i could add to the dashboard as a button.
I can create the group but dont seem to / cant find many more options to do things.
Ive added the group to the dashboard as a mushroom light card, essentially only gives me the option to turn then on and off.
I really only the want the button to turn the lights off not toggle on
Not as flexible as groups but I simply use a script:
all_lights_off:
alias: All Lights Off
sequence:
- entity_id: all
service: light.turn_off
(I change light switches to lights by using the “Change device type of a switch” helper)
Yeh was looking at that, why sitches werent included as a light
2 qs if i may ask
Are there any downsides to changing switches to lights
Also where do you add the script? Is it in the config yaml file
Sorry if stupid qs i think i need to forget everything and stop think HA will operate the samw as sharptools haha
No there is not.
The script of JAS-MRS goes into scripts.yaml