Update scene when lights are changed - motion lighting?

Hi folks, struggling with the logic on this one!

I am using motion lighting to control lights on/off in our living room. We have some lights we always want on, but a second set we only want on when we are reading/knitting e.t.c

We can turn the second set on manually, but if we leave the room, and it goes off, they don’t go off, and won’t come back on automatically if we come back into the room.

Basically I would like Motion Lighting to remember the state of certain lights, and restore them when it gets triggered again. I wondered if one way of doing this was to use Rule Machine to update a scene when light levels are changed, but then hit a snag, I have lights fading on/off using Motion Lighting so there’s no way to distinguish a manual change from an automated fade in/out. So, I’m a bit stuck.

Anyone got any pointers/helpful hints about how they are doing this themselves? I could probably do all of this in Rule Machine, and not motion lighting, but I am trying to keep as much stuff as possible simple and easily adjustable in the default apps.

Thanks!

Gareth

You could do some of this easily with motion lighting: add them as additional lights to turn off ("Additional switches to turn off when turned off"), and then they won't stay on after your automation turns off the "normal" lights. They won't turn on when you come back in the room if everything turned off, however. You could create an entirely separate Motion Lighting instance just for these apps and use some way to restrict the "on" and/or "off" actions to your liking--for example, a virtual switch or (real or virtual) button device. There are lots of options in ML, and you might be able to figure out something using devices that you have.

Alternatively, you could capture a scene when you leave and re-active that scene when you enter. In Groups and Scenes, there's an option to create a "scene capture" device, which gets exposed as a (virtual) button you can push from any app. I haven't actually tried this with ML, but if the "Buttons to push when turned off" option there works before your lights actually get turned off, you could probably use that to capture the scene. But then ML doesn't have an option to turn on a scene instead of turning on lights (though you could try turning on the scene device itself), so I'm not sure how well that would really work. This might be one case where a rule is easier.

I should also note that I wrote the custom app below for a similar situation. I have lots of two-bulb fixtures in my rooms but usually only want one bulb on. However, I want both to turn off, and if I had both on, leave, and come back, I want both to turn back on--effectively "remembering" the previous states. The app has grown to accommodate other user requests over the years (and I'm not sure how many people even know that I originally wrote it for that purpose), but maybe you'd be interested in checking it out, too:

1 Like

Download the Hubitat app