Home made door lock sensor

ThingShield. It’s a bridge between and arduino and smartthings. Very popular for just this kind of project. It’s what many of the makers use.

You’ll find most of them in the following topic. This is a clickable link.

Also see the pressure mat topic. There’s discussion there on connecting contacts sensors to other devices.

1 Like

Thanks @JDRoberts for those ideas. Unfortunately I cannot source any of those products in the UK…I will try and edit my original post to show I am in UK. Cheers

I believe the Thingshield uses zigbee, it should be the same for all countries unless you can’t get compatible Arduinos.

No problem getting Arduinos, and yes zigbee would be fine…but Samsung does not ship Thingshield to UK. One guy on UK eBay is trying to sell one for $100 !

Yikes! Must have some “no export” technology, then, some of the encryption technology falls into that. Or it may be boosted zigbee. That does make it more challenging.

Perhaps check with some of the maker groups in the UK to see what they use for Zigbee or Z wave communication. Zigbee needs to use the zigbee home automation protocol, 1.2, usually abbreviated ZHA 1.2

You could also check with robotics groups, but they’re more likely to use the zigbee green energy profile, which is not compatible with SmartThings.

Based on something someone else said earlier today, mysensors might be a European option, but no one is written an interface yet so you’d have a pretty big project. The people in the thingshield topic could probably help.

@djtucker @JDRoberts,

I used an Ecolink zwave sensor and a tiny microswitch that I mounted inside the lock itself. I also created a device type for it as well. Needs a little cleaning up, but it works:

3 Likes

John - I really liked your solution for checking if the door is locked - do you have any further pictures/tips on how I could go about making this? Would most sensors work this way? I’m good with prying open electronics and soldering wires and hope to engineer something like this as well.

1 Like

@shashvat - GoControl WADWAZ-1 sensors (and Ecolink?) have internal screw terminals so you don’t have to do any soldering in the sensor. I had some wired contact sensors with my previous home automation system and used those rather than mounting the GoControl

@johnconstantelo - That is really slick! Could one sensor be used with magnet on door frame AND using the internal contacts for the lock as you did? Does/can the DTH report both separately? I thought about attaching magnet to my sliding door “bar” (1" dowel rod) to make sure it was in place since the “locks” on sliding doors are pretty much useless. Its pretty easy to shake the door up and down to unlock them (on cheap/older ones anyway).

1 Like

Thanks @shashvat. Those are the only 2 pictures I took, but they are big and you can zoom in to see a lot of detail. Click on the picture, and then click on it again to see it in it’s original size.

Here are some tips on doing this with a microswitch:

  • Use a thin and small microswitch like the one I used from Radioshack so that it fits within the turn knob’s housing. Take the housing with you if needed to make sure. Notice in the second picture where I had to use a plastic spacer to make sure the switch made good contact on the barrel.

  • Rotate the knob all the way to the locked position and tape it that position so it doesn’t move on you while placing the switch and the high tech piece of toothpick on the barrel. :wink:

  • Hot melt glue is awesome for a little project like this. Be careful not to get glue by the switch’s hinge or button. You want smooth operation.

  • Give yourself plenty of wire to work with, and don’t go too thin. You can accidentally cut the wires if you put the housing back on too tight. The extra wire you give yourself can easily be tucked away.

As @kevin said, the sensors that work best are the ones with screw terminals inside. The sensors I know of like that are Monoprice, GoControl, Ecolink, and Schlage. You could use something like an Iris sensor by soldering wires too where the reed sensor is, but that’s a lot of work in my opinion.

I believe there was a question about that somewhere in the Community in another discussion, and the answer was yes you can, and yes regarding the DH. Let me do some searching and I’ll post back the link as soon as I find it. Be right back…

1 Like

Found it! Sounds like the GoControl Contact Sensor may be the one to use.

I have a few of the Monoprice ones,so I may have to try this out for fun.

Hello! I’m taking a subject of entrepreneurship and we have to present an idea to put in the market. My group thought about a keychain with a little light that warns us if we locked our front door or forgot. In case we forgot, the red light of the keychain will light up. Otherwise the light will be green.
We don’t have a deep understanding of electronics, but from what I searched I think the best way to do this would be with a piezoelectric sensor installed in the lock, so that when the door latch goes into the cavity, the sensor will be activated. I probably also need a arduino, right? To receive the information of the sensor.
My question is: what else do I need to send that information to the keychain? How can that be done?

What are the main components to do something like this?

If anyone could explain me just the basics, it would be a big help already.
Thanks.

Hello! I’m taking a subject of entrepreneurship and we have to present an idea to put in the market. My group thought about a keychain with a little light that warns us if we locked our front door or forgot. In case we forgot, the red light of the keychain will light up. Otherwise the light will be green.
We don’t have a deep understanding of electronics, but from what I searched I think the best way to do this would be with a piezoelectric sensor installed in the lock, so that when the door latch goes into the cavity, the sensor will be activated. I probably also need a arduino, right? To receive the information of the sensor.
My question is: what else do I need to send that information to the keychain? How can that be done?

What are the main components to do something like this?

If anyone could explain me just the basics, it would be a big help already.
Thanks.

NYCE sensors have been working on a way to do this, but have not released a product to date. A hub or bridge in between will be required to translate the communication type of the sensor to internet protocol. Examples are Bluetooth to IP, Zigbee to IP and Z-Wave to IP. A keychain is an idea that might have been better accepted some years ago, but with pretty much everyone in the world now caring a smartphone and home automation on track to be embedded in TV, set top boxes, kitchen appliances and voice assistants, the preferred notification device will be via smartphone.

The current sensors available from NYCE could be modified to sense a door has lock and they’re some of the smallest available with Zigbee radios built-in.

http://nycesensors.com/products/

There’s also a very small Z-Wave radio sensor called Strips. This video could show how a product like this could be made to react with the bolt of a lock interfering in the path of the sensor to indicate door locked/unlocked.

Hi there

I made something similar to this after seeing your post. I was using a Xiaomi door sensor.
The only hick-up I have is being able to edit the DH to make it say Lock and Unlocked instead of Open and Closed. I thought I could just take the door and change the Labels but it doesn’t seem that simple.

Any idea are appreciated.

Thanks
-mike

Point me to the DTH you’re using and I can help.

1 Like

OK…so I figured out a way to do this. After reading lots of threads about reed switches, microswitches, and pressure sensors (some of which are scattered on my desk right now) and trying to figure out where to place these various things…it occured to me:

I just need a metal contact to close the loop. Isn’t my deadbolt made of metal?

So, I decided to make my deadbolt the switch:

  1. I had a slim piece of wood (picking numbers at a Christmas party), which I drilled tiny holes through with a tiny screwdriver. I was using wires from a phone cord, which were very tiny (I didn’t want big holes in the wall.)

  2. I drilled an angled hole from the outside of the doorframe to the deadbolt hole, ran the wires through the hole, and threaded my wood base.

  1. I then stripped a considerable amount of wire and wrapped it around the base.

  1. While this went in perfectly, there was no contact. I figured I could put something behind the wood base, but I had an old wire run with a thick neutral wire, so I cut off two pieces and wrapped those around the existing wire and wood base. (Protip - be sure to cut yourself when stripping the wire. The Home Improvement Gods still demand a blood sacrifice. It would explain why my project didn’t work the first time.)

Be careful for any stray wires. My app kept reading “Closed” until I finally saw this.

  1. Carefully pull the wood base to the back of the deadbolt hole, and try your deadbolt. Voila!

Now…I’ve got to do this to my garage entry door…

1 Like

Very creative! I just use SmartLocks. Figured not only will they report lock/unlock status, but can also lock/unlock without having to physically do it.

If door remains unlocked for 30 minutes
And
Door contact hasn’t changed in the last 29 minutes
Then lock door

If presence sensor arrives
Then unlock door

If alarm is set
Then lock door

These rules are inconstant play.

I get it though. SmartLocks are not cheap. :weary:

I have a smart lock on my front security door, but didn’t want to put on one my back door (expense was one factor, though.) It’s a Kwikset, and it’s set to lock itself one minute after being unlocked. I won’t trust that to ST.

I just wanted to know if the back door was locked before we left the house. I have a Homeseer 200+ right by my front door, and now the indicator light will blink if the back door is unlocked to remind us to lock it before leaving. Also, I use Echospeaks to tell me when a door is unlocked, open, etc.

I’m confused. Are you running current through those wires? If so, that’s a heck of a fire hazard to put inside your wall. Just sayin’… :scream: :rotating_light: :fire_engine: :ambulance:

No, it’s connected to the dry contacts on my sensor.

2 Likes