RM 4.0 Automate locking doors

I'm having a bit of trouble with creating this rule. Within one rule I'm trying to do the things listed below. Any suggestions.

lock unlocked and door closed
delay 10 mins
lock door
notify that the door was left unlocked

lock unlocked and door open
(The lock keeps locking when the door is open)
notify that the door is unlocked and to close the door.

lock locked and door closed
(How do i tell it not to run the above actions if the door was locked immediately after unlocking?)

Something like this might do the trick. This will cancel the lock action if the lock is already locked, whether or not the door is open.

And others will not doubt come along with other suggestions. There are always more than one way to do something.

To cancel an action, first make the delayed action cancellable by turning on the "cancel" switch in the action. Note this doesn't cancel anything, it just means that the action can be cancelled. Use the "Cancel delayed actions" to actually cancel it.

Trigger:
  Lock *changed*

Actions:
  IF lock unlocked THEN
    IF door closed
      lock: lock --> delayed 0:10:00 (cancel)
    ELSE
      send notification
    END-IF
  ELSE
    Cancel delayed actions
  END-IF

Here's one of the variations I tried to do.

Delay has to be before if.

Rule has to wait 10min after you trigger, then check if door is closed and immediately lock.

In your case, rule check if door is closed and then it will lock after 10 min no matter if within those 10min you open door or not.

Did you check on in your lock's settings if auto-lock timeout is turned on? Both of my Yale locks have that feature and the locks would lock themselves after a few minutes regardless of what the hub was directing them to do.

Thanks I do have a Yale lock but it looks like its already disabled.

Thanks everyone for your advice. Here's what I have so far. If you guys see that I did something wrong let me know. Thanks again!

I will change trigger "changed" to "unlocked"

Because you don't really wanna trigger the rule if the door is already locked
and you save 50% on the processing time.

Really you wanna trigger rule only if the door is closed, That can be another trigger.

How about if somebody manually locks the door when the door is open?
If you have a deadbolt that can be a problem.

Also maybe you wanna have some announcement repeating or siren chirp if the door is open for a while.

Also sometimes is easier to break 1 complex rule to 2 separate ones.
like handling locking and announcing in 2 rules

  1. after year, you need to adjust something and read complex rule is difficult if you don't remember how you did it.
  2. if something breaks it will probably not affect all created rules. With one rule it will affect whole flow.
  3. if you ask somebody for help with easier rule more people will try to help.
1 Like

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.