I recently acquired the FP2 sensor and I’m looking to set up dynamic lighting adjustments based on different scenarios. Specifically, I want the lights to:
**Neutral Brightest ** when someone is seated at the table.
Dim when everyone is on the sofa.
Brighten when someone is walking…
To achieve this, I need the lights to return to a neutral state after making these adjustments. Additionally, I want to retain the ability to adjust the lights using other apps like HomeKit.
My initial thought was to use template lights for each individual light, but this approach would require numerous helper values and could become quite complex to maintain.
Is there a more efficient method to implement this? Essentially, I’m looking for an easy way to create individual virtual lights without the overhead of managing multiple helper values.
Any suggestions or best practices would be greatly appreciated!
You will have to use the aqara app to do this. What I do is have zones mapped out as occupancy sensors for couch and table (different FP2s in kitchen and living room). When someone enters the living room lights go on to low ambient levels. When someone sits on the couch the overhead cans above the couch are brightened.
When someone enters the kitchen lights go on to normal. When someone sits at the table the fan light above the table turns on to max brightness.
I have reverse automations for when couch clears - back to ambient, wait for room to be clear for a couple minutes then all off. When table clears, wait a minute and fan light off. Kitchen clears for a couple minutes then all off.
I did that before. But it’s lacking the flexibility since you have preset scenes for the zones and occupancy. I wanted to keep the ability to modify the lights on the run. I made a node red script for it, but it’s not perfect. it uses changes in lights while no automation is running to register changes in “normal” mode (brightness when someone at Tagle or sofa…). but its not stable enough.
No reason you can’t modify the lights at any time (from HA or HK). They won’t change until occupancy of the zone changes and at that point wouldn’t you want them to?
well. not necessarily. if I wanted to change the lights to a dimmer light ( when watching TV), then someone gets up we are back to the light we had before. What I did before is to have a scene input select helper for each zone, you could then select if you wanted dim bright or medium light. but this required 3 sub scenes(someone at sofa, no one at sofa, someone walking in living room). so with 2 zones I had to manage 18 sub scenes scenes and 3 main scenes. I might be overthinking this, but I guess that’s a part of the home assistant experience. then I thought being able to set the nominal/normal brightness and then have a script that adjusts the light would be simpler. but it seems to be hard to do it in a way that keeps it adjustable.
Ok, working though what you said - watching TV, change lights to a dimmer level manually (why are you manually changing light levels?!)…Occupancy at couch (assumed) is unchanged if someone leaves unless you are alone then yes, reset to no-couch-scenario.
If walking in living room this is just basic the “still-occupied-room” zone unless you set up a separate zone for the “walking zone” as a different occupancy zone from “room is occupied” zone. I think your hang-up is trying to set a manual light level amid your automations.
Find a way to make your movements and occupancy of the space the determinant factor in what your automations do. I haven’t touched a light switch in a few years - the lights do what I want based on how I live.
In my setup, I have multiple TV scenes, such as Movie Mode and Casual Watching. For instance, when Movie Mode is active, I prefer the table lights to switch to a dimmer, unoccupied setting, and the TV occupied setting to be dimmer then the Casual Watching setting . If someone stands up during a movie, I’d like the brightness to increase from 20% to 40% instead of reverting to the standard 70% used in regular mode. To accomplish this, I had to create sub-scenes for each mode, which became quite complicated and difficult to debug.
Having the ability to adjust the lights on the fly would offer much more flexibility. Im using input helper to control the brightness increments (e.g., +10%, +20%) in Node-RED. This way, I can still set scenes and adjust lights manually as needed. This approach is particularly beneficial for household members who aren’t deeply involved with Home Assistant. For example, my girlfriend often crochets on the couch while watching TV and prefers a higher light level than usual.
I think your hang-up is trying to set a manual light level amid your automations. Yes this is one of the hangups. I added a flag that disables manual overrides for 2 seconds after an automation is triggered but there’s more issues…
The only way to make it truly bullet proof is to have “Virtual lights” that I can set from the app, the wall mounted switches, and HomeKit/siri. And have node red read the values from there and adjust increments based on the input select. But Making 15 template lights and helpers for(brightness, Hues, colour) for all of them seems like to much boiler plate.