Computer Controlled

So, now that I moved into a house, I have gotten bit by the desire to setup some sort of computer controlled lights for Christmas. I realized this just before Christmas last year though. So it was too late to do anything. However, I realized that just after Christmas there would be sales on lights, so I should at least start the process in preparation for next year. (I bought over 800 lights on sale for more than 50% off from ACE soon after new year.)

I also realized after some investigation that this could be a pricey goal as well, so spreading the work out over a year is more fiscally possible as well. Not to mention that I plan to write all my own software, so it will take some time to do the research as well as coding.

This post probably should be longer, but I have a lot of information to record, and not much time to do so.

I have worked in theater a lot in the past, so I was very familiar with how professional lighting control is done. I realized that should I go with off the shelf components, that they would all work together well and would have lots of software possibilities as well. In the real world, most lighting control systems use DMX to control lights. So at first, I looked at some USB DMX controllers, as well as DMX controlled relays. (Velleman has some other seriously cool kits as well.) I even bought a cheap DMX hub from ebay. However, the more I looked into it, the more I realized that just revolving the design around DMX would be very expensive.

Then I remembered Phidgets. These things are not cheap, but are very versatile, yet so simple. But I knew that alone, nothing there would really help that much, until I found Solid State Relays. So I did some hunting around the standard component sites. Then I found the Crydom D2W series relays. They were really the cheapest ones I found which met the requirements. Sure, they top out at 3.5A, but I think that should be ok. I will just get some 3A fuses to ensure I don't mess anything up. I would have preferred the panel mount package, but the same parts in that package were about 4 times the cost.

With Pod 4, I am getting better at this

That would have put the cost just on the relays from 90$ to 360$. So I have come up with some creative solutions to using the PCB mount package. (see pic) So the way that the d2W series work are that there are 4 terminals. 2 terminals are DC control terminals for the 2 AC terminals. As you can infer from the picture, a 5V signal comes in and controls whether the hot wire of AC power is either on or off. The power comes from the cable, goes through the relay, and then goes out to the receptacle. It works very well actually. Remarkably simple. Of course, while this is the lynchpin to the system, this is only part of it, and does not work very well of course with the DMX plans.

So back to phidgets. I went for the 8/8/8 board. It seems to be the most versatile option. I didn't need 16 outputs, and this would allow for other interesting projects later as well. I "could" have gone for the 0/0/8 board, however 1. it only allows 2A per output, and 2. the switching is all centralized at the board meaning lots of LONG extension cords from one place. This is the breadboard setup for testing at the momentWith the current architecture I have, the power comes from wherever the closest plug is while the on/off signal travels over cat5 (which I plan on putting rj45 terminals on which make it easy to plug in/remove. Here is my test bed for the 888. I took an old LED clock face and was using the LED segments to test the 8 different outputs. If you haven't figured out already, each output presents 5V or Ground depending on whether its on or off. This maps directly to the AC port in the "Pod" that this cat5 cable is connected to being either on or off.

So I got the 888 and started writing some software. It comes with a great SDK that supports a "jillion" different languages. I just created a few timers and connected the timing to slider controls in the UI and started playing around. Here is a video I made of the process:

When I create my software some time this year, I REALLY want to use the concept of PWM in combination with POV. In this video, the key demonstration to see is that not only are the LEDs going on and off in a sine wave pattern (yes, I was using sin() in the code), but also the pattern for how the leds go from brightness to dim (or off) at a specific speed. Slow at first and faster later. The way this happens is that they are actually flashing more than 20 times per second, as the flashing "slows" to around 14 they actually appear to go dim. You can affect the appearance by controlling the "duty cycle" which is basically the ratio of how long they are on, to how long they are off. I used sliders in the UI to find the right values. This video was when I got the simple test to look pretty good. I was messing with the sliders on the computer at the time.
 
Pod 4 is nice and cleanThe next step of the process was building the different pods to actually be controlled. This involved putting an outlet in some enclosure with the relay and also providing power to the outlet/relay and running ethernet from the pod as well. I have some VERY detailed pictures of the different attempts and the insides here. However, essentially, you just connect everything you see in the picture at the top. From the Flickr set, you can see I tried some different enclosures. However in the end, I felt that they were all too expensive and it was probably just best to go with standard gang boxes (seen in blue). I also started by hacking up existing power cords I had laying around. Finally perfected the pod constructionBut I soon realized it was better and cheaper to get a VERY long power cord, cut it in 5 portions (20 ft segments...since I had 5 pods left at the time), and then just getting 4 plugs (plus the one original). Here is an example of a newly completed pod. There is insulation under the face plate to try and protect some of the insides at least a little. Other than that, all that's inside (for now) is what you see above. As I mentioned before, I plan to add 3A fuses to all the pods before they actually get used. I have a few ideas how to do this, but have not gotten to that yet. Of course, I had to make sure that they work though. Here is a video of one of the tests I did. In the test, I am controlling the on/off with the mouse on the computer, so its going through the 888 just as its all designed to do. It all works VERY well.
So, there is still a lot more to do, but I finally have all of the pods complete. My living room will thank me when I finally clean up all of the mess (yes, I don't need to hear about how I have a garage now, but don't use it for this). There will be much more to report on over the year, but here is a final picture of all the pods together.
All 8 Pods complete

» Similar Posts

  1. From Italy with Love
  2. Magical Mystery Music City
  3. So Many Projects, So Little Time…

» Trackbacks & Pingbacks

    No trackbacks yet.

» Comments

    There are no comments.

Comments are closed