A UPnP Home

Since Zhaan made it into extras-devel I have gotten several feature requests for new functionality.  Many of them have made sense and I have gone ahead implemented them in the latest version.  For example, Zhaan 0.1-8 implements vastly improved playlist support.  Zhaan is now at the point where I have found myself actually using it enough to entirely replace my standard Sonos controller and actually ENJOY the experience.  (I also installed Zhaan on my ‘stable’ N900, not just my development device, and have witnessed no ill effects.  I think it’s probably safe for anybody to use at this point)

Since (in my opinion anyway) I have succeeded at building an application to solve in-home media problems with UPnP I now turn to other problems that UPnP can solve (since it’s so much fun to hack around with).  Zeeshan Ali wrote a GUPnP-light application which shows an image of a lightbulb which goes “on” and “off” based on another test control point application. That seems like an interesting idea, using UPnP to control my lights.  And why not, right?  Who really wants to get out of bed at night to turn off the wall-mount light switch when my phone is on my night stand within arms reach and could be used to control those lights.  (clappers be damned).

Herein lies a rather common problem in computer science.  Writing software to do fun things in simulations is easy.  Applying it to solve real world problems by designing, manufacturing, marketing and selling a real physical product is hard.  Thus for the first 2 days of my search I could not find any devices to allow me to control my lights via UPnP.

During the first two days of searching I did learn a lot.  Here is a quick summary/FAQ of how modern “Smart Homes” work: (Smart meaning networked and remotely controllable)

  • Smart devices in the home do not often connect to the WLAN, let alone expose themselves as UPnP devices.
  • Instead, they use mesh networking.
  • There are several common mesh network protocols.   Z-Wave, X10, Insteon to name a few.
  • Once you deploy a bunch of Z-Wave (or other) mesh devices you need to deploy a “base station” of sorts which can control all of the devices and which MAY connect/bridge to the LAN.
  • Most base stations come with their own software to interact with via a browser or other proprietary mechanism.

Last night at about 3AM, on the verge of giving up my search, I found micasaverde.com.  They have a device, called the Vera, which looks to do exactly what I want!  I posted a quick question on their forums confirming that the device does what I had hoped (exposing each Z-Wave device as its own UPnP discoverable device). Turns out it does!   Here is a response from Javier, an “administrator” of the micasaverde forums.

Yep, that’s the main point.

Every device attached to Vera gets a full UPnP description and identification. Even for internal programming, everything is done using UPnP references.

In fact, writing device plugins (to get new devices attached to Vera) is mostly writing Lua code to join UPnP actions and state variables with the real-world device control interface.

To boot it looks like Vera is low power and designed for energy savings.  It also runs on a (mostly, from what I can tell) open source Linux stack.  Rock on!

Looks like I’ll be getting myself a Vera for my birthday (next week) and, with any luck, a week or two later posting another application to Maemo extras-devel that can control Z-Wave devices via a Vera!

Update: Turns out you can SSH into your Vera too.  I’m starting to build a collection of embedded Linux/OpenSSH servers around my house :) (Chumby, Vera, N900 etc.)

5 comments

  1. Interesting!,, I’ve always dreamed to do something like that on my own home, I’ll follow your blog to see what you can achieve.. have fun!!

    PD: is possible this could also be ported to android?

  2. Very neat! I just might have to get one of these now.

  3. Specifications….
    http://micasaverde.com/specifications.php

    It’s a Asus WL-500g Premium v2 router with a new plastic case.
    http://www.newegg.com/Product/Product.aspx?Item=N82E16833320030&Tpk=wl500g

    Plug a Aeon labs Z-wave stick in the back. The Z-wave stick uses a simple protocol over a virtual COM port. Probably a ft232 inside.
    http://www.aeon-labs.com/index.php?option=com_content&view=article&id=49&Itemid=62

    It’s running dd-wrt with their own gateway app loaded under Linux.

    Checkout 802.15.4. There are some neat tools at http://www.redwirellc.com/store/

    The is a Linux implementation of 6lowpan/ROLL for 802.15.4 but it is not in the kernel tree yet.

  4. Hi,

    I came across your blog recently looking for different N900 software…

    It’s interesting that you mentioned Vera – I’ve been using it since the early beta-testing for almost 2 years now. It’s quite a nice device, but not without its problems. Some people expect it to be robust and polished like a finished commercial product. But it’s more like a DIY device with Linux inside. That’s why I love it – it allows me to do with it whatever I want and not limited to what manufacturer thought would be good for me. Kinda the same appeal as N900 or any other Linux device… :)

    Anyway, welcome to the community (look for me on the forums…)! Hope to see some interesting hacks from you for Vera and N900 :)


    denix

  5. Jon,

    Ah, thanks for pointing all of that out. It’s really awesome that they’re building a product the “right way” by using off the shellf components so they don’t have to reinvent the wheel.

    Denix,

    Thanks for the welcome :) I’ve heard similar thoughts about the Vera (that its not entirely a finished end-user-ready product yet). That kind’ve saddens me, I wish this technology would move from the “device” to “product” stage, but I get the impression the smart home in general is still very much for hackers only.

    Nelson,
    Possibly. Want to ship me an android to test with :). I have not explored Android’s support for new libraries (like GUPnP, GObject Introspection and PyGi) or whether android already has a UPnP stack. Assuming it either would let me ship new libs or already has UPnP theres no reason somebody (or I) couldn’t build a vera android app.

    p.s. I think i fixed the ability to comment in posts. WordPress’s settings can be somewhat cryptic.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>