Is anyone actually using a door lock (with lock/unlock status) in OpenHab?

I have not seen anyone using OpenHab to actually securely control a door lock and know its status. Does anyone actually have this working?

I know Z-Wave is out of the question, because of the lack of security class in OH.

Besides just locking and unlocking, the first priority is to know whether the door is actually locked or not (knowing its status).

Given that real door lock support in OpenHab seems a long way off, I’m weighing my options as to how to proceed adding a lock in the next month or two.

The solution I’m leaning towards is to get a Samsung P717 lock, which has RFID and pin capabilities. There is an optional remote with this that can be used to lock and unlock the door. I can hack this remote, Jon Oxer style, and use an arduino or other microcontroller to trigger the lock/unlock mechanism.

However, the problem is in knowing the status of the door. If someone unlocks it from the outside and comes in, and leaves the door unlocked, I have no way of knowing. A post on the old OH site featured a clever way using magnets to determine if the lock bolt itself is closed. But this requires a bit more wiring than I’d like to do at the front door.

So is anyone actually using OH to lock and unlock the door, and more importantly, to know its status?
Thanks!

Actually it looks like zwave door lock support for Schlade and Kwickset locks will be released in OH 1.8. You can experiment with it now if you get the nightly build for the 1.8 zwave binding. See this lengthy thread for the discussion and current status.

Personally I got a Kwickset zwave deadbolt but probably won’t openHAB enable it. It has a keycode to enter on the outside and I can set it to automatically relock after 30 seconds so if the door is closed (I have sensors already hooked up to OH for that) I know its locked and if I need to unlock it I have a keycode which is way more convenient than whipping out my phone to unlock it that way. If I do enable it, it will be to get the battery status or as a “just because I can” project.

But the point is that door lock support isn’t as far off as you might think, but even if it is there are other ways around your problem.

Thanks Rich.

I’ve read that thread, and while it looks like progress is continuing, it still seems a few months away, at least. Hopefully not, but the point is, it’s not ready yet, and “soon” can turn into months.

The Samsung lock I referenced also has a self-lock, but I’d like another way besides just knowing the door is closed, to know that it is also locked. This may be my best bet, just trusting the auto-lock, but it seems “half done” at best since I cannot actually poll the status of the lock.

You mention “there are other ways around your problem” – that is exactly why I posted, to get some other ideas, so please, let me know what these ways are, thanks!

-Josh

I think you will find with HA in general, not just openHAB, a few months IS soon.

Assuming you can trust that the autolock will relock the door every time, which I do based on the two months I’ve been living with it, and that your door sensor will report the door as open even if it is just open a crack, I know with certainty that if the door is closed it is locked. There is no other way short of a major hardware failure or sabotage for the door to be closed. And in either of those cases, being able to poll the status of the lock over zwave is no more reliable.

The approach is simple, foolproof, and reliable and it fits perfectly with my personal home automation philosophy. Automation should just work without interaction and without my needing to think about it. If I ever have to resort to the sitemap for anything beyond debugging the system then it is an HA failure. I’m not unique in this philosophy but I’m also not necessarily in the majority. Adding in the ability to poll and trigger the lock, in my opinion, just adds complexity and redundancy for the sake of having it without adding any new capability.

The only missing part, which I will admit, is battery status. But I don’t think you need the security part of zwave to poll for the battery status, perhaps @chris can correct me if I’m incorrect. If that is the case then:

Knowing the door is closed + knowing the lock’s battery isn’t dead = knowing with confidence the door is locked

This is the other way around the problem. My point was you don’t necessarily have to poll the status of the actual lock to know the door is actually locked. You just need to find a reliable way to check other things which would indicate the door is locked.

Hmmm - I doubt that. 1.8 is due for release soon, and I don’t think the security classes are mature enough yet unfortunately.[quote=“rlkoshak, post:4, topic:5291”]
But I don’t think you need the security part of zwave to poll for the battery status
[/quote]

It generally depends on the device as to what classes are implemented in the open, or encrypted. If I look here for example, it shows that battery class for this lock requires the security class to read the battery…

1 Like

Thanks @chris

So, given that @rlkoshak does not have the lock actually integrated with OH in any way, the question is: does anyone have a lock itself communicating with OH (even through another binding, e.g., the lock can be activated through MQTT, etc)?

I am successfully using two Homatic “Keymatic” Locks via Homematic Binding and with a Homematic CCU2 as gateway.

1 Like

I initially used the kwikset lock with my omnipro ii install and openhab omnilink binding in my last place…now I am using another kwikset lock with the vera controller and mios binding. No problems. DSC alarm and binding for door status also.

1 Like

I am using a Schlage Connect deadbolt with a hacked Wink router connected to OpenHAB and it’s been working fantastically for a couple months now. The Wink router takes care of the security bindings and all of my rules are in OpenHAB. My goal was to be able to lock the door automatically once my wife or I left the house and unlock it when we were getting close to home again. This is something no commercial setup will do because of the feeling that this is an insecure setup. Frankly, my windows are quicker to smash than my setup is to hack so I don’t care.

I’ve also got OH set up to turn the porch light on/off depending on the lock status and the time of day as well as locking at 11pm if it’s still unlocked.

Very happy with the setup and I can provide some more dtechnical details if you’re interested. The Wink hub hacking was the bit that would turn off most people.

2 Likes

Hi,

I am using HomeMatic Keymatic since 6 months now. It works flawless.
It is controlled by a remote (directly) and by a Homematic CCU1 for interfacing with OpenHAB.
Status is updated perfectly.
Everything is installed on a Raspberry PI 2 .
I’ve also setup rules to close automatically (after open) after a configurable time.
If someone is interested, I can share the config .

all the best,
Nicu.

Bill,
I’ve seen a few Wink hub hacking tutorials and I’ve been keeping an eye out for an older one. Did you have an original version of the hub or can it be done using one of the newer hubs? I want to control a Schlage Camelot lock and the Linear Garage Door Opener (GD00Z-4). It looks like the AeoTec z-wave stick won’t work for these 2 devices since they use a secure protocol but I’m hoping the Wink hub would work. Do you think these 2 devices would work with a Wink hub and OpenHAB?

Any tips on how to get the hub ready for OpenHAB? Do you have a specific tutorial that you followed?

I have a free Nexia subscription that expires in September and my current alternative would be SmartThings, but I’d like to get everything into OpenHAB before September comes.

Hi David,

Yes, I bought a new hub about 5 months ago and rooted it fairly easily (although I bricked one and had to exchange it). Generally I followed the guidance in this thread: http://rootwink.com/viewtopic.php?f=6&t=67

You will have to open up the hub and short one pin on one of the chips on the board. It’s crazy small but after a couple practice shots it’ll get easier. Once you have rooted the hub using this method, you can let it upgrade the the latest version with no issues (at least, none that I’ve had so far), which is nice because they update the device catalog sometimes with those updates.

Any device that is compatible with the Wink ecosystem will work with OpenHab - it just involves an extra coding step on the wink hub to tell it to pass the data to your OpenHab server along when asked. This is all very well documented online (mostly at rootwink.com) and I found it easier than the OpenHab scripting.

Best of luck! If you run into a problem I can try to help, although it was long enough ago now that my memory is a bit fuzzy. The rootwink forum would probably help, too.

Thanks for your help! I bought a hub from Home Depot (WH18), shorted the NAND chip using a switch to make it easier, and have successfully rooted the hub. I can SSH in now and I will need to figure out how to get everything working with OpenHAB now. Thanks for showing me where to start!

I’m working on getting OpenHAB to communicate with my Wink hub, but I’m having some trouble. Are you using SSH or PHP to control your hub? I was under the impression that PHP no longer works with the newer firmware versions (like mine) and I’m trying to figure out how to pass an aprontest command to the hub through OpenHAB using SSH. Any input on how I might be able to accomplish this?

Other notes: I’ve got OpenHAB set up on Windows. I can SSH into the hub on both Windows (using PuTTY) and Linux, and I’m able to control my devices using aprontest through SSH.