Motion after sunset, what about if it's dark

Hi Guys
I have motion sensors that switch lights on after sunset however if it’s going to rain then get dark before the sun sets ?
So how do you guys deal with the dark from rain?

Thanks

I have motion sensors with illuminance. So I turn on lights when motion is detected + illuminance is below defined value.

1 Like

If the sensor has a lux value use that instead of the sun.

If you have the lux value you can monitor it and find the best value that works for you.

Then use that lux value maybe as a numerical state condition or similar.

1 Like

I’ve motion sensors with illuminance sensors, what is the threshold you are using for illuminance value.

1 Like

I use

condition:
  - type: is_illuminance
    condition: device
    device_id: 59ceff7d16833ca162d115ea4a3e3c60
    entity_id: sensor.kitchen_pir_illuminance_lux
    domain: sensor
    below: 20
2 Likes

I use an input boolean that I toggle to advance trigger my sunset lights automation. I use a number of booleans like this to either pause or start various light automations throughout our house depending on circumstances.

I also expose these to my Google Home so that I can turn these on or off without needing to pick up my phone.

I also reset these based upon certain conditions. The sunset light toggle clears when the sun sets so that everything is normal for the next day. Others will time out after a period of time. For example, I normally have my kitchen lights enabled to automatically turn out or off based upon motion. If we have guests and are eating dinner in the dining room I disable this automation for 3 hours (less if I turn it off myself).

1 Like