Schlage Connect Smart Deadbolt Door Lock


1) Give a description of the problem
Unable to find the correct event or log to use as a trigger

2) What is the expected behaviour?
If a wrong code is entered on the keypad the outside lights will flash and I will receive a text

3) What is happening/not happening?
When I run a test from WebCoRE, lights flash and I do receive a text. When I set the lock and enter a bad code, nothing happens. If I enter 3 bad codes the lock itself will timeout for a few minutes as designed by Schlage before a new un-lock attempt can be made. No flashing of lights or text after 3 wrong codes are entered either.

4) Post a Green Snapshot of the pistonimage

5) Attach logs after turning logging level to Full
6/6/2021, 9:48:41 AM +120ms
+0ms ╔Received event [Home].time = 1622987321999 with a delay of -879ms
+47ms ║RunTime Analysis CS > 19ms > PS > 7ms > PE > 21ms > CE
+50ms ║Runtime (38311 bytes) successfully initialized in 7ms (v0.3.110.20191009) (49ms)
+51ms ║╔Execution stage started
+71ms ║║Executed physical command [driveway light 1].off() (10ms)
+80ms ║║Fast executing schedules, waiting for 826ms to sync up
+916ms ║║Executed physical command [driveway light 2].off() (7ms)
+924ms ║║Fast executing schedules, waiting for 5ms to sync up
+939ms ║║Executed physical command [porch].off() (6ms)
+946ms ║║Fast executing schedules, waiting for 1933ms to sync up
+2886ms ║║Executed physical command [driveway light 1].on() (4ms)
+2893ms ║║Fast executing schedules, waiting for 12ms to sync up
+2912ms ║║Executed physical command [driveway light 2].on() (4ms)
+2919ms ║║Fast executing schedules, waiting for 10ms to sync up
+2935ms ║║Executed physical command [porch].on() (4ms)
+2945ms ║╚Execution stage complete. (2895ms)
+2956ms ║Setting up scheduled job for Sun, Jun 6 2021 @ 9:48:48 AM EDT (in 3.925s), with 54 more jobs pending
+2965ms ╚Event processed successfully (2965ms)
6/6/2021, 9:48:37 AM +871ms
+0ms ╔Received event [Home].test = 1622987317867 with a delay of 4ms
+61ms ║RunTime Analysis CS > 22ms > PS > 8ms > PE > 30ms > CE
+64ms ║Runtime (38308 bytes) successfully initialized in 8ms (v0.3.110.20191009) (63ms)
+65ms ║╔Execution stage started
+83ms ║║Comparison (string) {“3”:“House Code”,“4”:“Coyce”,“1”:“Madison”} is_not_any_of (string) “3”, “4”, “1” = true (3ms)
+85ms ║║Condition #2 evaluated true (14ms)
+86ms ║║Condition group #1 evaluated true (state did not change) (17ms)
+89ms ║║Cancelling statement #3’s schedules…
+115ms ║║Executed physical command [driveway light 1].on() (8ms)
+137ms ║║Executed virtual command [driveway light 1].flash (36ms)
+153ms ║║Executed physical command [driveway light 2].on() (8ms)
+161ms ║║Executed virtual command [driveway light 2].flash (22ms)
+176ms ║║Executed physical command [porch].on() (8ms)
+184ms ║║Executed virtual command [porch].flash (21ms)
+187ms ║║Requesting a wake up for Sun, Jun 6 2021 @ 9:49:38 AM EDT (in 60.1s)
+255ms ║╚Execution stage complete. (189ms)
+278ms ║Setting up scheduled job for Sun, Jun 6 2021 @ 9:48:41 AM EDT (in 3.851s), with 60 more jobs pending
+285ms ╚Event processed successfully (285ms)


I’m on my phone but this part of the log is what stands out.

+83ms ║║Comparison (string) {“3”:“House Code”,“4”:“Coyce”,“1”:“Madison”} is_not_any_of (string) “3”, “4”, “1” = true (3ms


These are the defined codes I have set up. My idea was if a non-defined code was entered, this would trigger the piston, which is not happening when I enter bad codes on the lock. We have 3 defined lock codes in the Schlage system and they are identified as 3, 4, and 1 as seen in the comparison string. If not one of these, then trigger the piston. The actual app does a great job of telling me who entered the code, Madison, Coyce, or the generic “house code” code. # 2 was deleted, which is why it does not show up in the string above. I’m interested if someone enters a code wrong that maybe walking through the neighborhood checking locks. All the homes in my community have these same locks. # 2 code was the builder / vendor code which everyone has and has been removed from my system. FYI, the numbers are not the code itself, just the placeholder for the actual code. I also have cameras at the door, but wanted the extra level of evidence to show you came to my home, entered a code to check the lock, and you tried to get in. The camera can not see the lock keypad, only that someone was standing at the door.


I think you may have to pick lock code instead of lock codes in the drop down list. See what it gives you in the logs. Right now, it’s logging all the assigned codes in the lock.

Edit: Hmm that’s not it, I just tried it on mine. Will check again later.


I’m not sure if we’re using the same driver for the lock but have you tried matching it on the lastCodeName attribute instead? If lastCodeName is not any of "House Code", "Coyce", "Madison"


Locks aren’t really my thing but I don’t see anything in the SmartThings capabilities for handling invalid codes. It may be you need a more sophisticated device handler supporting custom capabilities, which I believe is RBoy territory.


that’s a great idea, will give that a try today and report back.


no luck. I did notice that the piston is not running at all, so I entered a polling statement for every 3 minutes to see if it would poll the lock and see if bad codes were entered. No luck with that either…


I just set this up before I drove home and this is the output of my test piston. I should have entered the wrong code first to see what the output is :slight_smile: