I have created some buttons on a flashed NS Panel to control LED strips and I’m trying to get it to work where only one pattern can be selected at a time. I have created some automations which works but it’s messy and not scalable. The automations look like this:
If button 1 is pressed then turn off buttons 2 and 3
If button 2 is pressed then turn off buttons 1 and 3
If button 3 is pressed then turn off buttons 1 and 2
Is there an easier more scalable way to achieve this?
But I don’t want a drop down? I have 6 buttons and I want them to be exclusive so when I turn 1 on the previous selected one is turned off. The same way a radio button works in HTML.
Here are the full details of what I’m trying to achieve. I have an NS Panel which I’m using nspanel-lovelace-ui on. I have a cardGrid which has 3 buttons, each of these buttons currently calls a different preset on WLED.
This service call should work a bit more efficiently. Instead of turning off all lights except the one that just turned on, it only turns off the lights that are currently on but should now be off.