Controlling shiftbrites with colors from the screen
I have two ShiftBrite modules behind the monitors on my desk, so I tried setting their colors according the colors on my screen. Python-xlib has bindings to XGetImage, which was good enough for this project. (It's very slow, though, so I can't watch the whole screen with this technique. XCB might be better.)
I read two rectangles at the top of my monitors, have PIL calculate their average colors, and send those colors to the RGB LEDs.
Here's the essence of the code.
Flower LED lamp
I got a shelf from craigslist and stapled some cloth to the sides

When Kelsi and I were at the cloth store, we got some fake flowers:

I drilled holes in the flowers:

...and put 3 white LEDs and one orange LED in each one. The 12V power comes from an old computer power supply in another room that's running various other home automation devices.

Now the flowers are on top of the shelf, and Kelsi has a new nightstand with a lamp:
MegaBrite installation
I replaced the LED nightlight in our bathroom with a MegaBrite.
I got some plastic domes on eBay. Do you want one? I have several extras.
I attached the dome to the ceiling by tying some bicycle tire around pushpins that press out against the inside of the dome. Here are a few other uses for old bike tubes.


Here are some unretouched photos of the MB with its dome lighting up the bathroom. Shutter times are 1/2 and 1 sec.

When I was testing the MegaBrite, it was hanging down from the ceiling and I happened to have a glass of water nearby:

The first two pictures are from different positions of the MB in the glass; in the third one I am sloshing around the water:

I'm controlling the MegaBrite with a parallel port, which is very simple to do. I'm getting LED power from the 5V rail of an old computer power supply. The power is going over perhaps 50 feet of cat5 which probably adds a lot of resistance. I measure 4.7V at the MB end (with the MB turned on). The parport control code is here. It has no attempt at optimization yet, and I think it takes just under 1ms to do a single update. If I add more MBs to this chain I may need to fix the inner loop in that code.
2009 light9 theater lighting software report

David and I brought light9 back to life again a few weeks ago to run lights and sound for an annual dance show.
Each year we put a little bit of time into the code and then design and run a show over a weekend. Then we don't think about the code for hundreds of days, which leads to time-capsule notes to ourselves for the next year. It's a little disturbing to think about the future of a code project when it has the property that each chunk of development takes 1% of your life to complete.
This year, the notes have a bunch of small technical fixes, but I wish we could make some big changes that really improve our productivity. The bottleneck occurs when the dancers are rehearsing a song and we're trying to design and test lighting effects at the same time. We only see each song a few times, so even half a second lost to 'using the software' is a concern. There need to be actions like "that looks cool, remember it", "that was right, but a bit too late-- put it on a list of things to review with music later", "make the light animation 10% busier", "give me a random, contrasting look right this instant so I can fade to it (and I'll fix up the exact look later)". These actions need to be run from either of our computers.
There are other actions that would be helpful to run remotely. Sometimes I'm up on a ladder and I need light b35 turned on and then the other two blue lights faded up and down so I can see how b35 fits in with them. Dave can do this pretty easily from the booth, but it would be a better use of his time if he was in the audience planning out the looks we're trying to acheve. Maybe I can manage to press buttons on my cell phone, or maybe we can get some voicerec working.
Like many other data-editing tools, the light9 software uses names for various entities. I don't mind typing the names for songs, for example, but it's pretty poor that I have to name the things that I want to fade up and down during a song. We end up with names like "slcross", "green", "cs1", "edge", "bpurpleall", "centercircle", etc. I'm typing those (and reading/decoding them) while a song is being rehearsed, which is the most sensitive time of all! I want to move toward images, either captured at the moment we make the look, or synthesized from photos of each individual theater light (which is easier than it sounds [my project] [Ian's project]).
I also have most of the data in RDF, which should open us up to better sharing and syncing between apps. Right now I still read .n3 files from the filesystem, so there's no improvement in functionality. I like Sesame, so I thought I'd put my data in there and use some messaging service to send pings between the apps when things change. But the Open Anzo RDF store may have figured out that notification stuff already, so I'm eager to look into it some more.
SHDH 26
Kelsi and I both went to SHDH 26. We only caught the end of the lightning talks and then worked for a while on the upper patio. I ported my Tk/Togl opengl app to Qt so it would work on modern ubuntu setups. It's gotten hard to find a working package for Togl, although maybe it's still getting updates?
Qt is ok, although the python version of the API is long on prefixes (PyQt4.QtGui.QLabel!) and short on error message details ("TypeError: argument 1 of QLabel() has an invalid type"). The integration with twisted has some issue too, where i get qt warnings to stderr at about 20Hz. I couldn't figure out how to lose the enormous space around some of my label widets.
We met Brett there too. He's pictured here.
Theater lighting tool upgrade
With the http://light9.bigasterisk.com software, I can now sync motorized sliders to the onscreen ones, and synthesize an image of what the stage might look like. The slider sync is two-way (moving them on the screen makes the physical ones run to their new location). The image is an opengl addition of layer images for each channel. I could get those layer images by photographing each light by itself in the theater. Here, I just sketched some fake lights in gimp.
The first two sliders on the hardware are mapped to lights on the left and right sides of the stage, which are those gray splotches at the center of the screen.
Atom feed of this blog