Ring motion notification only if front door unlocked


#1

1) Give a description of the problem
I want to be notified about the motion that is detected by my ring doorbell, but only if the front door is locked.

2) What is the expected behaviour?
See above, but I have a smart lock that when unlocked, I do not want to receive motion notifications from ring. When locked, I want to receive notifications.

3) What is happening/not happening?
I am about 50-50 success rate on this working. About half the time, it works as expected, but the other times, I think the ring motion alert is being sent before the Lock gets registered as being unlocked. Then it sends the notification. My kids have odd work schedules so they come and go at different times, and I donā€™t need to know or be alerted when they leave. So I figured if I only alert when the door is unlocked, that would be better.

It is also possible that they are pressing the lock button from the outside when closing the door (setting locked = true), and then the Ring is again detecting motion, which is causing the notification.

I was wondering if there is a way to test against ā€œif the door was unlocked in the last X seconds, then donā€™t send the alertā€, and what would that look like?

**4) Post a Green Snapshot of the piston![image|45x37]


5) Attach logs after turning logging level to Full
OK - so I edited the piston after it not working correctly, so donā€™t at the moment have a log example of it not workingā€¦ I can update later if neededā€¦


#2

I know thereā€™s the ā€˜stays lockedā€¦ā€™ condition you can use but Iā€™m not sure if itā€™s reliable. Thereā€™s also the age() function where you can check how long the lock has been in that state in milliseconds. Something likeā€¦

age([YourLock:lock])

Hereā€™s an example from the eval console:

(expression) age([sim Lock:lock]) Ā»Ā»Ā» (long) 30317609402
(expression) formatduration(age([sim Lock:lock])) Ā»Ā»Ā» (string) 350d 21:33:40

Maybe something you can use in your condition.


#3

Thanks, Rey - maybe I am not advanced enough with WebCore, but I am not sure what to do with the info you posted - any way you could spoon-feed it a little more, please? I am going to go play with the ā€œwasā€ and ā€œstaysā€ options a bit too, thoughā€¦


#4

I was thinking something like thisā€¦ 60000 is 1 minute. You enter the condition as an Expression

image

orā€¦ make sure it is locked for more than 1 minuteā€¦

image


#5

OK - I think I got it - changed the ā€œif lockedā€ to ā€œif locked for at least 10 secondsā€ - that seems to allow me to exit, lock the door & get out of range before the motion kicks on againā€¦ now letā€™s see if the other 1/2 is that maybe the lock is not reporting in as fast as the motion picks upā€¦ :slight_smile: Posting below what I have in case itā€™s useful to anyone else. (left variable & device names in on purpose, as they shouldnā€™t reveal anything in this caseā€¦)

Thank you for the help!