Sleep Sensor flow options

Hello, another new node-red user here. I've been puzzling over how to solve a problem that drove me to using node-red in the first place. For what it's worth, I'm using node-red with Hubitat. So, here is what I'm trying to accomplish:

My wife works very early in the day and I'm a night owl. So, she goes to bed early. We each have Withings Sleep Sensors (which I've had no problem integrating into both Hubitat and node-red), which return a value based on "present" or "not present." Our bedroom has a Hue motion sensor (also integrated into Hubitat) to turn on the lights whenever anyone walks into the bedroom. What I'm trying to do is disable that sensor (so the lights don't come on) if either she or I are in bed.

I'd also like to have other automations happen if we're both in bed, if one of us gets out of bed, or if we both get out of bed. I've been trying to use Boolean Logic Ultimate to do this and it works for the and / or functions, but the way I have it set up is sloppy and I feel like there must be a more elegant solution. Any hints or tips would be much appreciated.

Why do you feel it is sloppy? In my mind, the best code is the code you will easily understand when you haven’t looked at it in a year.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.