X10 vs UPB vs... ybox2?

Tuesday, March 16, 2010 by darco
Posted in , ,

Now that I finally have a house, I can start doing what I've been looking forward to for a very long time—home automation. One big part of that is being able to control lights and appliances in an automated fashion.

The idea is that you have some sort of automated switch or dimmer module that allows you to control its state via some signal. The trick is how to get the signal to the module. In general, there are three categories of signaling for home automation systems: powerline carrier, wireless, or via a separate signaling cable (such as ethernet). I'm not a big fan of using wireless for permanent non-mobile installations, so that leaves powerline carrier and separate signaling cables.

Modules which use the powerline as the carrier for signaling are extraordinarily convenient from an installation standpoint because it uses the cables already in the walls. While there may be a handful of applications where I end up using separate cables for signaling, I hope to primarily use a system that is based on a powerline carrier. There are two protocols that I am considering: X10 and UPB.


The traditional home automation solution is the X10 signaling protocol. X10 modules are dirt cheap (~$7 for an appliance module) and readily available, and I already have a handful of X10 bricks.


An X10 appliance module

Unfortunately, there are a number of problems with X10.

  • It is horribly slow. Commands take at least three quarters of a second to transmit. Flipping a light switch and having the lights turn on or off nearly a second later is horribly annoying. Raw bitrate is a staggering 20 bits per second.
  • It is unreliable. Sometimes commands just don't go through. Even more annoying. Additionally, if you share a transformer with your neighbor, your neighbor may be able to send commands to your lights and appliances from their house!
  • It is very limited as far as functionality goes. For example, there is no easy or widely implemented way to set the exact dim level for a dimmer module—the most reliable way is to turn it all the way up and count out how many 'dim' commands you send until you reach the desired level.

While I wouldn't mind using X10 for a few random things that don't need immediate feedback and aren't security concerns. I don't want to use them to control lighting.


I learned about a relatively new power-line signaling protocol a few years ago called Universal Powerline Bus, or UPB.


A UPB Appliance Module

UPB is much faster and more reliable than X10, and has many more features:

  • Raw bitrate of 240 bits per second. Sending a command takes as little as a quarter second.
  • All UPB devices are two-way, meaning that you can probe any UPB device for its current state.
  • Supports multiple programable 'profiles' which allow you to change all of the lights in a room to a specific state instantly.
  • Larger address space allows for controlling many more devices than X10.
  • Protocol supports collision detection and retransmit with randomized exponential backoff, making sure that your commands don't get lost.
  • The protocol appears to be well documented.

This all sounds great, but there is a serious problem with deploying a UPB based home automation solution using off-the-shelf modules: UPB devices are very expensive.

Remember how I said an X10 appliance module costs around $7 each? A single UPB appliance module will set you back a staggering $57. A dimmable UPB lamp module will set you back $68 (vs $8 for X10). This isn't even MSRP—these are eBay prices. This likely means that your UPB lamp module cost more than the lamp it is controlling. What a rip off.

But there may be a silver lining. As I mentioned above, the UPB protocol is well documented. I could probably make my own UBP modules for less than it would cost to buy them.

I've started investigating possible designs for how to build a UPB module, starting at the physical network layer. Here is a prototype schematic of an experimental UPB decoder and encoder.

Experimental UPB decoder:encoder

Experimental UPB decoder/encoder. The decoder is on the left, encoder is on the right, and the powerline is simulated in the middle.

I'm convinced that I can make UPB modules for less than it would cost to buy one. The big question is if it is worth the effort.

Other Alternatives

I do plan to fully wire each room with at least four Cat5 drops each. If I'm going to go through all that trouble, why not add another drop or two for home automation purposes? With a few ybox2s and some relays I could have a 'room controller' for each room, and use an iPhone or iPod Touch to control it.


A ybox2, a internet-enabled set-top-box I designed.

The more I think about this option, the more I like it. This would have the following advantages:

  • Response time would be practically instantaneous—much faster than X10 or even UPB.
  • Would be less expensive to deploy than UPB (because I'm already going to be doing the Cat5 wiring work and a single ybox2 can control several lights or appliances).
  • Would be more flexible than X10 or UPB. I designed the darned thing, after all.
  • Would be inherently controllable from the internet.
  • Would be much more secure than X10 or UPB because the signals aren't transmitted over the powerline.

A big potential drawback would be what should I do ten years down the road when we sell the house. Because it won't be using off the shelf components, it would not be easy for someone else to maintain themselves nor would it be easy to find someone who has the knowledge to maintain it (because it's all custom). I may well have to rip it all out beforehand.

There is still lots to do around the house, so it may be a while before I get around to even starting to put this all together. But as I do, I'll be sure to blog about it and share my experiences.

Have you thought about making your own home a "smart home"? Have you thought about deploying your own home automation setup? How would you go about it?