I’ve put Lifx bulbs throughout my house as a retrofit solution to smart lighting.
This means the wall switches are still used as the primary means of control for turning them on/off.
I understand that some work has been done to allow the offline/online state of things to be read by the rules engine, but I can’t find any hints on how to use this.
Ideally my sitemap/gui would reflect whether the light is off at the wall (offline), off via an app (off, but online), or simply on (on and online).
Has anyone done this with a rule/script or have any insight on how to do this? If there is a way to do this, is there an approach so I don’t have to write variations on the below rule for each bulb?
rule "item state change"
when
Item Light1 changed from ONLINE to OFFLINE
then
Light1.sendCommand(OFF)
end
Yes, you’re right. I was writing my question while trying to do a few other things at the same time.
My question still stands though. Is there a way for a rule to be fired based on the offline/online state of a thing? If there is, I think I need to look at lambda’s or functions to make a single rule apply to all the light items.