
Creating a Z-Wave Smart Home hub using a Raspberry Pi - bedros
http://raspberrypihq.com/how-to-create-a-z-wave-smart-home-hub-using-a-raspberry-pi/
======
mankyd
Uniquely out of date as of today, actually: [https://home-
assistant.io/blog/2017/07/25/introducing-hassio...](https://home-
assistant.io/blog/2017/07/25/introducing-hassio/)

tldr; Home-Assistant, the system mentioned in the parent article, now
maintains their own OS variant for the RPi that they recommend you install
directly.

You don't have to, of course. You can still install Home-Assistant yourself on
whatever distribution you choose.

------
jon-wood
If this is the sort of thing that interests you, and you happen to be looking
for a job somewhere +/-3 hours from GMT, drop me an email. We're looking for
good engineers at Neos to work on our connected home security system (we're
also looking for people interested in building backend software for insurance,
but that's somewhat less sexy).

We've got a Raspberry Pi based hub which sits in customer's homes
communicating with z-wave devices, the software on there is currently
proprietary but if you do buy a policy drop me a line saying you're from
Hacker News and I'll turn on access to the MQTT broker running on the hub so
you can play with integrating other things ;)

------
knodi123
Hey, cool! I've been tinkering together something custom using a VeraPlus
[[http://getvera.com/controllers/veraplus/](http://getvera.com/controllers/veraplus/)]
and a raspberry pi for the last couple of years. It stopped working a few
months ago, and sadly I replaced my whole vera controller before realizing the
problem was that the wall wart had degraded and was no longer supplying enough
voltage. D'oh!

The Vera doesn't have wifi (well, it does, but it can't join a network!!!),
but a regular old raspi can act like a wireless bridge, offering wireless
access to the vera, and a sound card, and also a linux environment to run my
custom rails frontend. Add in some location reporting via Tasker, and I have
an announcement sound whenever an outside door is opened, and I have motion
and light sensors that record video and upload it to my personal website, and
it's all controlled intelligently based on when my wife or I are at home. I'm
pretty proud of it.

~~~
Klathmon
Home assistant works beautifully with the Vera.

It's how I have it setup right now, and it was a great way to slowly move away
from the Vera (at least as the UI).

------
Klathmon
I've been running Home Assistant (the software in the blog post) for a little
over a year now. (started out on a raspberry pi, upgraded to an Intel NUC
recently for more power, and to do more non-home-automation related things on
it)

It's by far one of the most well-managed community-driven open source projects
i've ever used.

All of the "components" are just small-ish python programs that contain mostly
"glue" code, and they are required to use 3rd party libraries to actually
implement the real work. This spreads the workload out across many repos in
terms of breaking changes and help, and makes it much easier to contribute
back to (you aren't contributing to a massive monolithic repo, you are
contributing to a small 200 line python library with 20 stars on github, much
less pressure!).

Because of this architecture layout, anything that has a python library that
can be consitered part of "home automation" most likely has it implemented
already. In my setup alone I have:

* chromecasts

* 2 different smart TV brands

* many zwave switches (run through a vera, not using zwave directly)

* many zwave door/window sensors

* multiple ip cameras

* a wifi thermostat

* a few IR controllers for "dumb" IR devices

* phone/device tracking (which keeps all the data stored locally)

* usps/ups/fedex package tracking and delivery notifications

* network speed monitoring

* have-i-been-pwned monitoring and notifications

* weather

* a 3d printer's completion percentage

* a google home

* an amazon echo

* ups runtime monitoring

* multiple esp8266 based sensors and switches for various hacked together things

* and more that i'm probably forgetting

And all of it is processed locally (when possible), stored locally (in a
postgresql database), secured via TLS, available on any browser anywhere, and
on a server I maintain and manage (with the help of some automations I created
in hass itself). And speaking of automations, it's python, so they are
basically unlimited. I have an automation that will notify me on my phone if
it will start raining at my phone's current location before I can get home,
and only while on my motorcycle.

It's not perfect (it's pre-1.0 software, so there are still semi-frequent
breaking changes, and configuration is mostly manual still via yaml files),
but it's been a such an amazing experience.

Home Assistant is the reason why I love IoT.

~~~
oh_sigh
I like the architecture of HA as well, but is there a way to use the HA level
interface but making it program driven, as opposed to config-driven?

I know python...I don't know all of the config variables for the yaml language
they encourage you to write

~~~
Klathmon
They recently introduced "straight python" components i believe, so you can
just write in that.

Additionally there are multiple apis you can use to interface other than the
front end at [https://home-assistant.io/developers/api/](https://home-
assistant.io/developers/api/)

Also the HA front end just calls those backend apis, so if you "emulated"
those you could use it as a drop in for some other backend (in theory)

~~~
oh_sigh
Thanks, I'll check that out!

------
fooey
I've been thinking how much I hate Iris and would love to replace it with
something else, and I've also been wanting to play with a Pi

It's amazing how awful the state of home automation is on the commercial side
right now

------
payne92
I think Z-wave has been or is in the process of being superseded by just using
Wi-Fi. I do not recommend investing in Z-wave gear.

~~~
manyxcxi
Unless you know something I don't, I think you're completely incorrect on both
counts. Z-Wave isn't going anywhere, just a few years ago the Z-Wave alliance
published Z-Wave+ and more and more consumer devices have been coming to
market. They're all over Home Depot (among other large retailers) and backed
by very large brands [0]. All major hubs support it, and z-wave offers many
specific technical and security advantages over WiFi with respect to
automation.

Z-wave has a much smaller threat surface area and requires no internet. In
fact, it requires no central controller at all, as you can have controllers in
every room for scene automation. The internet connected hubs bring a lot of
shiny features to the table, but they're completely unnecessary for local
automation. Even better, communication forwarding is part of the design so you
can have a controller hundreds of meters away from the thing you want
controlled and as long as there are a couple of devices on the mesh between
them it will work. We've seen how great WiFi repeaters are... plus WiFi on
battery is basically a deal breaker, whereas you can have z-wave devices last
two years on some AA batteries.

Z-Wave and Zigbee are both so much better than WiFi at automation that I can't
even fathom why someone would suggest the opposite.

[0]
[https://en.m.wikipedia.org/wiki/Z-Wave](https://en.m.wikipedia.org/wiki/Z-Wave)

~~~
payne92
History has not been kind to proprietary networking protocols, and it's
winning at scale rarely about just technical advantages. I know they have
opened up more in the past year or two, but it may be too late.

I refine my comment to capture BTLE as one of the protocols going forward, in
addition to wifi.

~~~
manyxcxi
I'll grant you BTLE and/or something more open ascending over Z-Wave or
Zigbee, but I've got to imagine that's years out. If I was picking something
for the next 5 years I'd still pick Z-Wave over the WiFi IoT horror show.

~~~
sdague
Also, there is a lot of inertia in the home automation space. Hue is all
Zigbee, and is one of the biggest off the shelf IoT platforms right now. The
door lock space is mostly z-wave. Friends that I have that have a mix of these
things are more and more putting their energy into z-wave as it's far more
reliable than wifi, having the advantages of the mesh network, and living in a
non crowded spectrum.

