|
Home Automation
The
Intelligent Home
I've been building my Home Automation system up for several
years and it is now at a point where it is very functional.
I have control of lights, appliances and fans etc. from either
a web interface or RF controllers (wall mounted and handheld)
and the Perl based Misterhouse
package allows me to build up macros and base events on various
inputs such as whether I am at home or not. It even sends a
text message to my mobile phone if someone presses the doorbell
when I am out! Temperature sensors allow the home automation
system to turn the fan and soon the heating on and off depending
on the environment. CCTV, CallerID, voicemail, whole house audio
and MP3 playback and much more also play a hand in making the
automated home, read on for a more detailed explanation.
X10
Automation
X10
is a powerline carrier technology that allows devices throughout
the home to communicate with each other via the existing mains
wiring in the house. Using X10 it is possible to control lights
and virtually any other electrical device from anywhere in the
house with no additional wiring.
I
have an increasing number of X10 modules installed around the
house plus several wireless wall controllers and hand held remote
controls, a mini controller by my bed, motion sensors on the
stairs and a CM12U computer interface which is controlled by
a Linux box running Misterhouse.
See
a full list of the X10 Modules
currently in use.
Misterhouse
- Perl based house control software
The
Misterhouse web interface
offers easy point & click operation of X10 controlled appliances
& lights but Misterhouse is more than just an X10 control
system and has support for a huge array of automation, communications
and security equipment. Being Perl based you can easily code
your own events, macros and integrate it with other systems
etc.
I
have several macros set up so that on arriving home I can, for
example, press the 'home' button on the entry/exit wall controller
(an SS13E)
which
causes the computer to turn on the audio amplifier and welcome
me and announce if I have new email. On leaving the house I
press the 'away' button and all X10 devices are turned off.
This also allows Misterhouse to base events on whether the house
is occupied or not. Other macros include a 'going to bed mode'
which turns all the ground floor lights and the amplifier off
and turns on the stairs and main bedroom lights.
Controlling
the system
Next
to my arm chair in the lounge I have a 12" Touch Screen
PC which gives me control of the Misterhouse web interface (screenshots
of my system). Elsewhere in the house a 18 button X10 RF
remote control or one of the 3 button wall switches allow remote
control of various functions. I can also pick up any phone extension
and dial certain extensions to turn lights & appliances
on and off.
In
the hall and at the top of the stairs are RF motion sensors
with built in light sensors that turn the landing/stairs light
on for one minute if it is dark when it detects movement. These
units also have several other possible uses in the future including
detecting somebody approaching the front door and warning me
audibly so I can view the front door camera.
I also have web access to a Bittorrent download manager, Uninterruptable
Power Supplies Status, Wireless Access Point config, Firewall
config, Xbox Media Center, Website Stats and Bandwidth Stats.
Out
of the House Control
If I am out of the house I can log in to Misterhouse using my
O2 XDA IIi PocketPC
Phone or from any other internet connected computer using
http, https or ssh. When I dial home from my mobile I get a
menu which allows me to listen to my voicemail and to turn lights
& appliances off by dialling extension numbers just as I
can internally.
X10
Wireless Door Bell
I
modified a KR19
RF keyfob to operate as an X10 wireless door bell by locating
two traces on the pcb that operated button 2 'on' and soldering
the two wires from the door bell push button to these traces,
hey presto: wireless X10 door bell. I used button 2 for the
door bell because button 1 can be used to program the codes
the remote control works on if held down. The remote control
is then located in the old door bell housing for one of my few
neat installations.
When someone presses the door bell misterhouse announces through
the speakers that there is someone at the door and logs it to
a file. If I am out (known from the entry/exit status) then
it also sends a sms text message to my mobile phone (using vgsmail).
1-Wire
Network: Temperature Sensing
I
use a DS9097U-009 Active serial port adapter and two DS1920
temperature sensor iButtons
(one indoors, one outdoors) to log the temperature. This information
is then available through the misterhouse web interface as
a log and a graph (courtesy of gnuplot)
and is also used to turn the fan in my computer area on and
off depending on the temperature. The plan is to connect an
X10 module to the central heating thermostat input so that misterhouse
can also control the heating based on the temperature information.
Dalsemi
have some Guidelines
for Reliable 1-Wire Networks online and there are several
iButton
related discussion groups
CCTV
System
The
CCTV system consists of a cheap TE104
/ Pico 2000 4 channel Digital Video Recorder card and four
cameras. Camera one is a wireless colour camera with nightvision,
it faces down the front path from above the front door. Camera
2 is a mono camera mounted inside the front window giving additional
coverage of the front door. Cameras 3 and 4 are both wired colour
cameras with night vision, one giving a view of the rear yard
and back door and the other an internal view of the computer
area.
The
software I'm using is the Linux based Motion
package which has motion detection, live streaming, mpeg recording
and much more. The cameras are only recorded when there is motion
which is very handy and saves a lot of disk space. I've also
set up a web interface
which is accessible from within MisterHouse and allows viewing
of single live cameras, quad view or recorded events. You can
have up to 4 of these cards in one PC for a total of 16 cameras
so there is plenty of room for expansion.
Telephone
System
I
used an external Pace Voice modem and VOCP
running on Linux as my voicemail
system for some years but have now switched to Asterisk,
the open source VoIP PBX.
I have a Digium FXO
card for the connection to my PSTN line, phones are a Grandstream
IP phone and pair of DECT cordless phones connected via
a Grandstream
Handytone FXS gateway and a Sipura
3000 FXO/FXS Gateway. I also connect from work using the
iaxComm
IAX client, which allows me to answer incoming calls from work
using a handset connected to a sound card.
Asterisk is very powerfull and has huge potential for home automation,
features include music on hold, call parking, speaking clock,
alarm calls and so on (Asterisk
features). I've also got a load of extensions set up which
allow me to control X10 devices from any extension, for example
dialing 21 would turn the lounge lights on, dialling 20 would
turn them off.
I
can also dial out through FWD,
IAXTel, VOIP to PSTN services
like Telappliant's
VoIPTalk or PSTN from any phone. I also have a free 0844
local rate number diverted to my FWD account courtesy of VoIPuser.
When
a caller leaves a voicemail message it is encoded as a wav file
and along with the caller ID is then emailed to me at home or
work depending on the time of day. A text message is sent to
my mobile phone containing the caller ID and the length of the
message and if I ring home from my mobile I get a different
menu than normal callers get from where I can listen to the
voicemail. Voicemail messages are also available via any IP
phone.
Caller
ID
Caller
ID is handled by Asterisk and by a TV
Messenger Caller Display unit (right) which overlays the
caller ID onto your TV screen and can also store up to 40 names.
The latest firmware for my Grandstream IP Phone has also added
a new ring tone which reads out the callers number.
Note
for any UK users, there is now a patch
available for asterisk & zaptel to allow the Digium
cards to do UK caller ID. As the web page says, it "just
works".
TV
& Audio Distribution
The main audio amplifier is located in the living room next
to the main TV and can be powered on or off via X10. This feeds
sound to four sets of speakers covering the ground floor, currently
there is a separate amplifier upstairs but I plan on connecting
the upstairs speakers to the main amplifier at some point. All
audio goes via my main PC before reaching the audio amp so that
system sounds, email announcements etc can be mixed in over
the TV or music sound. This also means that I can control the
volume and mute inputs etc from the misterhouse web interface
or via the X10 remotes.
I have a four output TV distribution amplifier which feeds video
from either the terrestrial TV antenna, a TiVo box, a Sky Digital
box, a freeview box, a video recorder, a DVD player or an Xbox
running XBMC. This
then outputs to the main TV in the lounge, the TV tuner in my
main workstation PC, the Silicon Graphics Indy alongside my
main workstation which I watch most of my TV from and the bedroom
TV.
Music playback is in the form of MP3, using XMMS on my main
PC with control also available via Misterhouse or X10 remote.
Barcode
Reader
I
have a Datalogic
DLC7070-M1 barcode reader with the keyboard wedge interface.
I've put together a database to keep an inventory of food &
drink so I can do automated shopping lists a la icepick.com,
simply scan items before throwing away the used packet and you
have a computer generated shopping list. This was one of those
things that was fun to set up but doesn't actually get much
use in reality.
Computer
Network
This runs throughout the house and consists of 10-Base2 (coax),
10-BaseT (cat 5) & 802.11b (wireless) networks, more information
is available here. The home automation
server itself is a lowly Pentium 200 running Debian GNU/Linux
and also serves as the mail, news and backup server. Misterhouse
monitors several important services running on several machines
and will send a sms text message to my phone if anything goes
down.
Security
I have a stand alone professionally fitted hardwired security
system with communications, however I won't be going into any
more detail here for obvious reasons but needless to say as
I work for a security company I don't have any worries on this
score!
The
Future
Some of the projects I have planned for the future are:
- Heating
Control
- I already have some iButtons
to detect temperature so the next step is X10 control of the
combi boiler via the thermostat connection. This will give much
better control of the heating than the built in timer and will
allow features like a 'boost' button on a remote control to
tell the heating system to stay on for an extra hour if I'm
staying up late.
- TiVo
Web - Install TiVo Web
and ideally a TiVoNet card to give web control of the TiVo.
-
LCD
Displays
I've bought a HD44780
based 4x20 blue lcd display from Milford
Instruments, I plan to use this with LCDproc
which is a client/server LCD program for Linux. As well as some
built in functions there are also many other clients
available and misterhouse also has LCDproc support.
Any of the many LCDproc clients can be used at the same time
and the LCDproc server will swap between the displays.
I've also found another source for some less useful smaller
(but much cheaper) displays here.
- Electricity
Consumption Monitor
I stumbled across this
page which describes a simple method to monitor your electricity
consumption if you have one of those electricity meters with
a flashing LED.
- Washing
Machine Monitor
I frequently put a load of clothes in the washing machine and
then forget about them. It would be usefull if I could have
an announcement from Misterhouse when it has finished its cycle.
Two methods spring to mind, a current sensor or a light sensor
to detect when the power light goes off.
- 1-Wire
Addressable Switches
As I already have the 1-wire network it makes sense to use some
of the Dallas 1-Wire Addressable Switches such as the DS2405
or DS2406.
These devices can be used as an input or can drive a relay for
control purposes. Many possible uses for this.
If more input/output options are required there are other possibilities
are the Weeder I/O Boards,
the Velleman
K8000 Board or something
simpler.
- IR
Control
An infra red sender would allow the home automation system to
have control of any infra red remote controlled devices. One
option is RedRat or maybe
something home
made
- 7"
Touchscreen - A Mini-ITX PC connected to a 7"
TFT Touchscreen with VGA input would make a nice compact,
quiet controller.
- Cybiko
- I have a Cybiko Extreme which I picked up for experimental
purposes but hasn't really found a use. Using a second Cybiko
as a gateway these have the potential
(more)
to be used as a wireless HA controller. Cybiko's are currently
available from CPC for £15
for the classic and £20 for the Extreme.
|