|
Hi All
Thought i would share my christmas project with everyone. I have always wanted to copy those crazy uTube videos of christmas light to music. Well i finally looked into it and found that everyone is generally using Light O Rama. Which is cool, but cost dam near 800 bucks for 32 channels. So i thought i would build it all myself. So i grabbed my BS2 from my Boe Bot, bought 20 1AMP PC board relays off of ebay for 15 bucks, (Spent way to much for transistors, resistors, soldier, diodes and pcb board from Radio Shack, (Hate that place.) and went to work. Took me about 3 weeks total so (Which is way to long, I made a few stupid mistakes since i don't do this stuff often, and used visual studio C++ for the first time.). Anyways, I made my own relay boards, threw together a very dirty housing for them with 16 outlets, put up all my lights, laid out alot of extension cord and wrote a gui in Visual C++ to controll the lights over serial. At first i tried just programming the BS2, quickly found that to be very limiting, not really surprising. Overall it is working out very well. I did rip off the actual sequences from other people. I was finding that actually writing the sequence manually was taking way way to long. I took a look at Light O Rama software and i must say, it is very nice for writing a sequence. Then i struck gold and found that their Version 2.0 software stores the files as xml. So from that i found a couple sights where people post there LOR files, downloaded some good ones for 16 channels and wrote a parser into my gui. Worked out great. The tricky part is assigning the channels in their sequence to the appropriate thing in my yard. I plan on having a total of 4 songs this year. I have 2 tuned out and working great so far, just a little bit more work and the other 2 will be done. Now i am waiting and hoping the FM transmitter i ordered off of Ebay from hong kong makes it here in time for christmas. That way people will be able to hear the music in their car.
It worked out that I seem to only be able to send the serial commands every 40 milliseconds reliably.
Which is ok I think.
The LOR stuff has twinkle and shimmer effects.
I think i can do that next year by using the pulsout command on the BS2 side of things.
A couple lessons learned, should have used bigger relays. 1 Amp isn't much and doesn't allow me to expand alot. I actually had to build a 17'th circuit because the porch lights were drawing to much current to go thru 1 relay.
I used mechanical relays, and there lifetime at full load is 100,000 cycles no load 5 million.
Running lights like this I do not expect them to last more than 2-3 years.
Managed C++ appears to be a big pain in the butt.
Without LOR software i don't think i can easily expand my number off relays much without making things to complicated.
Never assume those transistors in that old parts draw are NPN because they are labeled as such.
My wife has been great, she has let me take alot of time to do this.
Here is the youtube link to my best song so far.
Will post more later.
Also here are a couple pics of the setup, will open up the housing and show the relay boards later.
And here is the BS2 code. (I know someone will ask for it.) Simple ehh.
And here is the C++ code and gui.
Please go easy on me when viewing the code.
I know there are some really bad things in there, but it does work and will slowly get cleaned up.
If anyone knows why "delete thread" or thread.Dispose() will not work please please let me know. (See comments in form1.h)
That confused me for a whole night. (I found a way around it, but it would be really nice to be able to kill a thread.)
Also if you have never heard of Holdman, google Holdman Family Christmas and watch his YouTube video.
That dude is amazing. Post Edited By Moderator (Chris Savage (Parallax)) : 12/19/2008 3:21:43 PM GMT
Image Attachment :
 DSCF3001.JPG 397KB (image/pjpeg)This image has been viewed 648 time(s). | Image Attachment :
 DSCF3002.JPG 410KB (image/pjpeg)This image has been viewed 518 time(s). | Image Attachment :
 DSCF3003.JPG 407KB (image/pjpeg)This image has been viewed 563 time(s). | Image Attachment :
 DSCF3004.JPG 397KB (image/pjpeg)This image has been viewed 480 time(s). |
File Attachment : BS2 and C++ Code and GUI.zip 192KB (application/x-zip-compressed)This file has been downloaded 251 time(s). |