Inbedded

The Inside of an Embedded world !

Ambilight™ Clone Using BeagleBone

Today I will present you my custom built Ambilight™ clone. It entirely relies on open source software.

The setup is the following:

  • XBMC running on a PC I use as home theatre PC (watch and record TV, play movies and music)
  • boblight client plugin for XBMC (part of the default XBMC install)
  • boblightd running on the BeagleBone Black that offers a network interface to control the LEDs strip

I used the following hardware but note that boblightd supports other LED controllers and communication schemes so some variations are possible:

  • WS2801 SPI controlled LED strips (I ordered a clone of the original Adafruit 25 pixels 12mm strand)
  • BeagleBone Black
  • Level shifter (3.3V to 5V from dealextreme)
  • Breadboard / Protoboard
  • 5V 2A AC/DC converter

I first tested the setup using a breadboard but I’ve now moved to a semi-permanent setup mounted on a protoboard.

"Level shifter mounted on protoboard and attached to BBB"

I took some measurements so the LEDS would nicely fit at the back of my TV (40 inches Sony LCD) I then cut three plastic rails to the measured length (the plastic rails are in fact cables management pipes). I decided to divide the LEDS strip in 3 logical panels “left”, “right” and “top”. I “split” the 25 LEDS strand in 2x8 and 1x9 LEDS. After having put marks on the rails I drilled 12mm holes (wasn’t that easy, I’m a software guy after all).

I then inserted all the LEDS in the holes and wrote some routines to quickly test my setup (I based my work on the code I wrote for the Nokia LCD I used before). If you go the same route I would recommend testing BEFORE popping the LEDS in place just in case the LEDS strand you bought has a defective pixel and you have to replace it. (I was lucky)

Once the HW looked good I started to investigate the software part. First thing first I checked out the boblight repository on my beaglebone since it’s easier to build on the target directly than to fix possible cross-compilations issues. Then had to go through a bunch of iterations till I got the daemon to build (just follows what configure script says)

Once the daemon was running I investigated the boblight configuration. It’s got lots of options and is not straightforward, luckily I found the following tool: “boblight configuration generator” that allowed me to create a boblight.conf file without too much effort.

I tested the setup with boblight-static, one of the available clients part of the boblight repository, which sets all the LEDS attached to a static color.

Once this is working you need to enable and configure the plugin in XBMC, you can refer to that thread on the XBMC forum for more information on how to do that.

With everything in place it was time to mount the setup at the back of the TV and enjoy:

If you have any question or need help don’t hesitate to ask in the comments.

Comments