Hi. I know there are many topics on lights on/off randomly, but I haven’t come across any that I can build off of to achieve what I would like and I would like your take on the task. Here’s what I want:
I want all lights in a zone to turn on within 45 min after sunset (a). One light should turn on within 5 min of the sunset (b), the rest may or may not turn on at the latest 45 min later (c). This means that different lights tun on at different times within 45 min after sunset. Some might not turn on. At least 1 should turn on (d). The number of lights may warry, so the programming should be dynamic (adress all available lights in the zone at any time).
My first attempt on pseudo code would be something like this:
a) for each zone to automate
b) Put all available lights in an array/collection
Randomize if each light should turn on
Randomize individual delays between 5 - 45 min
Loop over and identify
c) The one which turns on first, randomize a new "on" time between 0 - 5min
If none is randomized to turn on, randomize one to turn on, randomize when between 0 - 5min
Schedule to turn on the lights according to delays
Or maybe the developer (@LRvdLinden who is very productive with new apps) is willing to help you with specific needs in this app, or a spin-off from this app in a new app (Security lights app…??).
@mrPilloft As @Torch1969 mentioned, you can try Party Lights. If this is not close to your needs, let me know. Maybe I’ll build it in or in a separate app.
Programming your lights to randomly turn on and off, even with some scheduled idea behind it to scare away burglars is a dumb idea imho. Many people program stuff that just doesn’t make sense at al. Like turning on the lights after sunset and leaving them on all night. Who in the world leaves their lights on at night when you are home and sleeping? If where a burglar and come across a house where the lights go on randomly some time after sunset and then stay on the entire night, i definitely pick that house as a target!
What I instead suggest is to just record the light conditions of all the lights for the week before you leave, and then use that schedule for the duration of the holiday.
Btw, that shot from home alone displays perfectly how idiotic these ideas are anyway. If you’ve seen the movie, you know perfectly well that burglars just post out the neighborhood for a while, and if they see anything that just isn’t making sense to them, they’ll go in anyway!
When no one’s home, it turns on automatically after dark, creating a realistic light pattern that mimics someone watching TV. And yes, I leave it on all night. I’m confident no burglar will think, ‘Hey, that’s a fake TV because it’s 4 AM.’ Instead, they’ll probably assume someone has insomnia or works night shifts.