The Hardware Hacker's Guide to Home Automation
Doctorin' the house
The home of the future is a staple of both speculative fiction and comedy. Back in the 1970s, Frank Spencer caused havoc in an automated home during an episode of Some Mothers Do 'Ave Em.
For some of us, the enduring image of home automation is either Michael Crawford chaos, worthy but dull X10 electric curtain openers, lights that turn on and off when you’re not there, or high-end systems that can manage everything from lighting and audio to collecting the post for you.
Source: BBC Worldwide on YouTube
Most of us, of course, can’t afford the money for the kind of top-of-the-line installations offered by a company like Grahams , but that doesn’t necessarily mean that home automation has to be limited to a few remotely controlled lights and power sockets.
These days, it’s much easier than many people imagine to achieve a fairly wide degree of home automation of one sort or another, without breaking the bank of leaving your visitors so confused when trying to figure out how the AV system that they end up lying on the sofa in the dark listening to the radio instead.
In the beginning
One of the most well known – if rather long in the tooth – technologies for home automation is the X10 protocol. Developed almost 40 years ago in Scotland, it sends control data over mains wiring during the zero crossing points of the mains signal. There’s a radio version too.
But with its 16 "house codes" and a maximum of 16 devices per "house", for a modern home with mood lighting, sensors and plenty of devices to control, the effective limit of 256 items that X10 can handle may cause problems for the more teched-up of us.
Set against that, there’s now a huge range of X10 modules available from suppliers such as UK Automation .
Tune in to your devices with wireless add-ons like Telldus' TellStick
By comparison – especially for the UK – there’s still a fairly limited selection of modules for some of the more modern X10 alternatives, such as the mesh radio-based Z-Wave or the newer Lightwave RF.
Then there are the various remote control power sockets, switches and dimmers that you can find in DIY stores. You might think that these are standalone, but in fact a reasonable number of them can be controlled using devices like Telldus Technologies’ £50 USB TellStick , with iOS and Android devices operating as touchscreen remotes.
But what’s it for?
But whether you go for a long-established system with a wide range of plugs, sockets, dimmers, switches and a controller, or something newer, one thing soon becomes abundantly clear: home automation can be an expensive business, especially if you want to go the whole hog and have things like touchscreen panels to control your lighting.
Home automation used to be thought of as something to save time and labour – open the curtains when you’re still in bed, for example. But as many of us become more conscious of issues from home security to energy usage – you don’t have to be a paid up member of the Greens to be horrified by your electricity bills – there are perhaps other ways in which HA tech can be useful.
Nest Labs' Nest thermostat can calculate your most efficient energy use pattern
Smart thermostats like Nest Labs' Nest  can learn about your routine, or sensors around the home can ensure lighting turns off when it’s no longer needed.
Automatic monitoring – I’ll skip the connected fridge; check out my feature WTF are… connected appliances  – can keep an eye on oil tanks and place orders, while security systems can let you know that the kids are safely home from school, all while you’re still at work.
They can you to movement caught on a camera. If you have a Synology nas box, for instance, then you already have surveillance software  - it's just waiting for you to attach an IP camera.
Roll your own
If you’re of a more technical bent, it’s not too difficult to come up with your own automation and control projects, even without investing in dedicated controllers.
For example, the Topfield TF5800 PVR is a Freeview recorder with a published API which includes a way to set timers. A few years ago, I created a service to allow timers to be set via SMS, so a user could send a text like ‘TOPPY RECORD BUFFY / BBC1 AT 1900 to a shortcode. The SMS provider, iTagg , then delivered it to a URL where it was stored in a database. A script on a PC then polled the website, and transferred a control file to the recorder via USB if there were new timers to set.
Take greater control of your energy use with a Wi-Fi thermostat, like the Heatmiser
Or take a device like the HeatMiser WiFi thermostat recently reviewed here . The protocol has been published, and there’s open source code to talk to it. By using the LocationOf.com app  on a Symbian phone, I can work out when I’m more than a certain distance away from home, and ensure the heating is turned off.
Open source, open house
While a glance through the various online stores will turn up quite a few "internet controllers" for home automation, they start at around £100, and very often you have to connect to the provider’s own website, rather than directly to your home network. That’s easier to manage for novices who don’t want to play with their firewall, but potentially leaves you stuck if the company folds.
That’s not going to happen with something completely under your control, and there’s quite a lot of software that you can run on Linux to do home automation. If the thought of a dedicated PC running 24 hours a day doesn’t appeal either, why not take the traditional path of hacking a router?
The Home Automation Hub reaches to a range of devices through your router
Just as replacement operating systems like DD-WRT  can make a lot of kit into a more flexible router, the Home Automation Hub (HAH) project  sets out to turn an Orange Livebox router into a home automation server, with an extra bit of hardware that – like the TellStick – allows it to control a range of gadgetry, and even keep an eye on energy consumption too.
In fact, with open source software like HAH and low-cost devices like Arduino , it’s probably easier than it’s ever been for people who want to experiment and use web technologies to link up disparate pieces of equipment with a mix of protocols.
Got an old IP camera? You can probably find out the URL to grab a JPEG from it to embed in a web page even if, like my old Veo Observer IP, the company behind it is long gone, and the camera itself would prefer to force-feed you an Active X control.
Since many of us now carry around a smartphone which can effectively be used as a touchscreen remote control, it’s the logical way to link many different devices together. And if the thought of doing all that from scratch doesn’t appeal, then you might instead want to take a look at Open Remote  which provides a Java-based server app that can talk to a range of automation protocols, including X10, Lutron lighting systems, KNX IP-based controllers and even Samsung TVs. A cloud-based tool lets you design remote control panels, which can then be accessed from Android and iOS devices, or the web.
Remotely operate your lighting with NXP's Wi-Fi bulbs
Likewise, the Ninja Block team have produced Ninja Cloud , a web-hosted console in which you can apply rules that will trigger events based on feedback from sensors - heat, humidity, distance, motion and such - connected to its Ninja Block gadget.
As more and more devices gain some sort of IP connectivity – even light bulbs are getting in on the act , and I saw the BBC’s ‘Universal Control’ in action when I visited its labs in Manchester last year  – it’s surely only going to become easier to control or interrogate things in the home, whether you want to save energy, keep an eye on security, or just make life a little bit easier. It might still seem unnecessary to many, but home automation has certainly come a long way from the days of Frank Spencer. ®