US Home

(Last updated: Monday Sept. 07, 2009)

Complete Home Control with Mr. House

Disclaimer: None of the opinions expressed on these pages are paid for. They are strictly those of the authors' and may not represent an endorsement of someone's project, product or service (unless otherwise stated so).

Links to commercial web sites contain useful information that the authors thought may be useful to the readers. These links tend to be vendors that the authors have used and had good experiences with. Before purchasing any product or service please investigate your purchase properly.

Originally this document was called "24 Days to Complete Home Control". While the name is not a bad one it no longer represents what this document covers. It's still related to Home Automation but it skewed toward MisterHouse and what needs to be covered there.

Also check out the Misterhouse FAQ and Wiki.

A Geek's guide to MisterHouse

Table of Contents


If you're reading this document and getting confused I apologize. I'm trying to putting this together in a book format but written in HTML. So far it's a real mess. I've written one book (Linux Smart Home For Dummies) but this one is written on the side and in my spare time. Also I'm a Linux user, my Mr. House setup under Linux.

So what is home automation? Is it controlling lamps and appliances? Is it your phone system (answer machine, voice mail, access to to home automation controls)? Is it controlling your entertainment system? Is it monitoring your security system? Is it power monitoring? Is it information processing? Is it handling security? Is it networking? Is it something else? Uhm, yes. :-)

Day 0 - Introduction to MisterHouse (aka MH)

Welcome to our attempt at making Mr. House easier to install, setup and run. MisterHouse has a very steep learning curve mainly because there is so much you can do with it. It's extremely flexible but with this flexibility comes confusion as to where to start. This document will give you that starting point.

This document is in no particular order other than starting with the requirements, installation, and using X10. After that it's in random order.

What is MisterHouse?

MisterHouse is an open source home automation program. It's fun, it's free, and it's entirely geeky. MisterHouse (MH from here on in) is written in Perl and runs on Windows 95/98/NT/2k/XP/Vista and on most Unix based platforms, including Linux, BSD, and Mac OSX. It's even been ported to a VAX (a large mini from the 1980's)! At the core, MH is a huge set of Perl programs for device, time, event, web, socket, and voice based monitor and control functions.

MH was originally conceived of by Bruce Winter in late 1996 [Timeline] as a way of using his computer to interface with X-10 modules. Over the years, Bruce and others have added a myriad of additional functions and features. The mailing list is teeming with new additions weekly as well.

MH has support for devices from around the world. In addition to X10 (a rather extensive list of devices) MH supports:

  • Insteon
  • UPB
  • network device (such as the Elexol Ethernet IO24 board)
  • serial devices (such as the K8055 IO board)
  • Music players
  • Security systems
  • Caller ID
  • Telephony
  • 1-Wire/iButton devices
  • Thermostats
  • Irrigation
  • Internet connectivity
  • Email
  • SMS
  • IM
  • ... and many other devices and services

What is Home Automation?

Home Automation (or Domotics) is automation specific to the requirements of private residences. It applies techniques for the comfort, security, entertainment and communications needs of it's residents. In simplest terms it is control and monitoring of devices and information.

  • Lighting and appliance control
  • Heating, ventilation and air conditioning (HVAC)
  • Energy/Resource management
  • security and access control (SAC)
    • Doors and windows control and monitoring
    • fire alarm (FA), fire, life, and safety (FLS)
    • CO alarm
    • Flood/Water Alarm
    • Thunderstorm/Tornado/Weather warning
  • communications (voice and data)
  • Entertainment control
  • information processing

What can I control and monitor?

Well I can only give you a sample here of what you can control. First off the most obvious things are the X10 modules. Up to 4096 different codes (256 using regular X10 codes) can be monitored and controlled with the CM11A. For less than $50 (US) every room in your home can have a iButton tempature probe that MH can monitor and graph. MH can download you favorite comics in time for morning read. MH can be programmed to remind of you of events by playing sounds or music. The list goes on and on. There will be more on this later in this section. Also other X10 interfaces are available and other interface to different protocoals such as EIB, UPB, Insteon and Z-Wave are now available.

What knowledge do I need to know?

First and foremost you'll need the willingness to learn. MH has a very steep learning curve because it is flexible and only limited by the computer resources and your imagination. Hopefully this documentation will help to make that learnign curve less steep.

As an installer and admin ...

As an installer and admin you'll want to be familiar with Linux and Perl. For simple control and monitoring this document, the Wiki, the MH Documentation and the MH mail list will suffice. For more advanced topics, there are many books on the topic.

Because MH is a DIY program you should know Perl or at least if you don't know it you'll need to learn to program in Perl (5.6 or better but not 6.0). So a programming background is probably a good idea. O'Reilly Books has plenty of excellent Perl books. In addition you'll need to understand the OS you're working with. Administration privileges are a must as you'll probably need to install device drivers or start services at some point. Also it's more than a good idea to know how to use Virus and Firewall software for your OS.

As a user ...

As a user of MH there is not such a steep learning requirement. Familiarity with your native browser is all that's needed and a little time to familiarize yourself with the web page layout.

Minimum hardware requirements

Since Perl runs on many operating systems and different CPUs I can

  • PC - Any modern PC, Laptop, or Desktop. Many users will use the common and abundant x86 based computers. But even older Vax 3100's and Sun IPX's can run MH. Older hardware may be slower and limited to what forms of I/O are available. For this howto document we will limit our discussions to the more modern WinTel PC's. Minimum requirements:
    • CPU - 386 or better. Faster is better as well as more modern (Pentium, Athlon, etc).
    • RAM - 32M or better. This really depends on your OS and what you have running on the system. Programs such as voice applications will require more RAM and a better CPU. MH really likes memory.
    • Serial port - It doesn't matter if it's USB, ISA/PCI Buss card. or directly on the motherboard. But it needs to be capable of 4800 baud.
    • Disk - This is OS dependent but in addition to the OS's requirements I'd recommend an additional 150M of disk space to be safe. MH 2.95 decompresses to approximately 26M, the mh_misc file decompresses to approximately 36M.
  • OS - Without getting into a religious war on OS, MH is designed to run on any OS that can support Perl and the CPAN libraries. Currently we know it runs on MS Windows 95/98/ME/NT/2000/XP, Linux (any distribution), Mac OSX, BSD, and *nix. I've been told that someone had MH running on a Vax and VMS.
  • MH Software - Unix users (Linux, MAC OSX, BSD, etc.) should pull down the tar.gz files. Windows users should uuse the .zip file. Bruce posts the dailies as .zip so Unix users will need to convert them from DOS format to Unix.
  • CM11A - We need to start somewhere and this is apparently the most common device. Future versions of this document will provide information on using a differnet interface.
  • X10 Modules - A nice appliance module or lamp module will do fine. Don't use the TM751 as the CM11A can't control it.

Recommended requirements

  • PC - Any modern PC, Laptop, or Desktop. Many users will use the common and abundant x86 based computers. Desktops or Tower PC work best as they can handle additional boards (PCI prefered). Laptops work well also an have the advantage of a built in battery backup. I/O requirements can be handled by PCMCIA cards and USB. For this howto document we will limit our discussions to the more modern WinTel PC's. Recommended requirements:
    • Monitor, keyboard, mouse - OS & motherboard dependent.
    • CPU - 586 or better (Pentium, Athlon, etc). at least 350MHz.
    • RAM - 128M or better. Programs such as voice applications will require more RAM and a better CPU. MH really likes memory.
    • Internet connectivity - either dial up (requires a modem card or external modem and USB or serial port) or some form of broadband access (requires an Ethernet card, xDSL card or USB interface).
    • Serial port - It doesn't matter if it's USB, ISA/PCI Buss card. or directly on the motherboard. But it needs to be capable of 4800 baud.
    • Disk - 250M of disk space, if you plan on doing MH development, at least 1G.
  • OS - Without getting into a religious war on OS, MH is designed to run on any OS that can support Perl and the CPAN libraries. Currently we know it runs on MS Windows 95/98/ME/NT/2000/XP & Unix.
  • Virus protection software - Currently the *nix family doesn't need this. But for the Windows users I'd whole heartly recommend getting, using and keeping it up to date. You may not have a problem with your machine being a Zombie but everyonce else will (one day I'll post a rant on this very subject!). Unix users it is recommended that you do as little as possible as root. It is possible and recommended to run MH as it's own user.
  • Firewall software - Both Windows and Unix users should take full steps to limit access to their machines from the outside world. Also keep up to date with program and system updates. They help to keep your machine running smoothly.
  • External Firewall - Yes I recommend using a good external firewall. It will limit the amount of useless probes from the outside world and keep local traffic (especially Windows SMB traffic). This will allow your home network to run smoothly.
  • A network switch - a switch is better than a hub most cases except for when you need to use a network sniffer to figure out what is goingon on the network. Most people have no need for a network sniffer. Many Firewall now come with a built in switch.
  • MH Software - Unix users (Linux, MAC OSX, BSD, etc.) should pull down the tar.gz files. Windows users should uuse the .zip file. Bruce posts the dailies as .zip so Unix users will need to convert them from DOS format to Unix.
  • CM11A - We need to start somewhere and this is apparently the most common device. Future versions of this document will provide information on using a differnet interface.
  • X10 Modules - A nice appliance module or lamp module will do fine. Don't use the TM751 as the CM11A can't control it.

What is Home Automation?

This is a question very enthusiast tries to answer when they setup their HA system. I've never really received a good answer. Let me sum it up this way. It depends on your needs ...

Here is what I consider HA: the control and monitoring of personals device and information, usually found in the home.

What is X10?

X10 is many things, it's a power line communication (PLC) protocol, it's a line of X10 PLC products, it's a line of it's a group of companies who manufactures, sells and markets X10 products. The original products were based on X10 PLC products that uses the X10 protocol. Newer products include the older products, newer RF products and other products. Yes, I just found that they had an Olympus digial camera for sale.

Without getting too technical, the X10 protocol is a method of communication that rides over the home's electrical wiring. It was originally designed for Europe's 50Hz eletrical system but with a few modifications works just as well with the US's 60 Hz system.

For those of you who are interested in further details there is Uncle Phil Kingery's X10 Technical Series. For a review of X10's history check out Digital X-10 article.

What's available to me?

OK, now we get to the fun part of MH. There are a lot of thing available to you to use with MH. I probably won't be able to list them all here but I'll try to cover various topics so you can at least get a general idea of what is available to you

Please understand that if you can figure out a way to hook it up to the computer we can figure out a way to access it with MH.

Control Lights

  • dusk to dawn, minutes before after dusk/dawn, motion only
  • when you are not at home keeping the lights on longer
  • vacation schedules

control appliances

  • warm your bed

measure temperature

  • iButtons

control heating and air conditioning

pool control

  • pumps, timers, testers?


  • get your mail
  • read your mail to you
  • filter mail
  • Advise you of weather alerts
  • page you
  • call you
  • filter some spam

get the television schedule

  • record your television shows on vcr or tivo or computer
  • change your channel on TV / VCR

Monitor your telelphone

  • log outgoing telephone calls
  • log incoming telephone calls (caller ID)
  • wake up your computers
  • monitor electronic equipment

  • put your computers to sleep
  • back up your files
  • get your stock quotes
  • advise for weather alerts
  • track computer/television usage
  • make sure doors / windows are closed/locked
  • be your voice mail box
  • remind you of important occassions
  • track last time you did things
  • monitor equipment / watchdog turn off / reset if not responding
  • remind you to do things on a re-occuring basis
  • log where your cars are
  • send messages to your IM account or cellular phone when predetermined things happen

Monitor/log events with the Wireless HomePlate Stick-on Wall Switch (RSS18)

Here's the start of an outline I put together a while back for the Wall Switch use:

I have used the Wireless HomePlate Stick-on Wall Switches (RSS18) for some time now. They can be set to transmit on and off for three consecutive X-10 signals. You can program MH to grab these 6 signals to turn on & off three different devices, or you can also have MH do 6 different things. Here are some ideas of what you can program them to do or keep track of:


  • Last time chemicals checked
  • Last time chlorine added
  • Last time filter was backwashed

- Of course I plan to do simple reminders when I haven't done these steps within a certain timeframe. I also plan to have MH track how long it actually takes before these things are needed. This may involve hooking in to the weather data as chlorine usage goes up in warmer weather, etc.

  • Laundry Room
  • Need more laundry supplies (send reminder email)
  • Need more dogfood (send reminder email)
  • Washer started (start timer)
  • Dryer started (start timer)

Around the House

  • All lights on/off
  • Grandfather clock wound for the week
  • Heater filter changed
  • Houseplants watered
  • Medication taken (for those who need to remember to take meds on time)

HVAC Control

In theory, note at this time I am un aware of any MHer who has implemented ALL of these items, you can employ iButton temperature sensors (e.g. DS18S20, DS1920) to monitor individual locations around your home and property. For example two in the living room, one in the TV room, each bedroom, the kitch, he bathroom, the hallway, rooms in the basement, the furnance, inflow duct, the outflow duct, your garage, and of course outside.

Using some of the HVAC codes as a base in mh\code\common, you can turn your AC/heating system on and off based on those temperature readings instead of relying on your thermostat. Note: it is recommended you wire your system in series with the thermostat incase of a MH failure. E.g. failsfe the thermostat at 55 and 85)

Further control can be achieved by using computer controllable dampers and say a Weeder I/O board to control those motors. You can make your owned Zoned heating system integrating in the information from the optional code.

Day 1 - Generic Installation

Now we're going to setup MH to use the CM11A to control an X10 module. I'll try to provide the links and other items so you can 'fill in the blanks'. I won't go into installing Perl. Bruce has a very good documentation on installing MH and Perl on Unix and Windows.

Hardware Installation

Before we start it is assumed that the PC is setup and running properly with the OS of your choice and that any of the device drivers that you may need have already been installed.

  • Connect the CM11A to the serial port. Note the location, on Windows this maybe COM1, COM2 (both tend to be on the motherboard) or some other serial port (USB and additional serial port boards). Under Linux COM1 is /dev/ttyS0, COM2 is /dev/ttyS1. Other devices will have different designations. Check the readme file for the device, check the /usr/src/linux/Documentation/ directory for Readme files or do a google search on Linux and the board you are using.

    Mine is /dev/ttyM00 (Moxi board)

Software Installation

... Download, install, download, install...

  • Download MH. Generally developers will want to work with the source code versions of MH. So for Unix download the .tar.gz file and Windows should use the .zip file. If a Unix user downloads the .zip file then they may need to convert a few files from DOS to Unix in order to get MH working. Compiled version ??? The MH MH test code is a zip'd source file so Unix users will need to convert the mh.ini to make sure it works properly.
  • Uncompress MH - Windows users will unzip the zip file. Unix users will be required to sue gunzip and tar to extract the files.


    Blah blah blah


    Blah blah blah

  • Download MH_MISC
  • Uncompress MH_MISC

MH Setup

...Walk through menus, disable everything, edit ini ...

  • Main screen (http://local:8080/)
  • Administration (MH, Home)
  • (Setup Mr House)
  • Turn on or off common code (Common Code Activation)
  • Turn on or off user code (User Code Activation)
  • Edit items, like X10(INI Editor)
  • Change configuration parameters (Item Editor)


... Setup X10 devices, iButtons, Comics, etc. ...

Day 2 -

Planning MisterHouse

Minimum Hardware

The core Mister House code will use between 10 and 30 Megabytes of memory. On Windows, the VR (Voice Recognition) function takes about 10 MB and the TTS (Text To Speech) function takes about 15 MB. On Linux, the Festival TTS engine takes about 20-30 MB of memory. So, with TTS enabled, on Windows you can get by with 32 Meg, but you will need 64 Meg or more to run with low speech latency. See FAQ question 1.2 for more info on memory usage.

The cpu time used -vs- loops per second is controllable. On a 100 MHz Pentium with a 100 ms sleep time, mh uses about 20% of the cpu and gets about 8 passes per second. Such a machine will experience occasional pauses in playback of MP3's with increased activity on the PC. Increases in RAM help sooner than a faster processor. Many enthusiatst purchase older dual pentium III boards to run as their home server with MH as a piece of the load. As a final note, a 166+ pentium with 64MB RAM, should be adequate for MH except for Voice Recognition.


For X10 a CM11A is recommended as a starting point. It is possible for you to use another device but with the steep learning curve associated with Mister House it easier to start with something that works and is well understood. I may have instructions that will help resolve this issue as the CM11A is starting to become a bit more scarce.

One thing to note X10 has a very poor protocol as it it is slow, there is no error correction, collision detection and no device feedback. In spite of these problems X10 has 1 thing going for it and that is that it is cheap (see the X10 troubleshooting section for tips).

Insteon Controllers

UPB Controllers

X10 Controllers

X10 Modules


  • Leviton RZC0P-1LW - Vizia-RF Plug-In RS-232 Interface for PC's/Automation Controllers
DeviceCapabilitiesX10 model number
Appliance moduleon/offAM486
Lamp moduleon/off/dimableLM14A
Motion sensor
FirecrackerDB9 serial port transmitterCM17A
PC receiverSerial port deviceMR26A
Computer interfaceTwo way controller TX/RXCM11A
RemoteInfrared (IR) and Radio Frequency (RF)

X10 Hardware Required

iButton Hardware Required

Digital I/O Hardware Required

-camera(s) (interface)

Existing resources
-Email account(s) 

Other Hardware
Mics mixers, speakers amps ...

- etc ....

What you want to integrate
Lights (may need seperate list, that could aide in .mht setup )
Weather station
Email Monitoring

Evaluate and assign hardware resources and making choices
Com1(ttyS0) - Cm11a
Com2(ttyS1) - Modem

Shopping/wish list (what I need to...)
Weeder DIO
thermostats (supported types listed and interface)
Multiport rs232 card

Setup Steps
Installing MH
getting Perl modules (list ea)
Selecting Common code functions (based on hardware from What you have)
Selecting Soft Common Code (adding functionality without hardware)


Day 3

Day 3 - Basic Installation of MH on Linux/Windows/Mac OSX

For future Automates. Here is the receipt for getting mh to run in the
background at startup on Mac OSX.  Other UNIX systems should be some what

As root create a new folder /Library/StartupItems/MisterHouse

Create and EXECUTABLE file called
/Library/StartupItems/MisterHouse/MisterHouse In it put:

. /etc/rc.common
export mh_parms=/Applications/MisterHouse/mh.private.ini
sudo mh -tk 0 > /Applications/MisterHouse/data/dump.log &

Create another file
/Library/StartupItems/MisterHouse/StartupParameters.plist  In it put:

 Description     = "MisterHouse";
 Provides        = ("OpenSource Home Automation Software");
 OrderPreference = "Late";
 Messages =
   start = "Starting MisterHouse";
   stop  = "Stopping MisterHouse";

Restart and look at /Applications/MisterHouse/data/dump.log to see if it
started correctly.

All this because the power when out for longer than my UPS lasted.

Have fun,

Day 4

MisterHouse configured for your home

I recently found a much better way to use MH (compiled version in
windows) as a perl interpreter for learning and testing perl scripts.
This is for newbies, maybe Day 2 for simple folk like me ;) Assuming
MH is installed and running ok.

Type up your perl script and save it anywhere


Get to the dir that has mh.exe in a DOS window  c:\mh\bin
Enter at the prompt: mh -run c:\mh\code\
remember CTRL + C will stop looping code.

Day 5

Day 5

Settings for Australia


Melbourne Location info
latitude  = -37.817
longitude = 144.967
time_zone = 10

Seasons info
#seasons=Winter,Spring,Summer,Fall          # Northern hemisphere
seasons=Summer,Autumn,Winter,Spring        # Southern hemisphere

Day 6

Day 07 TV GRID

Those are regular expressions. Just put "^Favorite show$" to match the entire string. I don't know what that would do to shows with an episode name after the show name. Well, actually I do know. It will not match that one. I have some of mine matching things with a ^ in front so that it matches shows that start with that. This is the case if you want something like "Walker, Texas Ranger" as there is a 2 part special on right now matching "Walker, Texas Ranger Part 1 of 2: Showdown at Casa Diablo". IIRC then that would match as the show name. So, the example would be: "^Walker, Texas Ranger" and that would match all of those shows, but no specials like "Making of Walker, Texas Ranger".

If searching for a specific title and you are getting more than you want: e.g. Monk and you are getting monkeys, use the term Monk: <-- note the colon that subtitles are always preceeded by it and it is unlikely you will see monk:es in the subtitles.

Day 8

Day 8 - Caller ID logging

YAC client

using IM to send the caller ID information

Net Caller ID *********
>  # NetCallerID Box
> callerid_port   = COM1
> callerid_name   = line 1
> callerid_type   = netcallerid
> callerid_format = (number only)
> When mh starts up, the callerid port is never created.
> I can create a serial port on com1 (serial3_port) but not a caller id
> port.  I have tried this on other com ports as well.
> Any idea what I am doing wrong?
> Thanks!

Those look like the right parms, same as I have.   Did you also enable the
common/ code?

This code is a bit different from other serial port code in that the serial
port is not opened until the user code is run, and by default there is not
errata saying it is opened.   If you run this:

mh -debug phone

You should see something like this in your console:

05/24/03 06:53:55 PM Calling Serial_match_add_hook
Telephony_Interface port open:  n=line 1 t=default p=COM3 b=38400 h=dtr
- creating line 1          object on port COM3

linux> diff ../mh/code/common/
> $cid_interface2 = new Telephony_Interface($config_parms{callerid2_name}, $config_parms{callerid2_port}, $config_parms{callerid2_type});
> $cid_item      -> add           ($cid_interface2);
<     set_test $cid_interface1 '###DATE12151248...NMBR2021230002...NAMEBUSH GEORGE +++'           if $state == 3;
>     set_test $cid_interface2 '###DATE12151248...NMBR2021230002...NAMEBUSH GEORGE +++'           if $state == 3;
<     set_test $cid_interface1 '###DATE01061252...NMBR...NAME-UNKNOWN CALLER-+++'                 if $state == 7;
>     set_test $cid_interface2 '###DATE01061252...NMBR...NAME-UNKNOWN CALLER-+++'                 if $state == 7;

Basically, I needed to remove the reference to the $cid_interface2 object.  This appeared
to be confusing things, since after I removed it, things started to work.  To be honest, I 
was thrashing with a few things, so it might have been something else.

I have these in my mh.private.ini file ...

callerid_name=line 1
caller_id_format=first last

Day 09 Getting MisterHouse to Speak

code/common/ speaks time each hour
code/common/ speaks time each hour

Day 10 HVAC

> How do you control the fan speed?  Eg. the physical connections there to do so.

    I used relays from Radio Shack mounted in electrical boxes to
replace the three way fan switch. An extension cord with the
socket cut off is wired to the relay coil. The cord is plugged
into the X10 Appliance module. Two SPDT relays are all that is
needed, but I used DPDT for both.


                       ------------  (low)
                      V (NC)
                                        --------- (med)
                      ^                |
                      |                V (NC)
                                        -------------- (high)

Attic Temperature Control

I have been reading the attic fan control slightly off-topic postings with interest. I have gleamed many useful insights on attic temperature buildup and ways to prevent it from the document I have a link to below. It comes from the Florida Solar Energy Center (FSEC) and is one of many interesting publications regarding saving on air-conditioning homes in hot climates. I have done two things to reduce the heat in my attic: 1) increased the amount of soffet and ridge vent area, primarily by adding soffet vents all around my house (Houston, TX). The ratio of attic floor area (A) to ridge+soffet vent area (a) should be about 1500 (A/a=1500). Builders aim for about A/a=3000 but the FSEC suggest doubling the vent area to get to a A/a=1500. 2). I have added radiant barrier foil to the undersides of my roof (stretched between the rafters). I bought several 1000 sq ft. rolls for about $90 each. Previous to installing the radiant foil, I installed several temperature sensors in my attic at various levels and installed a CdS photocell in my roof ridge vent to record amount of sunshine. I use MH to capture the temperature and sunshine data which I have been doing for many months now. I haven't reduced all the measurements yet but I would estimate that the temperature in my attic is about 25 degrees F cooler after installing the extra passive ventillation and radiant barrier foil.

If you're Air conditioning unit (air handler and evaporator) is located in your attic (common along the Gulf Coast), then adding insulation to your attic floor may not be the best way to reduce A/C costs. Another study by the FSEC compared FL residents who had A/C air handler/evaporator units in their garages vs. those who had them in their attics. Electric usage for attic-located A/C units where on average about 26% higher compared to those units located in the garage. The study indicated that the surface area of ductwork in an average size home is about 2000 sq ft (hard to believe) and the insulation is only R4 to R6. The greatest heat gain occurs where the delta-T is highest (between the super-heated attic and the cool (45 degrees or so) A/C air in the ducts. Insulating the attic floor will not reduce the heat gain that occurs between ductwork and the attic. If you can make your attic as cool as under a shade tree then you are in good shape. The study by the FSEC (posted below) demonstrates the advantage of a highly reflective roof to reduce incoming solar radiation and heat gain to the attic.


Day 11

Getting plotting going with MH

Downloaded gnuplot-3.7.3  something from

because I have patched my tar to handle gzip files

tar -zxvf gnuplot-3.7.3.tar.gz

cd gnuplot-
./configure --with-png=/usr/local/lib


su -

make install

stuff to go into winamp section
> You should be able to control winamp on any box, but we currently
> don't have
> the ia5 web interface setup to pick between more than once box.
> If you are using the httpd plugin, you can control control them
> all via your
> main mh.   See code/bruce/ for an example.
> Another option would be to run code like on each
> proxy, where
> the 'set the house mp3 player ...' commands point to the local winamp
> player.  Then use the web interface for that proxy to control its winamp
> player.
> Bruce

Day 11

Day 12

Day 13

Day 14

Day 15

Day 16

Day 17

Day 18

Day 19

Day 2

Day 21

Day 22 - Networking

Basic networking - DHCP, default routing, IP addressing






Day 23 - What's available?

Ya gots to know the protocols!

I worked with a gentleman, Rosie Grubs, who used to say "Ya gots to know the protocol!". That one statement is so extremely true. If you don't understand you can't use it to write your software or properly debug system problems.


X10 refers to many different things/companies. It's wired and wireless protocol and products, it's a marketing company who brought us their infamous popups to our browsers and it's also the company who sells us various X10 products. The problem is that everyone refers to each as just X10. Unfortunately X10 (all of the above) deserves some of it's reputation.

Our primary concern with X10 is the protocol and products. The oldest x10 protocol is the Power Line Control (PLC) protocol. It uses your home's AC to send commands to the X10 device modules. The X10 wireless protocol is a newer protocol but it can be tied into the PLC protocol and they can work together to control X10 modules. The good news is that X10 is not the only company that makes X10 compatible products. The X10 company's products are inexpensive and because of a lot of effort of the DIY/first adopters commuity it's products are pretty well understood. The community figured out how to keep it running reliably but not quite 100%.

X10 came to us in 1978 from the Scotish company, BSR. At the time it was an inventive design. It used an analog shift chip to shift the X10 protocol in to the end device and convert it to digital signals used by the end device. A single command to turn on or off a device too about one second (between 50 and 60 bps). This is just about the limit of tolerance for delay between issuing the command and the device reacting to the command. When a command is sent there is no acknowledgment from the device being controlled. This is called open loop (send and pray ;-). This led to X10 being unreliable so users often sen the same command twice just to be sure. The protocol and devices pretty much stayed the same until the early 1990's when the PIC chip became available (inexpensive and small micro-controllers). X10 then started to replace the analog shift chip with the PIC chip (the 16C57 I think). For home automation there wasn't much to challenge X10's price and simplicity. CEBUS came and went, it was too expensive for home use. LONWORKS did the same though it is use in industrial products. X10 seem to make no effort to improve X10 though it did come out with a wireless X10 protocol.

Though X10 was designed in Scotland, designed for 220Vac/50Hz it has mostly been sold in the US (120Vac/60Hz). Most of the X10 line has products that are designed for 220Vac/50Hz but they appear to difficult to find. Many times people modify the US products to fit their needs.

Today a lot of lighting and appliance power line control is still done with X10 but competitors have risen. They have comparable products, at similar prices but with a better protocol and are more reliable.


Insteon is one of X10's prime challengers. It's another PLC protocol though there is wireless support in the protocol. The controllers support both X10 and Insteon protocols. One of the things Insteon improved was the use of a closed loop protocol for the Insteon protocol. If you send a command the device being controlled will send an ACK (everything is okay), a NAK (not now I'm busy) or a lack (the device didn't get the command and no ACK/NAK was received). Second the protocol communicate as about 4kbps. Even though the message is larger the delay between a command being issued and the device reacting is much quicker. Many new products are appearing supporting the Insteon protocol. At this time Insteon only sells products that support 120Vac/60Hz systems. They are promising products for other electrical systems at a future date.


UPB is another PLC protocol, it has support for 120Vac/60Hz systems. It too is faster than X10 and uses closed loop communication. I don't have any UPB devices yet but I hope to order a few soon.


Zwave is strictly a wireless protocol, no support for power line communications. I don't know a whole lot about ZWave yet. It does use a closed loop system. I've ordered some ZWave equipment and hope to find a way to get it to work under Linux.


European Installation Bus, now known as KNX (Konnex), supports a number of methods of connecting devices together including the pwToer line, twisted pair and wirelessly. It's the world's first open, royalty-free and platform independent standard for home & building control, approved as a European (EN 50090 - EN 13321-1) and a Wordwide standard (ISO/IEC 14543).


Hardwire is a looely defined group. It could be devices directly controlled via your parallel port, a USB board, an internal I/O board, RS232 or multidrop RS485. As the name suggests the things being controlled have wires connecting the device being controlled to the PC controlling it. It's not really based on any protocol, though there may be a physical layer protocol such as RS232 or RS485.

Day 24 - Accessing MH from the outside world.

I'm sure, by now, you'd like to access MH outside your home. If for no other reason than to show off. :-)

Opening a hole in the firewall

SSH, vpns and tunnels

Day 25

Day 26

Troubleshooting X10

One of X10's greatest weaknesses is that it's a real pain to troubleshoot problems when they occur. And, unless you have a simple X10 setup, you will have problems.

Smart Home has a interesting page related to X10 Home Automation called the X10 projects page. Lots of links to things they sell but with info related to X10.

Here is a typical problem with X10:

Someone asks: Every house I have tried my X10 gear in has had a problem wherein getting signals to go across circuit breakers seems to be impossible. Or: Why does X10 only work in some parts of my house and not others?

Simple explanation:

The problem may be that your home may have 2 seperate phases being brought in from the street. Getting the signals from 1 phase of the AC to the other phase of the AC is impossible unless something is there to 'bridge' the 2 phases. The 2 phases are not connected together.

More complicated explanation (but still simplified so you don't need an EE or Electrician's License):

Normally you use 120 V AC in your appliances with the exception of things like driers, electric stoves, furnaces, large A/C units and some hot water heaters. For a small home the Electric Company gives you a single 120 V AC feed (up to 100 Amps). In my home I have 2 120 V AC feeds. They are not connected to each other, they are isolated by the transformer out at the street. Each 100 A feed is what I've been referring to as a phase. See the ASCII drawing below:

    Wires and
    transformer      Breaker
    on the            Box
            100 A   +------+           Wall
    ----)   Feed    | |  | |          Outlet
        )-------------+  | |          +----+
        )           | |  +------------|(||)|
        )----------------+ |          |(||)|
      +-)   100 A   | |  | |          +----+
      |     Feed    +------+
      v Ground             v
                      A  B

If you plug in an X10 device into 2 wall outlets that are on the same phase then they can talk to each other (skipping things like X10 black holes). But if you plug in an X10 device in an outlet on phase A and an X10 controller on phase B they won't be able to communicate because there isn't a path to each other. To get a path you need a signal bridge.

Why do we need to troubleshoot X10?

There are a couple of problems with X10 that makes it an unreliable protocol. The first is that it is an open loop control system. That means the signal gets sent and no confirmation that the signal was received (you don't know if it got there). The second has to do with the design of US homes or any other home that uses more than a single phase electrical system (the phases are not coupled). The last problem is that many appliances, such as TV and entertainment system tend to filter any signal other than 50/60 Hz to ground.

There is no easy fix for the first problem other than redesigning the protocol.

The second is easily fix by having each of the phases coupled with a signal coupler. A qualified electrician can install it very easily.

The third problem requires the user to sit down and trace out all the appliances, one by one. Applying a filter to each that act as a 'black hole' for X10 signals.


  • A map of your AC panel
  • A device you can send continous X10 signals.
  • The ELK EMS-1 (ELK signal meter).



    0) Trace out your AC distribution panel. Usually 1 breaker space is
       a phase and the other is the other phase. This is on typical US
       Homes with 120/240 systems with 200A service. I'm not sure of
       other setups.
    1) Get an ESM-1 (ELK Signal meter), ~50 + S&H
    2) Use the ESM-1 to figure out which devices are causing your signal
       loss. You do this by unplugging all the devices on a leg and
       checking you signal strength. Add each device, individually
       and recheck you signal strength. This will help single out X10
       'black holes'.
    3) get some plugin or inline signal filters and apply as needed. I
       would recommend another vendor, such as ACT-Solutions over X10.
       Watch the ratings (usually the Amps).
    4) If the problem is across phases you usually need an X10 phase
       coupler (signal bridge). On larger homes (2000+ sq ft) you
       may need a phase coupler/amplifier.

    x) In case your problems are caused by a dimmer, you may need
       to replace the dimmer. Dimmers cause noise though to don't
       mimic X10 signals they can cause some X10 devices to trigger.
       I believe that this is caused by the X10 device's poor design.

For more information on noise and filtering check out 4 articles from Uncle Phil:

MisterHouse at James home:

I have MisterHouse running on a linux server in the garage. My current setup is not nearly complete, I am still trying to figure out just what I want it to do. I have it setup to send a text message to my phone when anyone comes in the front door after the house has been empty (no motion) for a period of time. I can tell when the boys get home from school and give them a call. When on vacation I can tell when the cat and gecko were being looked after. I also have the front porch light set to turn on at dusk then dim to about 40% after 5 minutes. When motion is sensed at the front door then light will go to 100% then dim back down after a time limit. After dark the livingroom and kitchen lights turn on when motion is detected then turn themselves back off. I have the Smarthome light switch with the 8 buttons in the livingroom and master bedroom. Everyone needs one of these. It is a 2way device and you can program each of the 8 buttons to send an x10 command. I have one that operates the local light, one for turning all lights on, one for turning all lights off. I have one programmed to tell (speak) me the current weather forecast via my Audrey in the livingroom and one that sets movie mode (dims the livingroom light, turns off the kitchen lights and dims the foyer light). The neat thing about this switch is that each button has a status led that will also turn on when it sees the x10 code assigned to it. From the bedroom I can look at the light switch and tell what lights are on around the house.

When I wake up in the morning and walk into the livingroom I am greeted with a 'Good morning James, todays weather conditions are ...'. The practical application has to do with my wife. She was in an accident last year and is now paralized on the left side. She can't turn over at night (pressure relief) so I get up a lot during the night to take care of her. I have two lamps in the bedroom using 2way x10. Anytime I get up they will brighten so I can see what I am doing. After midnight only the one near her turns on to about 30%. I just get back in bed and they turn off in a few minutes. I also tied on of those rf remotes to the right side guard rail so she could press it if she needed me (she takes long naps during the day). I have it programmed to send a text message to my phone and blink the bright green light on top of the livingroom Audrey so whoever is in there can check on her. On night I decided to try and lay her more on her stomach than her side (kind of half on side / half on stomach). She said it felt good. I was in the room for awhile when I got a phone call and went to the livingroom to talk. After about 30 minutes the green light on the Audrey started to flash and I got paged on the cell phone. I ran into the bedroom to see what was going on. I usual casually check on her but this was different. When I left she was in the middle of the bed facing the left side and the guard rail was down so that the remote was about 4 inches below the mattress top. I knew there was no way she could reach it. It turns out she had managed to roll completely on her stomach and her head was facing the right side and she managed to get her arm out from under her and reach the remote. She was in pain (she was laying on her stomach tube) and out of breath. She told me she was very glad to see me. It took her a few minutes to recover, she must have been struggling for some time to be out of breath like she was.

MisterHouse at James's Driveway

Here's one little part of my mh setup that my non-techy friends are pretty impressed with and my wife really likes. Using mh, I can track/record all vehicular traffic in my driveway and get audible indications of visitors before they knock or ring the doorbell(sometimes those extra seconds really count ;-)).

When I built my house, I had a Cartell vehicle sensor buried in the middle of the driveway. The device is very sensitive, the kids skateboards will trigger it. The output is a simple relay closure that runs back to a weeder board, that tells mh a motion event has occured.

Mh immediatly tells a Hauppauge video capture card to capture an image via Sendkeys. The camera it captures is pointing at the sensor in the driveway. It stores this image in mh's local web space. I have a custom web page that auto creates thumbnails using nconvert and displays the last 5 images captured so they can be viewed from one of the many computers or Audreys sprinkled around the house.

Mh then copies the image to a mh-proxy machine for future ftp'ing. Then it turns on the garage coach lights if it is dark out, they are the soft-start kind that ramp up for dramatic effect. Then it tells another weeder channel to pulse a unique doorbell chime via my NuTone intercom system. The camera is also modulated to channel 82, so once I hear the chime, I can just change channels or look at a dedicated monitor in my office to see who is approaching in real time.

Meanwhile, once per minute, the proxy mh checks to see if there is a new image to ftp. If so, it checks to see if the Net is up and if it is, ftp's it to my publicly viewable(but password protected) website. Again, a custom webpage auto-creates thumbnails when it is viewed. So If I am away from home, I can still check to see who has been coming and going.

I plan to add the 'mh commands via email' functionality to this, so when I am away, I can tell mh to take a picture so I can see what the weather is or what is happening in the driveway. I actually burried 2 tubes about 10 feet apart, so in the future, I could tell if a car was coming or going. Maybe if we can prefect a vehicle id system, I could have it open or close the garage doors if one of my cars is coming or going.

MisterHouse at Alan's home

MisterHouse at my home runs 24x7 on a Linux box (LFS 3.3) which
    Cyrix 333 processor
    128 Megs SDRAM
    Amptron 9100C Integrated MB
  	SIS 630 Chipset
	integrated Audio (used)
	integrated Network (not used)
	integrated Video
	single serial port
    Fujitsu IDE HD's 10gb, 4gb
    6 SCSI CD ROM drives
    Adaptec 2940 Scsi card (moving to 19160 or 29160 soon)
    STB 4Com multiport serial Card
        port 1 - empty
	port 2 - iButton network
	port 3 - empty
	port 4 - non functional?
    3Com 10mb ISA network card
  	connects to Qwest DSL modem
    D-Link 520TX+
  	connects to 10/100 switch

Layout: 1955 rancher with a full basement. Main floor entry to living room with dinning nook, kitchen, hallway to 3 bedrooms and full bath.

Downstairs has stair landing, laundry room, half bath, two non egress bedrooms, and a greatroom. Attached to the house is a garage with no access from inside the home.

A motion sensor at the front door causes MH to announce movement anytime in my office from the main box and log it. After dark, a lamp module turns on an inside light from motion on the front porch and dims it to approx. 40% for 5 minutes. At the moment the code to make the lamp stay on if it was already on seems to be2 broken. If it is day time no lights come on for the front door motion. There is a motion sensor on the side of the basement stairs that has gotten pretty reliable now, say 90%. I hope to bring that up to higher spec with a new antenna I am constructing for my BX24-AHT. A second motion sensor in the landing room between the two exit doors there causes the lights to come on when you have been downstairs long enough for timers to run out. I have the lights stay on longer in the morning than other times of the day.

The great room has a Leviton 6291 controlling flouerescent lights, a pair of motion sensors (MS13a and a SP561) monitor this room and leave the lights on for motion. MisterHouse resets a timer whenever there is motion in the room, after expiration the lights are turned off.

I have also installed a sensor in my wife's scrapbooking room, but a noisy PC power supply in another room blocks the X-10 signal to her phase. I place to purchase another XPPF to filter that PC off the powerline. This will turn on a compact flourescent that is a task lamp and allow for quick in and out trips.

My kitchen has a stick a switch and uses a Leviton 6291 for it's flourescent lamp, the stick a switch is not being received by my BX24-AHT at the moment, another item I hope the new antenna will remedy.

I have a 8 temperature iButton network, one outside in my phone box for outside temperature, one in the bathroom, one in my daughters room, one in my furnance room, one in the return air duct, one in the outgoing heat duct and one in the living room. I hope to integrate them into a HVAC system using zoning in the future.

Additionally I have experimented with a power meter counter and have a new phototransistor to try in the circuit that pulses a pin on my parallel port.

MisterHouse at Neil Cherry's Home

Here's what is MH software currently running on the 350MHz (& 486 & AMD 450) :

	AMD 350mgz
	96MG Ram
	2 Audrey's (1 with caller ID)
	several X10 modules
	print server (hardware)

Current Hardware in waiting:
        Celeron 1GHz (w/RH 9.0, MH 2.82 & Perl 5.8)
        HCS II (work in progress).
	LabJack (just got the USB driver working)
	Ninja Pan-n-tilt & Cameras
	Palm Pilot (currently a work in progress)
	Tivo (currently offline for home rewiring)
	RS485 interface & P89C51RD (RS485 & Sprinkler system)
	USB Cameras
	Ibutton (Dallas 1 Wire)
	USRobotic's Voice/Fax/modem	

	Redhat Linux 7.2
	MH 2.73
	Perl 5.60
	Festival speech engine
	tinydns & dnscache
	print server (CUPS via Samba & lpr)

	http (Apache & MH)
	router monitor
	Abbot-n-Costello (currently a work in progress, program monitors MH's
                         health and restarts as necessary. Why because I can't
                         get MH to restart it self properly).

Currently I have my Zyxel Prestige 310 router (same as the Netgear RT311 except the Zyxel router has SNMP) monitored by pings to determine if a software lockup has occured. But because ISP's have threaten bandwidth hogs with extra charges I'm using the SNMP to monitor the total number of bytes on a daily and monthly usage. I can monitor other things but I haven't figured out what I want to monitor.

Second one:

This one is a bit complex, it involves my central print server queueing up jobs for printers that are attached to HP ethernet remote print servers. The printers themselves are connected to an X10 module to control the power to the printer (not the remote print server). The HP server is SNMP pollable and I can find the current status of the printer such as offline, out of paper, error cleared etc.

My 10BaseT hub is also SNMP manageable but I haven't spent any time trying to poll it's variables.

I've modified my printer scripts under Linux to turn on the appropriate X10 module. When an X10 printer module is turned on I begin to SNMP poll the HP server (from MH). Currently I can turn it off after I determine that the printer is idle (I set a timer for 5 minutes to turn it off). I need to do more work on the script as it doesn't handle error conditions or another print job.

On a totally different note. I have an old color TV (no remote all manual) which I have on a modified appliance module. It's connected to a VCR (which handles channel changing but about to be replaced with an old Tivo) and the stereo output of the VCR goes to my stereo. I use X10 to control the TV (On/OFF), IR (via the Ocelot) to control the VCR & stereo. I can issue 1 command to turn on the TV (via X10, IR, CLI or MH web interface) and the TV, VCR, and stereo come on in the correct order and with the correct settings.

I'm currently working on the HCS II, LabJack and Video Camera interface to MH. A friend has donated his VA11A and I'm currently working on the USB driver. When used with the X10 Cameras & motion sensors I will be able to capture a picture of who is at the front door or remotely see my yard or whatever I choose. I haven't worked out how I'm going to display the video on a TV channel yet (remember I have a VCR and Tivo on the Cable feed).

There isn't much you can't interface to MH if you've got imagination, can figure out the protocol and write the code (or con-vince someone to help ;-).

MisterHouse at Baz Butcher's home

	Pentium 133
	2GB hard drive
	netword card
	sound card
	Windows 95
	MS Voice

Upgrading to:
	1.5ghz processor
	K7S5A motherboard
	  Lan builtin
	  sound builtin
	  2 RS232
	4 port RS232
	TV Card
	80gb hard drive

Win 95 and downloading the speech software from MS proved ok for speech but voice recognition had no chance. Also when running a screensaver that displays a new picture every 30 seconds this caused MH to pause for a few seconds each time. I also used this PC for everything, and surfing is a bit slow on 133 MHz, plus it needs a complete reset every ew days. I finally ran out of disc space too.

Using Weeder I/O cards and home-made relay cards meant the single RS232 was not a major problem for basic control of lights but I expect to need more for IR etc. X10 is expensive in the UK, plus I'm not so sure it is reliable so that wasn't an option.

I have also installed mh on my work PC running Win2k and laptop on NT4 mostly so I can read the docs anytime and try to understand the software. I also add to the Twiki in lunchbreaks 'cos it gets through the company firewall, while the lists get blocked.

I have just got a 1.5Ghz processor in a K7S5A which has lots of slots, built in LAN & sound & USB, 2 RS232 + 4way RS232 & TV card to come, and an 80G drive. Win 2k and MH 2.81 with the London.ini installed easily.

MisterHouse at Pete Flaherty's Home

I started witha 90M Pent MMX, 64M ram I ran basic MH, RH linux 6.1 ?
Basic setup X10, standard Hardware 

Added speech to MH using IBM ViaVoice
Upgraded CPU to 233M and Ran to 128M
Played with voice recognition (VV)
Added Modem support

Upgraded to RH 7.1
enabled CID on modem to MH
Added Tons of X10 modules
background enabled VV speech recognition (local Mic)
Added OWW Server (One Wire Weather station server side software), and
station on roof. (wrote/hacked )
Added 2 port PCI RS232 Card for other IO ( Ibutton buss, CM11A, MR26, )

Upgrades to RH 8.x
Upgraded Ssytem and rebuilt the House Box, now a 650M PIII, 256M,
basically same config as old box.
Started Acquiring Audreys, and using them as front ends
(OWW server still on old box)
Added Audrey Caller ID
Added/wrote interface to home phone system to monitor outgoing (merlin II)
Full time VR (added 'room Mics and mixer/support equipment)
Started hacking Audrey Images
Beta testing of MrAudrey images

Released first MrAudrey Image to MH community
System Hardware reasonably stable (for now)
Added functions to Bruces for ALL functions to control all the
lights ete.. with a single function. (for MrAudrey all Mail/Top lights
on/off) so CID and Email could trigger all the lights to signal, and Mr
Audrey page (Email and Phone Logs) could trip them all off.
Updated MrAudrey Image adding Package manager, dl etc etc etc ....

MisterHouse at Sean Walkers home

I have a simple Mister House setup at home. I run an AMD K6-2 based 
system with 128M RAM, 6GB hard drive, and running RedHat Linux 6.2. This 
system serves to control the house lights, display TV schedule 
information, play MP3s, and give general information about the house. I 
am currently working on integrating Sphinx2 based voice recognition into 
Mister House. I also have a "proxy voice" type of setup that allows me 
to speak voice commands at any Mister House proxy and have those 
commands sent over to the main Mister House box. This also sets the main 
box to reply to the station where the voice command originated. This 
makes it nice so I don't have to broadcast the results of a query to 
every room of the house.

Also along the network lines, I have the MP3 player set to stream audio 
to my workstation. Right now I have to set which system the sound is 
targeted at manually, but I'll be adding some code later to set the 
ESOUND environment variable for my MP3 player so that if I ask Mister 
House to play music in the living room, it will.

Future projects include:
Integration with HTPC to include PVR functionality.
Controlling HVAC.
Integration with alarm system.
Integration with intercom system.

MisterHouse at Craig Schaeffer's home

Dual 450Mhz Pentium III, 512MB memory, 12GB hard drive, SB Audigy, MOXA 8 port
serial card, RocketPort 8 port serial card. 

Software: Windows 2000 Pro, perl 5.8.0 build 806, MS Speech SDK 5.1, AT&T
Natural Voices (Mike and Chrystal), tightVNC, Folding@Home, McAfee VirusScan
4.5.1, Diskeeper 7.0, SpyBot Search & Destroy.

HA hardware: RCS TX10B thermostat, WeedTech Digital I/O (2), WeedTech Analog
I/O, iButtons (lots), 16 port relay board, Identifier (callerid),
8 speakers around the house (driven by a Yamaha PA amp), Red October Infrared
controller, 3Com USB webcams (3), MR26A, garage door sensors (3), hardwired
motion detectors (5), hawkeye motion detectors (3), DigiLock iButton board.

This pc replaced a single Pentium 450. I went dual processor to try to keep mh
as responsive as possible. Definitely better with 2 processors. I tried to run
with the new Windows 2003 Server software, but found some applications didn't
like the server version (Diskeeper and AT&T Natural Voices). I went back to
Windows 2000 Pro which has been very stable.

MisterHouse Even Graham house

I started out 3 or 4 years ago with MisterHouse running on a Dell Pentium 
120 with 32 MB of memory. Windows 95 was the OS. From there I added 
an X10 Firecracker Kit (which was almost free from x10 in the good ole 
days)  Mostly I wanted to do lighing control but I was also running speech & 
sound which I transmitted through the house with a baby monitor. Speech 
recognition worked but I hardly used it so I can't testify to how good it was 
on this platform.  For a Perl newbie, a hobbiest programer, and a hardware 
hack this was a good learning platform which satisfied me for months.  A 
great deal of functionality is possible even with this minimal setup.  The 
single biggest improvement to this setup (no surprise) was a boost to 96 
MB.  This probably lasted me through the first two and a half years of 

From there I began to slide down the very slippery slope of hardware 
acquisition and stringing of wires to every corner of my 1954 rambler...

Today I've accumulated the following:

* MH running on a Dell Pentium II with 192 MB memory (Win2K pro).
* Two sound cards (one for speech and one for music)
* An 8 port Moxa serial card (which replaced a 4 port STB card)
* One weeder digital I/O board
* An old weeder DTMF (phone) decoder card
* A twelve channel home brew relay card
* An MR26a x-10 RF receiver with RF amplifier and modified antennea
* A Realistic PA system and speakers through out the house
* A Sony stereo amplifier with speakers in two rooms
* An I-Button network
* Temp sensors in the dryer vent & furnace supply & return
* A Net-callerID box
* A leviton phase coupler / repeater
* Too many x-10 modules to count including:
    - light switch modules
    - slimline switches
    - lamp modules
    - appliance modules
    - keychain remotes
    - universal modules
    - motion sensors
* Garage door sensors (currently not working)
* Doorbell wired through weeder board
* Two Audreys
* Five networked computers, switches, etc.
* A drip irregation system controlled with an x-10  appliance module

What I've had trouble with:

* False doorbell rings - Think continuous ringing while wife is in house and 
technical support is out of town (improved but not perfect when I added a 
capactor added across the inputs)

* Garage sensors working correctly with the weeder - There seem to be 
some timing issues here that I've not had time to troubleshoot.  This has 
turned out to be a much bigger problem that I expected.

* Setting up custom web pages and links to code.  I've made it work but still 
find it confusing as hell.

* Managing all of the cables and connectors in my wiring closet (I finally 
built a custom chasis for the electronics and spent quite a bit of time 
cleaning up an accumulation of messy routings.

MisterHouse at Robert Mann's home


MisterHouse at my home runs 24x7 on a Linux box (RH 9.1) which contains:


    Main Computer
      PII 550 processor
      512 Megs SDRAM
      Generic motherboard
      Western Digital 20 GB
      Generic CD ROM drive
      Generic Ethernet
      Sound Blaster Live! 
      Byterunner 16 multi port serial card
      Weeder DIO digital 14 port input output /dev/ttyS6 Byterunner
      Home made 4 10amp relay board connected to Weeder DIO for sprinkler control
      Weeder SSR 5 port relay card /dev/ttyS6 (second module)
      WGL W800RF X10 RF receiver /dev/ttyS1 onboard serial
      CM11 /dev/ttyS0  onboard serial (See below X10)
      CM17 /dev/ttyS5 Byterunner(See below X10)
      iButton /dev/ttyS4 Byterunner DS9097U-S09
      iButton /dev/ttyS7 Byterunner DS9097U-S09 
      Standard Audrey running Infinity+ image (Don't know about this
image was installed when I got Audrey)
      3COM 3C19250 USB Ethernet Adaptor 
      LinkSys WET11 Wireless Ethernet Bridge (Makes Audrey a hole lot
      1		CM11		Wall transmitter
      1		CM17		RF transmitter
      13	WS12A		Rocker dimmers
      5		WS14A		Rocker companions
      3		XPDI3-IW	Rocker inductive dimmers
      10	XPS3		Rocker appliance switches
      5		LM465		Lamp modules
      5		AM14A		Appliance modules
      1		PZZ01		Passive blocking filter
      16	MS16A		ActiveEye motion sensors
      1		MS14A		EagleEye motion sensor
      1		MS12A		Motion sensor
      3		HR12A		Palm pad controllers
      2		SS13A		Slimline wall switches

  House Layout
    3 Bedroom two story house.  
    Downstairs: front yard, driveway, attached garage, living room, dining room, kitchen, guest bathroom
    Upstairs:   master bedroom, master bathroom, hallway, kids bathroom, office, Daniels bedroom.

System Layout

Main computer is located in the office upstairs. Drilled a 1 3/4 in hole in the office floor to the attached garage below.

Audrey is located in the living room between my wife's and my recliner.

Every switch in the house is a X10 switch of proper design. For standard lights there is a WS12A installed. If there is a ceiling fan with a light in it a XPS3 is installed (Neutral wire required). If there is a straight ceiling fan then a XPDI3-IW inductive dimmer switch is installed (Neutral wire required).

Motion sensors are located at the following locations: driveway, front porch, garage, entryway, living room, guest bathroom, kitchen, dining room, den, back porch, downstairs stairs, upstairs stairs, upstairs hallway, master bedroom, master bathroom, kids bathroom, office, Daniels room.

System Functionality

Sprinklers are controlled by mh with a custom built software module that checks the status of the sprinklers every minute to insure that they are in the proper state. I have chosen this method instead of purchasing a kit that shuts sprinklers off automatically after a certain amount of ?on? time in case your mh crashes. I am a risk taker and felt it more fun and exciting to insure that my mh does not crash. Motivation is the name of this game. How I did the sprinkler system is I ran the wires from the garage through the previously mentioned hole between the garage and the office and connected the 24v AC transformer originally used by the previous sprinkler system. I connected this through the home built relay box I mentioned above as well. In this box I added 4 LEDs so I can tell the status of each relay.

Motion detectors send signals to the W800RF receiver in the main computer. From this data certain events occur. Light turns on and off in the guest bathroom downstairs as this is a no window bathroom. Lights turn on and off in the house when $Dark. If it is dark and the house is in sleep mode then strategic lights come on and dim to 40% which is actually a lot darker then you would think. This has to be done in a way where full on lights will not bother you as the WS12A switches come on full then dim to the proper percentage due to the light switch design or coding in mh but I have not had a chance to investigate this yet. Sprinklers around the in the area and the cycle is reset for ten minutes later after motion has stopped. I have chosen to let mh handle all events of the motion detectors and as such no motion detector directly controls any other device in the house. This gives me the ability to let mh do all the timing events and such.

iButton networks are controlled by the DS9097U-S09 modules in the computer. 1 of them runs my temperature network consisting of 7 DS1920-F5 iButton: outside, garage, kitchen, living room, master bedroom, office, Daniels room. The other DS9097U-S09 controls the garage door via a DS9092L (Touch Probe w/LED) that is outside my garage door. The LED is controlled by an output on the Weeder DIO board and a 150ohm resistor that turns on for 5 minutes when there is motion in the driveway and it is dark outside (No need for LED in the light) There are no RF commands to open my garage door as this would be a very bad idea as someone could just walk by and use a palmpad or some other device to open your garage door. I plan to add other doors to the iButton network and will do this via separate DS9097U-S09s if needed as right now there is no way to determine which touch probe was used to active a iButton there for no way to know which door someone is at. With different DS9097U-S09s attached to different COM ports I can easily write this in to a module. Ceiling fans throughout the house are controlled by the iButton network of temperature sensors and turn on if the temperature reaches a threshold and the system is on automatic $Save{ceiling_fans}.

Intercoms this is a strange install I am sure compared to what some people might be using but what I did was go to radio shack and purchase two sets of: Radio Shack 43-3102 4 channel 900 MHz intercoms they come two per box. I purchased two of these sets for 4 total that I have placed in: kitchen, office, master bedroom, Daniel's room. I use appliance modules (Loud relays) to turn them on and off as needed throughout the house. I use the Audrey in the living room for audio there. This system is definitely a work in progress but is functional now. I just have the loud clicking to get rid of and to add real usable functions to the code to make the process work better. At this time I have the system pretty much on a time schedule. I would like to be able to utilize the rooms= functionality. The problem I have is that there is a small delay in the VOX input on these units so I have to run a sound through them first. Play on my system does not like to wait for the sound before speaking so I have tweaked the system to actually call play and wait for it to finish before talking. Then if I speak multiple things at a time the play and speak walk on each other. so like I said it is a work in progress that I will get back to VERY soon. The cool thing about using these is I can add two rooms at a time for 70.00. I plan to get Voice Recognition to work over these as well but that is a different story all together.

My next big project is HVAC. I have the wiring down for the system I just need to run the wires to the HVAC unit and determine if the power needed by the unit is two great for the Weeder SSR board and if so I need to build another home made relay board to attach to the Weeder DIO board. Here again I will attempt to do this without a controller. Will probably leave the original in place to take care of things while I am away in case something goes wacky but the day will come when I trust the HVAC system to mh.

Software Layout

I run 4 separate mh processes on the main computer. 1 main mh that handles everything that the 3 other proxy processes don't. 1 proxy for each iButton network. The reason for this is read_temp (reading the temperatures) of 7 iButton used to cause great delays in mh. The reason the second network uses a separate process is so that during the 15 second or so pause while reading the temperature the door triggers work normally. If not it 2could take up to 15 seconds (the time it takes mh to process the temperatures) for it to relay the info to the main process to activate a door trigger. The 3rd mh proxy is for the CM11 and CM17 interfaces as those are inherently slow as well and can cause mh pauses. All of these run on the main box and I have no issues at all. The load on the box is very low even with these 3 extra mh processes. All events are carried out as fast as I expect them to be. There are little tricks that had to be carried out to make this work on a single box and if you have this need email me and I will try to explain it the best I can. The main issue if you are running a items .mht/.mhp type file. You have to have a separate file for each process or you have each process trying to convert the .mht to a .mhp and you get all kinds of cool errors :) I just made a different code directory for each proxy process and place its own .mht file and code files for each process there. This also enables me not to have to worry about setting each file in the mh_proxy.ini file which on my system are actually called mh_x10.ini, mh_ibutton.ini and mh_ibutton_temperature.ini for easy remembering.


	AMD K6-2
	128MB RAM
	6gb hard disk
	Redhat Linux 6.2

This system serves to control the house lights, display TV schedule 
information, play MP3s, and give general information about the house. I 
am currently working on integrating Sphinx2 based voice recognition into 
Mister House. I also have a "proxy voice" type of setup that allows me 
to speak voice commands at any Mister House proxy and have those 
commands sent over to the main Mister House box. This also sets the main 
box to reply to the station where the voice command originated. This 
makes it nice so I don't have to broadcast the results of a query to 
every room of the house.

Also along the network lines, I have the MP3 player set to stream audio 
to my workstation. Right now I have to set which system the sound is 
targeted at manually, but I'll be adding some code later to set the 
ESOUND environment variable for my MP3 player so that if I ask Mister 
House to play music in the living room, it will.

Future projects include:
Integration with HTPC to include PVR functionality.
Controlling HVAC.
Integration with alarm system.
Integration with intercom system.

1.2 What do you want to know? aka environmental knowledge

 - Motion Detection
    simple = install & have MH speak
    medium = send alert emails if you're away, turn on lights, etc., 
    advanced = Active floorplan
    room occupancy
	allow zoning of AC to just active rooms
	predictive travel path of occupants


- 6" 16 Gauge solid conductor wire.
- 1 tiny picture nail.

- Pound nail into wall 1/3" from the corner and 1/3" from the ceiling.  
- Bend wire almost in half
- Bend about 1/2" at 90 degrees from ends pointing inwards. 
(should look like (upside down V)
 /  \
 -  -
- Place two ends into the holes in the battery compartment (from the back)
- Batteries will keep the wire in place when door is closed.
- Hang the top of the V on the nail.

You can move it up/down/side/side and it says in place due to friction 
between device corners and wall. ;)


- Monitoring and/or controlling garage doors
- Coming and goings of people
- Coming and goings of vehicles
     leave lights on until other car gets home
- Where are the vehicles when not home
     HAM radio gateways with gps connected     
- Temperature of various househould/homestead locations
- Computer usage
	tell there is person in room by computer activity
		linux w command
		windows ??
- Television time limits
- Are we sleeping
	Making MisterHouse be quiet
- morning routines
- dimming lights after hours to prevent "middle of night blinding"

What can I use to control my home?

	  RF Card
	  WiFI Card
	Touch Switches
          X-10 stick a switch RF
	  Leviton hard wired
	  Scene Controllers
	  Voice interface
	  DTMF decoder
I found a gadget at Radio Shack that is
intended to start a recorder recording when the phone is picked up - it has
a phone plug on a a cord and two other mini-plugs on cords, one small (audio
out)and one very small (recorder on).  I plugged the small one into the line
in on my pc audio card, and when I pick up my cordless phone (NOT a cell
phone), turn it on and hit the 1 to turn off the tone, I can input voice
into mh.  Just have to hang up before the phone complains.  Also have to
adjust the MSVoice level with the phone (about to move to Linux). Works
great!  I also use a Sharp Zaurus SL-5500D to control mh - got on eBay with
wifi card and 128M SD card.

-- Jonathon

	FRS Radios
	  headset connected to sound card mic input (non secure)
(against law?)
	Web Interface
	  inside your home
	  available outside your hom
	  Homevision controller
	  touch screen internet appliances

Related Links

Back to top