HABpanel Button "Scene" with button that is on if everything in scene is on

Has anyone created a button in HABpanel that is tied to a group of items? When you press the button, it turns on all the items in maybe a group and then the button shows an on status. If you manually turn off a light in the scene, it would break the scene and the button would now show an off status (or maybe a 3rd status would be even cooler, like maybe “partial” status). If you were to hit this scene button again, it would run through it, but only have to turn on the 1 light that is off and then restore the button to on status again.

It would also be nice if every light in the “scene” was manually/individually turned on, the scene button would change from off to on.

I believe you are just describing a Group Switch. You can define these in an items file for testing and then work up an Group Item in the UIs once you understand how they work.

1 Like
Group:Switch:AND(ON,OFF) gScene

The “AND(ON<OFF)” means the state of gScene will be ON if all the members of the Group are ON, and OFF if any one of the members of the Group are OFF.

Put this on your sitemap or HABPanel like any other Switch Item.

However, all members of the Group must be a Switch or else the AND function will not work.

If you have a mix of Item types, you will need to use a proxy Item and Rules.

1 Like

That was the ticket and I definitely looked right over that in the documentation…