Getting started with home automation

Until a few months ago, I’d suppressed any interest in home automation by assuring myself that, by living in an apartment, I had few options. I also knew myself well enough to recognize that I’d probably become a bit obsessed. An unrelated trip to Best Buy, which landed me in the home automation section, changed things.

I’d gone to Best Buy to pick up something I’d ordered online, and while I waited, I meandered through the section of smart lights, thermostats, and so on. The Philips Hue options caught my attention, but only enough to start me subconsciously planning how they might suit the apartment.

After a few days, I’d unintentionally come up with several issues automation could address:

  • we had a habit of leaving the lights on in the office when we’d finished work;
  • no rooms had dimmers, despite many that would benefit from them;
  • several rooms had awkwardly-placed switches (I’ve kicked our couch more times than I care to recall);
  • I had certain daily routines, like turning lights on at sunset;
  • in two areas, shared switches control multiple lights, which could be overwhelming;
  • finally, one of us has a habit of forgetting to lock the front door.

Hardware

To provide for the aforementioned, and much more, I wanted hardware from reputable brands that was also open for integration. My intent was to avoid hardware whose service provider might disappear, rendering the hardware useless. I also wanted to ensure that I could work with the hardware outside of the official apps they might offer. A fair bit of research led me to the following choices:

  • for lights, Philips Hue;
  • for sensors and other integrations, Samsung SmartThings;
  • for ensuring we lock the door, August Smart Lock;
  • to control it all, a Raspberry Pi 3.

Philips Hue

Several things attracted me to Philips over its competitors. First, the Ambiance line of bulbs have adjustable color temperatures, but not adjustable colors, so I have control without too much insanity. Second, Philips offers switches, so a smartphone isn’t even necessary to control the lights. Lastly, the Hue hub can be address directly over the local network, in addition to having an API and web interface, which provides for many integration possibilities; this also means that my lights aren’t subject to Philips’ API’s availability.

Samsung SmartThings

For everything other than lighting, I opted for the Samsung SmartThings product because it provides a wide array of sensors, and integrates with an endless number of third-party devices. It also offers an incredibly-robust development platform to allow for third-party software integrations. That the hub supports Z-Wave, Zigbee, and Bluetooth didn’t hurt.

August Smart Lock

While I love the product, I also had no other choice given the layout of our door’s hardware and my lease’s prohibition against changing the locks. August replaces only the back side of the lock, and is only slightly larger in diameter than a standard lock face, so it fits without interfering with other hardware or belying its existence from the exterior.

Raspberry Pi 3

I wanted something on our local network that was always-on and could host any software necessary to tie everything together, which made the Pi an easy choice. That I’m also comfortable with Debian and the command line didn’t hurt its chances. Also, I’d been looking for a justification to buy one for a while. 😂

Software

While each hardware provider (save the Pi) provides an app and other means of control, I knew that a centralized interface would be the only way to avoid endless frustration. If I, and anyone else who visits, need to install multiple applications just to get in and turn on a light, I’ve failed. Fortunately, my colleague Scott Evans is well-versed in home automation and saved me considerable research effort by directing me to Home Assistant.

Home Assistant

Home Assistant is an open-source, Python-based tool for integrating one’s disparate smart-home components. It has native support for many devices and protocols, and is also easily extensible. Beyond providing a unified view of our smart home, it also offers robust automation controls. Not only does this keep automation centralized–rather than being locked within each product’s app–but it also offers far more options than each app can on its own, such as turning off lights after no motion is detected in an hour.

SmartThings MQTT Bridge

For Home Assistant and SmartThings to communicate directly over the local network, rather than via the SmartThings API, I leverage another open-source project: https://github.com/stjohnjohnson/smartthings-mqtt-bridge. MQTT is a protocol designed specifically for “internet of things” communication, and this project uses that protocol to capture events from SmartThings and send them directly to Home Assistant (or any other MQTT-enabled service) over the local network. This gives me access within Home Assistant to every sensor and other bit of data that SmartThings devices capture.

Results

Now that I’ve teased how I got started and what I’ve done, why not a look at the current state of things? In the near future, I intend to detail my setup in full, and open-source my Home Assistant configurations. For now, here are some screenshots:

4 thoughts on “Getting started with home automation”

  1. I currently use smart things for some stuff around the house, but have some devices that are incompatible – this looks like it might just be able to unify all that. I’d imagine the smart things hub is still required in all of this?

    1. The SmartThings hub is still a big part of things, but with the MQTT bridge, it’s really just a translator between the devices connected to it and the MQTT broker. While I only communicate with the MQTT broker via Home Assistant, it’s an open protocol that can be used with other things.

      Another example of the flexibility SmartThings and MQTT provide: https://ethitter.com/2016/08/smartthings-smart-home-monitor-shm-mqtt-home-assistant/.

  2. Great post. I think your mindset prior to your Best Buy venture is very similar to those without smart home technology. The concept can seem overwhelming, unnecessary, and expensive. Glad that you are happy with your outcome!

Leave a Reply