Help with resetting Rule

I need help with a Rule....maybe. This rule has been working great for months. What I have found and I'm sure it has always been this way is, If the door is closed the rule will wait 3 mins and check to see if the door is still closed. If so, lock door. Now what I just found the other day is, if door is closed and timer is set for the 3 mins and someone opens the door within the 3 min delay and closes again, The timer is NOT reset. It will lock with how many mins are left from the first delay.

How can I get the timer to reset with the second door close?

I would think you'd want a cancel on truth change then the open would cancel the first execution and the second close would start the new timer.

@Terk That's the part I'm trying to figure out how to do.

Edit the delay and there should be a cancel option

@Terk I don't see this option

Did you make that rule a while back or are you running an old firmware? You should see that option with RM 3.0 and higher

Running Rule Machine 4.0

Do you think this would work?

I believe you have to select the cancel toggle on the delay. also add ELSE IF Door Contact Door Open "Cancel Delayed Actions"

You would also need to change your trigger from "closed" to "changed"

Something like this I think would work

Ok what about something like this.

Changed

I think that would only keep the door from locking if your door is open when the 3 minute time is up. Have you tried another browser to see if the cancel option is available?

Yes. I don't want my door to lock if it's open.

Here's what I'm thinking this will do.

If the door opens (Changed from closed) the action is > If Door is open the Stop...do nothing.
If the door is closed (Changed from open) Delay 3mins and lock door.

Maybe I'm wrong... Lord knows I'v been wrong before on this stuff. I will test this when I get home.

Yeah that stop might get you what you want, haven't used that before.

Me Either... Not really sure what or how the STOP works yet.

Here's what the Docs say about Stop Action

Stop Actions
This action causes delayed, or repeated Actions to be cancelled, Periodic triggers and Fade Dimmer over Time are also cancelled.

1 Like

Ok just tested and seems to work.

Stop action will stop the timer. All is good

Glad it worked, nice to learn a new feature too.