Filtering Treshold helper

Hi,

I am constantly trying to improve the automatic lighting in my home.
Now I have added a few light sensors.
For easy maintenance I have made Treshold helpers for each lighting area so the lights come on as much as needed, not more or less.
So for correct working lights it is necessary to have the helpers be active (or filled) only when the lights are off.

Currently I have to fill some numeric helpers with amount lumens from light meters, on timer when the lights are off, (lights ‘on’ terminates the usability of light meters) to let a different automation toggle a binary switch. So the main automation knows whether to call a scene/script with low lights or lights on high .
It would make things easier if the treshold helper would work with conditions.

Anyone have an easier solution? (tried AI already)

Hello Dakhaas,

Well I’m not sure of an answer, but I’m not sure anyone will know if you don’t share your working code and what your goal is…
How to help us help you - or How to ask a good question.

Working code :undoable … in short: 4 main automations with about 8 triggers: pir sensors on zigbee and RF, calls on scripts and scènes depending on timers.

What I tried to do is in fact impossible. A treshold helper cannot use another helper as the source.
So the light sensor value becomes a numeric helper when the lights are turned off. Then the number is checked if above a treshold for that area and a boolean helper is set. When the area becomes ’ occupied’ , the boolean determines which scene is called.
The luminosity cannot be used straight from the sensor ; the sensor may be influenced by surrounding area lights.
If a treshold helper could be filtered, this workaround could be avoided.

It’s still not clear what you’re trying to do, but it seems like you want a threshold sensor to not update (either go unavailable or retain the last known value) when surrounding lights are on. You can do pretty much anything you want with a template sensor, and if you need it to retain state you can use a trigger-based template sensor. And trigger-based template sensors do work with conditions.

If you have a more concrete example of what you’re wanting, we can probably help.