Introducing Randomness?

Hello,

I’m trying to wrap my head around the PLEG logic that would be needed to have each light in my home randomly turn on and off within a set period of time (similar to the de-appreciated Vacation Ghost plug-in).

Would I need to create a separate condition for each light I would want to turn on and off random? For example:

[ul][li]C1KitchenLOn (Repeat): !tKitchenL AND sVacation AND sEveningRandom AND sIntervalRandom[/li]

[li]C2KitchenLOff (Repeat): tKitchenL AND sVacation AND sEveningRandom AND sIntervalRandom[/li][/ul]

Then rinse and repeat for every light I want randomized within this period (e.g. swap out KitchenL for LivingL)? Is there anyway to combine the logic so I can tie everything into one condition that randomly turns on individual lights? The best method I’ve found so far for that is to use Vera’s built-in delays but that makes the pattern of lights turning off obvious (e.g. Kitchen turns off first, then Library, then Bedroom). I’d like each light to be independently random within a 3 hour period to simulate the movement of people inside.

We just worked on this a few weeks back. See: http://forum.micasaverde.com/index.php/topic,33254.15.html

You would likely need separate “random” timers for each light…

wilme2, thank you for responding. I was afraid that might be the case. At least I only have 7 lights to do. I can reuse the random interval timer but I was hoping to avoid creating two conditions for each light in my home. =)

@wilme2, did anyone pull together a complete PLEG that defines, triggers, timers, conditions and actions? Looking at the thread I see parts only…

[quote=“wilme2, post:2, topic:188678”]We just worked on this a few weeks back. See: http://forum.micasaverde.com/index.php/topic,33254.15.html

You would likely need separate “random” timers for each light…[/quote]

for us, we have a lot of lights controlled by motion sensors. Is there a way to fire off a motion event? Then you could call a random event to trigger motion and that would handle turning the lights on/off automatically.