My smart (and private) home
We have two small kids and wanted a way to create an evening ambience so they would understand it is time to calm down and start preparations to go to bed. As a technology enthusiast the answer revealed itself to me immediately: a couple of smart lamps should do the trick. While that turned out to be true, the path to it proved more winding than I had anticipated.
I have written more extensively on why I have been avoiding big tech companies, but, in the case of home automation, privacy was an especially sensitive concern. This was a crucial piece of the puzzle I have been trying to put together to form the image of a convenient, modern, private, and secure personal technology landscape.
There are plenty of articles out there outlining—or even scrutinizing–the shortcomings of existing smart home solutions. The bottom line is this: there isn't (at least yet) an easy way to set up a smart home, no matter how much privacy you are willing to give up. And I just lost half of my readership.
Anyway we are here for my personal account, which can be summarized in one sentence: I don't need a frigging cloud to turn on a light bulb. I grant that many people want the ability to check, after leaving for work, if they remembered to turn off the lights. But that was not my concern when setting up my smart bulbs. Besides you don't need a cloud for that; only an internet connection.
The cloud usually comes with a liability: you exchange the services for your privacy. Now, many people are fine with this trade; I am not. Although I think you shouldn't be either, I won't try to convince you—not here, at any rate. It should suffice to say that what equipment in my home is on or off and at what time and how often is my sole business, not anyone else's. In addition, as hinted earlier, at least in the case of smart home systems, you don't seem to be in a much better position by using off-the-shelf, privacy hungry solutions.
Let us, then, assume you too would like a privacy respecting home automation system—or at least want to see where this is going. What then?, you ask. Here is where I will lose the other half of my readership. The short answer is: get yourself a Raspberry Pi and a Zigbee hub, install the FLOSS smart home solution of your choice, spend the better years of your youth setting it up and—if you are successful—your old age adding and configuring devices on it.
Although this is obviously an exaggeration for many people that is how it would feel and it is a legitimate criticism to several FLOSS initiatives. So, instead of just describing what I did, I will also try to generalize my steps to a slightly broader audience. Be aware that this is not an installation tutorial, nor a technology review, but more like a map of the required parts.
Let us unpack the scary sounding sentence above and see if we can make it more digestible to regular folks. First of all, you don't really need a Raspberry Pi for this, that's just the nerds preference. The Pi is popular for this kind of projects among people who do with it what I call the digital equivalent of model trains. It is a small device and it can do many tricks, but it is just a computer. Obviously this was my choice.
You do need some sort of hub, though, but you can also use that old computer that has been lying around. You can think of it as a sort of kapellmeister of our smart things orchestra. The things—light bulbs, sensors, locks, etc.—are our musicians. All of these devices need a language to communicate with each other. For example, a real orchestra uses the music notation—a protocol, in computer parlance. And you, my friend, are the composer.
A fair warning: be prepared to spend time on this, it should probably be treated as a hobby to avoid frustration. For example, at some point, while trying to fix something for the nth time I plugged the Zigbee module in the wrong place and burned my Raspberry Pi exactly when there was a world shortage of this device.
If you're thinking of going with Home Assistant, an easy option will be Home Assistant Yellow which is a single board computer with this system preinstalled.
The language with which your hub (or gateway) communicates with your things is probably the first decision you want to make. The reason is, most devices are not bilingual. Or, in our orchestra metaphor, imagine that, instead of giving the musicians their part from a score, the conductor gives a sheet with jazz notation. Classical musicians don't necessarily know how to read that and our music wouldn't work.
When I made my decision to start it seemed that Zigbee would be the best option because it is open source and it works with many different platforms and devices. The other contender was Z-wave (I don't know why they all have to start with a z), but at the time I was making the research Zigbee seemed to be more open.
If you are starting now from scratch it is probably better to wait a little and see where Matter is going. This is the protocol that promises to solve all of the interoperability problems we currently have with home automation standards. If it succeeds it will render the interoperability problems hinted at in the beginning of this article obsolete. (You would still have to worry about privacy, though.)
Our conductor obviously needs a baton, that is how it communicates tempo and some of its intentions to the musicians. It is such an important instrument that it is worth dying for. In off-the-shelf, big tech products—such as Amazon Alexa—this piece of technology is built-in. But we are exactly trying to avoid them, so we need to worry about this as well.
For my use case I chose the Raspbee II, because I wanted to leave the USB ports free for other possible uses (also, I must admit, because it is much cooler). If you couldn't care about this or if you are using a regular PC for your setup you can use the Conbee II.
I already told you about my maestro's body: the Raspberry Pi. But how about its mind? That is the home automation software to manage all the things and allow you to control them. Here you also have many options. I chose openHAB because it is free and open source and it seemed to have a vibrant community behind it. The downside of this option is that the learning curve is very steep. Even with technical skills it took me long to learn my way around it. Home Assistant was another free and open source contender, which I did try at some point. It seems to be much easier to use and has lots of integrations. I didn't like to have a limited operating system, which is the default (and easiest route). Both support Zigbee and Z-wave and I can bet they will support Matter once it is released.
Another option I encourage beginners to check is Webthings, originally a Mozilla project, but now independent. The interface is much simpler and seems a lot easier to use. I haven't tested it thoroughly so I am not able to recommend, but I suspect it will be the easiest of all.
All of them have mobile apps and/or a web interface for you to interact with them, so you never even have to check your hub's screen (if it has one). I control everything from my phone and do the configuration from my laptop, both on the same network. (I didn't expose this setup to the internet for security reasons, although you can do that—if you know what you're doing.)
Once I had all of these pieces in place I bought my first smart thing: an Ikea Trådfri light bulb with variable color temperature, which is great for creating a day–evening ambience range. The entire Trådfri line of products uses Zigbee and I got several of those; they work really well with my setup and do exactly what I expected.
One thing I learned the hard way was that to pair your devices to the network—that is, to connect them to the gateway for the first time—you sometimes need to put the device really close (less than 20cm) to the Zigbee receiver, otherwise it might not be recognized.
I have been spending some time configuring the remote control interface. There are many ways to do that with OpenHAB and I use two: sitemaps and the HABPanel. The former exposes the things to different interfaces, including the iOS app, which is what I use to control the devices from my phone.
This setup also allowed me to repurpose an old iPad, which, according to Apple, was obsolete. In fact, the device works really well, but the app store won't allow me to update the operating system, which means I can't install new apps. This is called planned obsolescence and is a nasty, environmentally harmful practice.
That's where the HABPanel comes in handy because it is available as a web interface. It is also a progressive web app, which allows me to install it to the home screen and renders it indistinguishable from a native app.
My smart home remote is designed by me for my family's use cases. It looks as good (or as bad) as any other smart home remote, but it behaves exactly as I want, without compromising our privacy and without vendor lock-in.
Regarding my original aim, as with my media library the smart home project turned out very successful from the personal perspective. Like I said my goals were not especially ambitious, so it is actually surprising how much work it took. Most of it went into learning how to use and configure OpenHab. If you go with a simpler option it will probably be a lot easier—although you might need to give up some power.
The political level goal, as with the media project, was also a bit of a disappointment. Not that I expected an out of the box solution that would work for everyone. But it is sad to prove once again that keeping our privacy is so difficult for the average person. As usual, if you decide to try, feel free to get in touch with me and I will do my best to help.