Raspberry PI + AugustLock + ST

Hey all!

Just a heads up that I managed to integrate the AugustLock into ST. The only downside is that an external computer is needed - in this case, I used a RaspberryPi and tested against my Mac.

Uploading the project and all the info here:

More to come soon…

8 Likes

Just made a quick video showing this in action:
Youtube Video

Working now on documentation to get this done. Still facing some odd bugs, but for the first run it is totally functional!

2 Likes

This is awesome. I got this working with a Mac Mini that I already have running node js for my homebridge / smartthings / homekit tinkering…

Though the instructions aren’t quite clear I was able to limp along from the various Git projects and cobble it all together to get it all working on the first attempt…

Of course I just question the fact that I have my offline key now stored on a config file on my server, will have to lock that file down. But at the end of the day i’m not worried about that kid of stuff because this is more of a convenience device. If an intruder wants into my house there are many easier ways to get in than hack my mac and august lock… i.e. kick my door down, or go through a window with glass cutters…

Awesome!

Still have a lot to improve on it. Spent just a few hours working, so, a lot to be improved. Glad it worked for you!

Of course, ideally would have this accomplished directly from the HUB. But hopefully will be able to improve this and get an extra security layer on it.

Yeah but it’s definitely a good start. How can I get this to run on boot and output errors to a specific file on OS X? For my homebridge node app i’m using launchccontrol that creates a launch daemon just not sure if this has all the parts yet…

I’d take the same approach, using a launchd. See an example here:

Would also add that to the project. Let me know the progress!

Ok i’ll give it a shot this weekend will update you…

I wonder when ST is going to activate Bluetooth in the new hub… maybe you would be able to connect August directly to the hub.

@jcommisso for sure - would be quite straightforward porting the code, and safer too. The only thing is having them releasing things.

For instance, local hub notifications for example, doesn’t support https, only http. So, it’s not a big deal if we add an extra safety security layer, like a firewall, but doing this directly from the HUB would be the best approach indeed.

Only doesn’t understand why people from ST don’t release that. If things with August doesn’t go forward, then, let us do :slightly_smiling:

Can you add the capability for the device to automatically update its status if the lock is manually locked or unlocked?

I added:
capability “Refresh”

To the metadata section and this has allowed me to use pollster to launch a refresh every minute. Wondering what the affect would be if we had something polling the state every second to get the latest state of the lock.

Great!

It is on my roadmap. Just dont know the downsides yet of polling the lock every minute. For sure, the minimum would be battery drain.

Will add that.

Thanks

Oh yeah it seemed polling every minute for the last couple days may have killed the battery. I’ll keep testing…

Does this require the August connect to work? Or does it just work with the August lock itself? I cannot seem to get this working no matter what I try.

Does not require August connect. The raspberry PI or Mac Mini in my case, connects directly to the August lock via bluetooth. Where are you running into problems?

I think I have everything setup correctly. Using a Mac Mini. I can start Node and run the Server.js but from there it doesn’t do anything. When I try to open a browser and check the status I get no response and cannot run any commands. In the Smartthings app the Lock device I added just shows “waiting”.

Any help would be appreciated!

In the terminal you are running server.js are you seeing any output? Like error messages etc?

When I start it the only output I get is …

Matthews-Mac-mini:~ matthew$ sudo node
Password:

/Users/matthew/.nvm/v0.10.29/lib/node_modules/augustctl/server.js

You should see something like this:

Listening at {“address”:“10.20.30.106”,“family”:“IPv4”,“port”:3000}

And then it will output successful commands and errors

Can you try and type:
$ cd /Users/matthew/.nvm/v0.10.29/lib/node_modules/augustctl/
$ node server.js

Also is node v0.10.29 the only version of NodeJS you have on your Mac?

Thanks for all your help.

When I type the commands you gave I am getting:
Matthews-Mac-mini:augustctl matthew$ sudo node server.js

module.js:340
throw err;
^
Error: Cannot find module 'debug’
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object. (/Users/matthew/.nvm/v0.10.29/lib/node_modules/augustctl/lib/lock.js:3:13)
at Module._compile (module.js:456:26)
at Object.Module._extensions…js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)

If it helps I was able to get the project https://github.com/robson83/augustctl working independently of this and can successfully execute the commands
augustctl unlock
augustctl lock