Episerver 9 CertifiedMicrosoft Certified ProfessionalMicrosoft Certified Technology Specialist: .Net Framework 4, Web Applications

Home Automation with Home Assistant

A few months ago. I was bitten by the Home Automation bug. This started with a simple conversation with a colleague about security cameras. He mentioned some software called Home Assistant, which is an open-source piece of software that allows you to automate all sorts of things in your home.

This began with researching what was possible, and what I could do. I wanted to start simple, just to get a feel of things. Inevitably, this started with automating lights (I think this is where most people start!). I found that Ikea do starter kits for a reasonable price. Perfect!

This kit came with a couple of light bulbs, a remote, and the hub required to communicate with the bulbs. This was up and running in no time at all, and I was very happy with it... to start with.

Fine Control

I wanted to do more.. I wanted to be able to turn on the lights when I walked into the room, for instance. Handily, Ikea also sell some motion sensors. As these are part of the same range as the lights, they already integrate nicely with them. So, I purchased a couple of these as well. Again, connected up and working in no time.

I still wanted more. More control over what items did what. Enter Home Assistant.
I run an Unraid server at home, for all my NAS needs. This also allows you to expand functionality, by running Docker containers. As it turns out, there is also a docker container for Home Assistant.

Fast-forward a couple of weeks, and I'd got HA up and running, and I'd tinkered enough with it to know what I wanted to do.

I then hit a snag. It turns out that the Ikea hub doesn't let you connect it to HA. The hub runs the Zigbee interface for low-powered devices, but doesn't expose itself be being controlled externally.

A few posts on the home assistant forums suggested using a universal zigbee gateway. The Conbee II, A small usb-key that runs as a hub, but with much more control over what you want to do with it. (Also, works with HA, if you hadn't guessed!)

So, I purchased https://phoscon.de/en/conbee2one of these and installed the software for this (Also a docker container) on my server.

We're up and running! - Time to disband the Ikea hub, and move over to Conbee.

Even Finer control

Home Assistant does most of what I was aiming for, but the techy in me wanted to see what else I could do. Node RED is a node-based application for wiring together different hardware devices.

Install that on the server (also as a Docker container). So at this point, I have Home Assistant, DeConz (the Conbee software) and Node RED all installed via docker on the server.

Hooking into Home Assistant is easy, and once connected, you have access to all of HA's devices.

From here, I can tweak, change and customise how I want things to work.

For example, I have a motion sensor in my hallway, and an Ikea light on the landing upstairs.

I listen for the motion sensor trigger, and tell it to turn on the upstairs landing light. After 5 minutes, I tell the light to turn off.

Now that I have such fine control, the possibilities are endless!

Update: I've now added a few door/window sensors into the fray. Whenever a sensor goes off, it sends a message to my phone letting me know.