Logo ©1994-2007 Kevin Boone
My professional interests
Computing
Law
Education
Science and research

My leisure interests
Martial arts
Heritage railways
Garden railways
Motorcycles
DIY

Downloads
Linux downloads
Windows downloads
Java downloads
Perl downloads
Home automation downloads

About me
Home & family
My CV

Site info
Contact the author
Download policy
Keyword index

  *** I have changed my e-mail address: please see the contact page for details ***
Home > DIY and home improvement

Using X10 for home automation

Last modified: Thu Jul 8 07:19:38 2004

This article describes the `X10' power-line control system, how it can be used, and some of the devices that are available. It is written specifically for a UK readership, and may not be applicable elsewhere.

Disclaimer
Electrical mains supplies can be dangerous. Please don't let this article encourage you to attempt procedures beyond your competence. The author accepts no responsibility for any adverse consequences of your use of this material. In general, the use of X10 devices requires few changes to electrical wiring, but there are safety implications. Remember that X10 allows electrical appliances to be switched from remote locations, so some care should be taken to ensure that appliances can be properly isolated for maintenance.

What is X10, and what can you do with it?

X10 is a system for controlling mains appliances and lighting using signals carried over mains power cables. X10 modules are available that replace ordinary lightswitches, mains outlets, and pendant lamp holders. As well as being controlled locally as normal, appliances can also be controlled remotely using keypads, radio and infra-red remote controls, timers, and computer interfaces. X10 can be used for many applications; here are a few examples.
  • Extending a light with a single lightswitch to be controllable from two, three or even more locations with no additional wiring.
  • Switching lights on and off at set or random times, or opening and closing blinds and curtains to give an illusion of occupancy when the house is empty.
  • Controlling groups of lights or appliances from a single switch point.
  • Allowing lights and appliances to be controlled from outside the house. Using Internet or telephone control allows control from any distance from the house.

X10 principles

X10 works by carrying control signals over the domestic mains power wiring. Because most houses are wired so that all power and lighting circuits originate from the same point, a control device in one part of the house can control appliances in another part. This means that controllers do not have to be wired directly to appliances.
      Control signals can be generated by various sources, including plug-in controllers, radio and infra-red receivers, and computer interfaces. These signals are detected by appliance and lamp controllers, among other things. The X10 protocol also provides for a controller to determine the status (on or off) of an appliance, although many appliance modules don't support this (see below).
      As all controllers and appliances are connected to the same mains wiring system, how does the X10 system determine which device a particular control signal should be directed to? Embedded in each X10 signal are a `house code' and a `unit code'. Both of these can take values between 1 and 16. Each appliance or lamp is set to respond to a single house code/unit code combination. The house code was originally intended to allow adjacent houses to use X10 without interfering with each other; this is necessary in theory because houses in the same neighbourhood may share a connection to the power distribution system, so that control signals can `bleed' from one to another. In the UK, where uptake of X10 has not been widespread, the house code and unit code can both be used to select which device to control. This means that a total of 256 devices can be controlled independently in a given property.

Where to get X10

A number of manufacturers produce X10 devices, including Leviton and IBM, but they generally only supply to distributors, not to the public. In the USA X10 devices can be purchased from high-street shops, but you are unlikely to find such availability in the UK; you may well have to resort to mail-order suppliers. A good mail-order source is Laser Business Systems in Barnet, London. Maplin carry a small range but, although Maplin do have high-street outlets they are unlikely to carry X10 devices. In the text below I have provided the Laser product codes for convenience; these may not always be the manufacturer's own codes.

Sample X10 scenarios

Here are a few situations that might suit the use of X10 devices, based on my own experience.

Outbuilding lights

If you have a detached garage or shed, or other outbuildings, it can be very convenient to be able to switch the lights on and off from inside the main building as well as from the outbuilding. Normally this would require two-way switching, with a three-core cable run from the house to the outbuilding. This would be in addition to any other cabling you may have installed already. Suppose you have a detached garage about 60 feet from your house, as I do. You have already run a heavy armoured cable from the house to the garage, and don't want to run any more. With an X10 lamp module in the garage you can control the garage lighting from anywhere; no extra cabling is required. In addition, you can install multiple switches in the garage if it has separate vehicle and people doors.

Coupling room lights

Suppose you merged two rooms in a house to make a single large room. For example, in my area houses have separaate living rooms and dining rooms; commonly people knock down the dividing wall to make one large room. But you now have a long room with two doors, and separaate lightswitches. What you really want is for both switches to operate both lights. No problem: just replace the lightswitches with X10 lightswitch modules, set to the same unit code. Either lightswitch will then control both lights.

Convenience switching

When I moved into my house the lights for the attic were controlled by a small switch in the attic itself. To get any light in the attic I had to get into it and then wander around in total darkness looking for the switch. Eventually I rewired it so that the switch was in the room below. However, it would have been much easier to install an X10 pendant lamp module on the attic light, and then it could have been controlled from anywhere. Similar logic applies to other inaccessible areas.

X10 devices

This section describes some of the more popular X10 devices that are available in the UK.

Appliance modules

Appliance modules are designed to switch `heavy-duty' loads like fans, pumps and motors. The simplest type (e.g., AM12U) plugs into a three-pin electrical outlet, and provides its own three-pin outlet for the appliance to be controlled. There may be a manual switch on the housing; there will certainly be provision to select the unit code and house code that the device responds to. The advantage of this kind of appliance module is that it can be used with no wiring changes at all; the module just plugs in.
      Alternatively, you can replace a standard three-pin double or single mains outlet with an X10 version. It will work the same in all particulars apart from allowing control by X10 codes as well as by a local switch. It will also be slightly bigger than a standard double socket. For a permanent installation this may be better than a plug-in module, because it can't be removed by accident and looks less unsightly.
      For a new installation, or a significant rewire, you may prefer to use X10 appliance modules that plug directly into a consumer unit (fuse box), e.g., AD10; this, however, is a job for the expert. It is also possible to get (dimmable) lamp modules for consumer unit mounting (e.g., LD10).
      Note that some appliance modules allow a suitably-equipped controller to determine their on/off status. This feature may be very important, because X10 has no built-in error checking; the status report feature may be your only way to determine whether the device really switched or not. This issue is discussed in more detail later.
      Although heavy-duty heating loads (e.g., immersion heaters) can be switched on and off using any appliance controller with a suitable current rating, specific X10 devices are available for varying the output of these heaters (e.g., TS194). They usually operate by switching the mains supply on and off for extended periods of time, and are thus unsuitable for lamps and motors.

Pendant lamp modules

A pendant lamp module sits between a pendant (ceiling-mounted) lamp holder and the lightbulb. It responds to X10 codes and switches the lightbulb on or off. Versions are available for Edison-screw (SL575) and bayonet lightbulbs. They can typically switch up to 250 watts. Note that there are a number of important limitations to these devices, resulting from the fact that the module does not have access to a mains neutral connection; see the `caveats' section below. Some lamp modules can dim as well as switch.

Lightswitch modules

A lightswitch module (e.g., LW10U) replaces a standard wall-mounted lightswitch. It contains a lamp switching module or an appliance module, and a single-channel controller. The controller normally generates control codes with the same unit code and house code as the lamp module, so pressing the switch operates the lamp exactly as a standard lightswitch. However, unlike a standard lightswitch the X10 approach allows more flexibility.
  • We can fit a lamp module in another room that responds on the same unit and house codes; this allows the lighting in both rooms to be controlled using the same switch. Moreover, this technique is not limit to two rooms; any number of lights can be controlled.
  • We can control the light using a different controller altogether, in addition to the lightswitch. For example, remote control and plug-in controllers can be used.

      Be aware that lightswitch modules are available in two wiring varieties. The `live only' version (e.g., LW10U) is a drop-in replacement for a standard lightswitch, and needs no neutral connection. These version is intended for filament lamps (not fluourescents) and will be able to dim as well as switch. The `live-and-neutral' variety (e.g., AW10U) needs a neutral connection; this may be suitable for new installations, but is unlikely to be compatible with existing wiring. The live-and-neutral version, because it is intended for fluorescent lights, will not be able to dim.
      Because of its increased complexity, a lightswitch module is significantly bigger (front to back) than an ordinary lightswitch, and thus stands prouder from the wall. This won't be to everyone's taste. As an alternative, a battery-operated remote control transmitter is available that fits into a lightswitch mounting; in conjunction with a pendant lamp module this offers the same features as the lightswitch module, but is nicer to look at. It will, however, need occasional battery changes.

Motorized devices

A number of motorized appliances are available with built-in X10 support. The most popular (in the US at least) is the `Swish' curtain puller. This allows curtains to be opened and closed by X10 commands. Although an able-bodied person would have to be very lazy to find this appealing as way of opening and closing curtains, under timer control it can provide additional household security by giving an illusion of occupancy when the house is empty. Similar systems are available for windows blinds.

Sirens, locks and other security devices

A number of X10-controlled sirens and strobe lights is available (e.g., PH508); these are switched on and off using standard X10 control codes, just like mains appliances. Similarly, X10-compatible locks allow a door to be locked and unlocked under X10 control. It is also possible to be obtain passive infra-red (motion) detectors that issue control codes when movement is detected in or around a house (e.g., MS13E), and X10 security floodlights that are controlled in the same way as an ordinary lamp.

Relay modules

If you have electronic devices that cannot adequately be controller by a standard appliance or lamp module, you can use a relay module (e.g., UM506). This has a standard low-voltage relay which is controlled by X10 signals. Such a module can be used, for example, to switch a hi-fi amplifier onto different sets of loudspeakers.

Environment sensors

As well as motion detectors, there are X10 controllers that respond to other environmental changes like temperature and light level (e.g., SD533).

Control keypads

There are many plug-in control keypads, ranging from single-channel devices that can control only one device (or multiple devices on the same unit code), to enormous desktop multi-channel units. The largest that I have seen (SC502) has sixteen on/off switches. Smaller devices usually have slider or rotary controls to allow a smaller number of switches to control a large number of devices. The popular `mini-controller' (MC640) is about the size of a wall-mounted light switch (although slightly thicker) and has four on/off switches, bright/dim, all on, and all off. A slider allows the on-off switches to be allocated to either unit codes 1-4 or 5-8. Thus this controller can manage eight appliances or lamps.
      Plug-in controllers normally have a three-pin plug and are intended to be plugged into a standard mains outlet. For a permanent installation you can connect the device to a fused spur unit, but note that these devices always require a neutral. In other words, you probably won't be able to fit one in place of a standard lightswitch, because the connections won't include a neutral. There are controllers that are designed to fit into a lightswitch mounting (e.g., LV6400), but these won't be useful in most houses because of the lack of a neutral connection in lightswitch wiring.

Remote control transmitters and receivers

You can overcome the `neutral problem', and get increased flexibility, with wireless devices. Being wireless, they need a transmitter and a receiver; additionally the wire-free part (the transmitter) will need battery power. There are two types of receiver: infra-red (e.g., IR543) and radio (e.g., TM12E); infra-red devices offer better battery life in the transmitter, but are otherwise not very useful (in my experience) as they need line-of-sight between the transmitter and the receiver. With a radio system, the receiver can be mounted anywhere in the house that is within range, and need not be visible (I have mine behind a cupboard). The range of most of these devices is such that the transmitter will work anywhere in an ordinary-sized house, and at least part of the grounds as well.
      Transmitters are available in a number of flavours.
  • `Replacement lightswitches'. The transmitter replaces a standard wall-mounting lightswitch, whose wiring thus becomes redundant. One-gang and two-gang devices are available and, owing to their small size, they do look OK as a lightswitch. However, most of these devices sacrifice range for increased battery life; many have a range of only a few meters. This means that you must mount a receiver fairly close by. If this scheme is widely used, you will end up with a large number of receivers. This is not a technical problem, but will be expensive.
  • Handsets. An X10 remote control handset looks like the remote control device that you might get with a television or video player. However, if it is radio-based -- rather than infra-red -- then it will be usable anywhere in the house. A number of devices (e.g., MK19) are available that combine X10 control with standard infra-red remote control, so can be used to control television and hi-fi as well.
  • Control panels. Devices like HR10E provide the same facilities as plug-in controllers, but without the need for plugging in. Although portable, they are large and therefore less suitable for mobile operation than handsets.
  • Key-ring devices. These are very small transmitters designed to be carried on a key-ring (e.g., KR19E). They normally allow one or two devices to be controlled. If they are radio devices they will work from outside the house. This allows lights, locks, etc., to be controlled from outside.
  • Wireless security sensors, e.g., motion detectors (DM10E), door sensors (DW523). These are intended for wireless security systems.

Telephone-based receivers

These devices (e.g, LV6325) convert touch-tone telephone keypresses into X10 signals. This allows lamps and appliances and lamps to be switched on and off by telephoning the premises and pressing the appropriate buttons. Unless you have multiple telephone lines, such a device will have to be set up quite carefully to avoid conflict with telephone answering machines and fax machines.

Computerized X10 controllers

For sophisticated timing and control requirements, you can use a computerized controller (e.g.., CM12U, MT10U). These devices have an on-board microcontroller and real-time clock, allowing appliances and lamps to be switched under the control of a timing specification. The timing details are normally downloaded from a computer (e.g, a PC) through an RS232 cable (CM12U) or set up through front-panel buttons (MT10U); once set up the on-board memory allows the unit to operate without further intervention.
      Sophisticated units are normally supplied with software, but it is invariably for the ubiquitous PC-Windows platform. Linux, Unix, and Mac users will have to look elsewhere. Happily, the communications protocols are usually straightforward, so a competent programmer should have no difficulties writing software to control the device.

Computer-controlled X10 transceivers

For the ultimate in flexibility, you can use a computer-controlled X10 controller or transceiver. Unlike computerized controllers like CM12U, these devices have no on-board logic; they simply allow a computer to issue and -- in some cases -- receive X10 codes over the power line. Send-only devices include the USA model PL513 (very popular in the USA but not, I believe, available in the UK). Two-way (transceiver) devices include the TW723, which is available with a range of computer interfaces. Send-only devices are slightly cheaper, but for my money the increased versatility of a transceiver unit is worth the extra. A transceiver will allow the computer to respond to signals generated by key-presses, and to monitor the status of the appliance modules. These units interface to the computer in a variety of ways. For real enthusiasts there are versions that require TTL-level logic signals (these can often be controlled by a PC's printer port, but the software is horrendous), or support RS232. For example, TW723 can be attached to a computer's serial port via a logic converter called TWSERIAL. Interestingly, this adapter costs more than the X10 controller itself, but makes programming much easier (although still not trivial). A Linux driver for the TW723/TWSERIAL is available from this site (click here). A number of software packages are commercially available that allow the exploitation of the more sophisticated features of X10 transceivers. Again, these mostly run under MS-DOS or Windows. With the appropriate drivers it is not very difficult to write software to use an X10 transceiver, and there is a huge amount on the World-Wide Web.

Caveats

Anyone planning to use X10 devices should be aware of a few issues.
  • Most embedded lighting controllers cannot be used with fluorescent lights. By `embedded' I mean devices that replace standard lightswitches or lampholders. The problem is that these devices do not have a neutral connection. The power supply to operate the electronics is derived by allowing a small current to `leak' through the light filament when it is turned off. This current is not sufficient to light the bulb, but is sufficient to operate the controller. However, fluorescent lamps do not allow this leakage to take place; they have a very high electrical resistance in the `off' state. For similar reasons, very low power incandescent bulbs may not work either. I have found that 40 watts is the practical minimum. With bulbs rated lowed than this, the bulb may glow even when technically switched off, and not respond to the controller.
          For many applications this limitation is quite severe; it effectively precludes the use of fluorescent power-saving bulbs as a replacement for standard lightbulbs.
          It is possible to obtain an X10-compatible lightswitch that does support fluorescent lamps, but it requires a neutral. If your lighting system is a standard loop-in arrangement (most are) then you won't have access to a neutral. In theory, a neutral could be taken from elsewhere (e.g., a power ring), but this causes problems with isolation.
          Another possibility is to mount an appliance controller module in the ceiling cavity near the light to be controlled, and get its neutral supply from the ceiling rose. The existing lightswitch wiring can then be modified at the ceiling rose so that the lightswitch pulses the control input of the X10 device. This usually means that you have to switch the lightswitch on and then off again to switch the light either from off to on, or on to off, which is not ideal.
          The plain fact is that using X10 devices to control fluorescent lights usually requires some wiring changes.
  • An X10 appliance or lamp module is never a safety isolator. Switching off an X10 module never constitutes safety isolation, even with modules that include a relay. Someone in another part of the building could be tinkering with a multi-way controller and switch the device on unexpectedly. When buying X10 lamp modules, ensure that they have some form of safety isolation. Lightswitch modules usually have a fuse compartment in the body somewhere; removing this fuse constitutes isolation. If your modules don't have an isolation mechanism you will need to switch the entire circuit off at the fuse box to make it safe to change a lightbulb.
  • The X10 system was never designed for unattended remote operation. Usually pressing a button on a controller generates an X10 control code, and that's that. The controller does not normally check that the operation was successful. Most appliances and lamp modules cannot determine whether they are switched on or off. An X10 switching operation can fail for a number of reasons, even when there is no fault. For example, if two people try to control two devices at the same time there will be a collision, that is, a conflict. In all likelihood neither operation will succeed.
          This is fine so long as it is people that are controlling the devices. If pressing a button has no effect, you can press it again. If you are switching a light on, it is usually fairly clear whether it worked or not.
          Suppose you are using X10 to switch, say, a central heating system on or off. It you press the appropriate `on' button, it may take several minutes to be sure that it is switched on. The same applies to switching off. If you are using computer-based control to do this remotely, then you don't really have any way to tell whether the heating is on or off. This is not ideal.
          If you plan to control appliance from a remote location, ensure that you get appliance modules that can report their status to a controller. If you are writing software to do this, ensure that the software checks the status of the appliance module after sending the `on' or `off' instruction, and takes appropriate action if the status does not seem to be correct. To the best of my knowledge, there are no controllers commercially available that can do this automatically.
  • Wireless devices use a variety of radio bands. In the UK, there are two `approved' frequencies: 418 MHz and 433 MHz. Most suppliers carry devices that use both these frequencies and these are, of course, incompatible. In addition, it is possible to get devices that operate on the USA standard frequency of 310 MHz; these are unlicensed in the UK and their use may be illegal. These devices are, naturally, much cheaper than their approved counterparts.
  • X10 products are available to suit different supplies. The electrical supply in the UK is 230V at 50Hz, although 240V devices should be OK. However, US equipment rated at 110V will probably not be OK, and may well be dangerous. There is a thriving market in `converted' US X10 devices, as they are about 20% cheaper than UK-spec equipment. These are devices that were made for the US market, and then converted for 240V operation. In general, these products will not be compatible with UK-style three-pin outlets, and a variety of adapters will be required to make them work. In my opinion it isn't worth the modest cost saving achieved.

   
Search

WebThis site

Shameless plug

By the author of this site. Buy on-line from Amazon USA | UK

Editorial
So you want to be a university lecturer? Read this first!

Speak like your boss: new developments in managerese

Computing features
File handling in the Linux kernel: an in-depth look at how Linux handles files, filesystems, and file I/O

All sorts of Linux stuff

Confused about CLASSPATH? answers are here

First steps in EJB using jBoss (recently revised for jBoss 3.2)