Integrating Home Automation & Alarm

I have been thinking lately about improving my approach to home automation, and particularly in making better use of the various technologies I’ve got. I think one of the mistakes made in home automation generally is neglecting the ‘automation’ part. I’ve seen plenty of approaches which really just substitute one set of switches for another (albeit electronic). I can’t see much point in in switching lights on and off using a phone or remote when it’s much easier to do so using the light switch! So really what you want is a largely automatic system which anticipates your needs and does what you want without user intervention.

So far as I have written about before I already have a mixture of systems with MAX for heating (currently controlled using FHEM) and Z-Wave for which I have been using a Vera Lite. I have been using a 3rd party plugin which provided an interface between the Texecom panel and the Vera, but in spite of this I’ve never been that happy with it as a controller. The interface is rather old fashioned, the newer updates (so called UI7) have had a decidedly mixed reception and I’ve never really felt I understood how to program it properly. Whilst the UI looks pretty it was also rather clunky when you tried to use it.

I’ve written before about FHEM and whilst I know it’s not everyone’s cup of tea I have really got to like it because although it looks unappealing it gives you a huge amount of information and lets you do pretty much anything you want with a few command lines. I also think that it helps you understand a lot more about the devices you are using. So the obvious thing to do was to bring all my Z-Wave devices into FHEM and try to integrate heating and lighting and also build integration with the Texecom panel.

The key to all this is a USB Z-Wave adapter for my main server. These don’t come cheap and there is some choice. I eventually bought an Aeotec Z-Stick Gen5, which came recommended but pretty expensive at about £40.

aeotec-z-wave-usb-z-stick-526

 

There are others available, including the Z-Wave.Me UZB which seems rather cheaper. This should also work with FHEM and other software although the Aeotec seems slightly better established. The other and much cheaper option is to use an experimental method whereby CULFW devices can be set up as Z-Wave controllers. However this lacks some of the benefits of the proper controllers (including battery back up etc) and probably is not for ‘production’ systems just yet.

So far all has gone well. FHEM recognised the controller and configured it correctly. I had to ‘exclude’ all the devices from the Vera to reset them and then ‘include’ to the Z-Stick. You can do this either by physically taking the stick to the device and pressing the button on the stick, or else simply setting the Z-Stick into ‘inclusion mode’ from FHEM and then doing whatever is needed on the device.

I would recommend doing the latter, as then FHEM will automatically pick up and configure the devices for you. I now have a variety of Fibaro devices and a Minimote which are all available as devices in FHEM with a lot of detail about them. I have recreated a few scenes which I was using before (such as one which turns on a few table lamps in the front room).

Now I need to find a better way of integrating with the alarm. I am using an Arduino with one of the outputs from the panel to report whether the alarm is set or unset and therefore whether the house is occupied or not. I’m using this at the moment to trigger a ‘notify’ event in FHEM which sets the heating into low power mode and now sends Z-Wave events which turns off all the lights. What I would really like is to get FHEM to interface directly with the panel to read out the status of the sensors etc directly. I have been able to get some information about this so I am going to see if I can learn how to do this.

As always I’d be very interested to hear from anyone else who is exploring this kind of thing.

6 thoughts on “Integrating Home Automation & Alarm

  1. What I’ve done is use a special Arduino firmware called ‘Firmata’ (http://firmata.org/wiki/Main_Page). This is directly supported in Fhem using a plugin, which then presents the various inputs and and outputs so that notify triggers etc can be hung off them.

    There are more details here although you’ll need google translate etc if you don’t speak German!

    https://wiki.fhem.de/wiki/Arduino_Firmata

    It sounds complicated but was actually dead easy to do, happy to discuss further if you need it

  2. No, at the moment it’s just a USB cable as the alarm box sits in the same place as the server. In fact I have quite a rats nest of wires coming out as there is another which does the fake ComIP and another on the other serial port. I’m sure that you can use an ethernet shield if you want to though. There might also be other approaches which would work, maybe using an ESP8266 or similar as well.

  3. Hi stumbled on your site, some interesting projects, the texecom stuff interests me most. Why did you chose FHEM? Have you looked at Hass.io? I have been playing with Hassio on a Pi with a lot of success, Hassio has a huge following, is free and simple to get running, i now have it integrated with my families mobiles etc for full accurate presense detection, cctv camera arm/disarm on time/presence, motion sensing, have it integrated with my orbit irrigation system, lights, windows blinds, other bits, my texecom alarm is the next project. I see some people working on this in the hassio community. Just thought worth mentioning to a tinkerer like you 🙂 I think i need a comip to go with my smartcom (unless you can install two smartcoms? which are cheaper than comip), i read your article on your home made one but didnt get impression it ever fully worked, and i need it to work. Enjoy, keep up the post Darren

  4. Hi Darren, thanks for the reply and the info. I used Fhem because at the time (10 years ago or so now!) it was the only system which supported all the different devices I was using and I kinda got to like its style although it is very low level and data heavy. It is highly flexible though, have always got it to do what I want but I definitely should look at other bits too. Do you need a COMIP as well? Can’t you just use the Smartcom for everything once it is on the network? My home made one did work basically fine, there are a couple of small issues but these didn’t affect it. It basically just converts a serial port into a network connection using ser2net and worked perfectly well once running. I’d recommend this if you need another route in but as before why not just use the one connection? The other option is the hardware solution, which was dead easy and has given me 8 outputs to play with which is enough for me, just got the back door sorted to turn the heating down when the cat goes out. Thanks for the advice, will look further!

Leave a comment