Re-evaluate motion sensor status after delay

apologies if this has been covered elsewhere, but i have a particular scenario that i'm trying to work out.

My dining room lights are on a motion sensor; a fairly standard rule in rule machine that evaluates the sensor status to turn on the lights, but then turns off with different intervals depending upon whether an associated switch is on or off.

My dining room adjoins the kitchen and it is open plan, so every time i walk past the dining room while in the kitchen the dining lights come on. The obvious solution is move the sensor, but I was wondering if there's a more elegant solution that evaluates the rule the first time, then a second time after a delay - thus:

  • If motion is detected then turn on the dining lights at low level.
  • If motion sensor is still active 5s after the motion was initially detected, then raise to full brightness. (the 5s appears to be the cycle time of my motion sensors)

that way they'd still come on dim as i walk past, but would not be bright until I entered the room.

My mind is blank as to how to achieve this, so thoughts welcomed as to whether it is possible! Thanks.

I do this with my big lights in the kitchen/dining using a virtual switch. If motion stays active for 10 minutes, then the lights turn on. Otherwise just accent lighting in the room for a drink or whatever quick. I sure wish I were at home to look up the rule for you. I'll give you a description and maybe this will help to spark your imagination. If motion is active in either room, then it turns on a virtual switch. That switch toggles on and off with motion. then another rule is set to turn on the lights after a 10 minute delay if that switch is on. If it's off, then the rule cancels. It's actually pretty darn accurate overall, though it might seem like it would take a while to turn on those lights, but i have several motion sensors to detect activity in the two rooms and they all have to be inactive. I was thinking that you could do something like that for your rule?

Slightly off topic, but what motion sensors do you have that evaluate every 5 seconds?

Ah, yes - that makes sense. Thankyou. i was trying to think of a rule that would do it all, however two rules are probably the answer. One rule to put the lights on dim with any motion, and another one to go to full brightness if a virtual switch is on for more than x seconds using 'cancel delayed actions' in my resets. I'll give that a go when I get chance.

In truth it's not too far away from what i'm doing now, i guess...I think I just needed inspiration!


1 Like

I'm using a Samsung Smartthings sensor; in the logs for the sensor status changes i recall seeing instances of it going from inactive to active to inactive in 5s - which i assume is resulting from the sensor 'resetting' after losing motion.

I can report back next time i have a look.


Awh .. well I'm just a girl with a good idea from time to time. I'm glad that I could inspire you! Good luck and I'd really like to hear about what you ended up doing with the rule. My kitchen and dining rooms have the most complex setup in the house. Always lots going on there and it's always changing. I strive to NOT press a button and to NOT ask alexa for something. That was the stipulation my husband put on this hobby. Mostly, the HAF stays high if I follow that standard. (He's so spoiled)
I do have my accents brighten on motion in that room. I'll post the rules here later this evening.

1 Like

@c.j.winter here are the rules that I mentioned. This one dims the kitchen cabinet lights if there is not activity and brightens when there is. We use this automation more than the overhead lights. Unless we're doing something. Then the lights will come on after 10 minutes of activity. Here are the rules


This is the kitchen with the accents at 100%

1 Like

Brilliant, thanks - I'll have a read tonight.


1 Like