#How to add multiple entities to button card

1 messages · Page 1 of 1 (latest)

misty bolt
#

want 1 button to turn on/off all my lights but cant seem to figure out how to add multiple entities/scripts to 1 card

chilly zenith
#

you only get one entity/action

#

To do more you make a script, and then call that script

misty bolt
#

so i have to create more scripts to do everything?

chilly zenith
#

correct

misty bolt
#

thats sad lol

#

wonder why u cant just have button card accept multiple entities

chilly zenith
#

well you can make 1 action with multiple entities

#

that will work

storm compass
#

you can make a template button that calls the action

misty bolt
#

whats the easiest way to make a button that can turn on 2 smart switches lol

chilly zenith
#

The entity in the button card defines the state of the UI for the button, it wouldn't make sense what to do if there were multiple entities

#

Set entity to none, set the tap action to perform action, swtich.turn_on, and add both entities as the target

misty bolt
#

i tried that cant find my switches in targets

chilly zenith
#

Are they switch entities, or an input_boolean?

misty bolt
#

switch

chilly zenith
#

show a screenshot please

misty bolt
#

hold on might have wrong action

#

i selected toggle but maybe its something else

chilly zenith
#

yes it must be the switch version

misty bolt
#

hmm doesnt sow up with toggle switch either

#

its a smart dimmer switch

chilly zenith
#

is it a light then?

misty bolt
#

yes

chilly zenith
#

then use light.turn_on

storm compass
#

switch.turn_on is limited to switches, if you make the dimmer show as a light, then it won't show up as a switch any more

misty bolt
#

ah theres a toggle for "light" aswell

#

so many toggle options it controls a light but it is a toggle switch so very odd

chilly zenith
#

any dimmable switch is implemented as a light, switch domain is strictly for undimmable on/off

misty bolt
#

ok next issue how do i add run multiple scripts?

#

no button to add another one

chilly zenith
#

correct, only one, as I said

misty bolt
#

so i need to make a script to run these 2 scripts and use that?

chilly zenith
#

If you want to do light.turn_on and something else, then yes you make one script, which calls light.turn_on and then does the other thing

#

then you call that script on tap

misty bolt
#

no tap is on/off toggle , double tap needs to run 2 scripts which puts the lights into night mode

#

and i need a hold to do brightness but havent got that far

chilly zenith
#

For double tap, click the "Add Interaction" button

misty bolt
#

basically i need it to run exactly like the normal button for each light but control both

chilly zenith
#

it may be easier to just make a group of lights

misty bolt
#

ya i have double tap but u cant run 2 scripts

misty bolt
#

i just wanna be able to control all my lights at once or individually

storm compass
misty bolt
#

have to start from beginning idk where helpers is

#

im on main screen

#

nvm search bar worked

storm compass
#

main screen -> settings -> devices etc -> helpers -> create helper -> group -> light group

misty bolt
#

oh thats perfect

#

now just need to make a script that calls multiple scripts

#

is there a way to make it not wait on last script to finish before exectuting the next script?

#

figured it out

#

there now to add the rest of the 3 switches for the other 3 rooms lol

#

@storm compass there a way to set turn on brightness, its defaulting to 100% i want 1%

#

or do i have to make a script for that

storm compass
#

you can set it in the light.turn_on command, but not light.toggle iirc

misty bolt
#

works in seperate script