Christmas Lights to Music Using Arduino

Christmas Lights to Music Using Arduino
My wife and I have wanted to create our own lights-set-to-music show for the last few holiday seasons.  Inspired by the two Instructables below, we decided to finally get started this year and decorate our RV.  We wanted an all-in-one controller (lights AND music) but didn't need it to be controllable over the internet, making it a little different than the other two Instructables.


Video to come!


Sources I've Used:

Instructables:
Arduino Christmas Light Controller
xmas-box: Arduino/ioBridge internet controlled Christas lights and music show

Other:
Solid State Relays (SSRs) Using TRIACs:


 
Remove these adsRemove these ads by Signing Up
 

Step 1Parts You'll Need

Parts You\
SSR Supplies ($7):
MOC3031 Optocoupler (8)
Z0103 TRIAC
(8)


Light Controller Supplies ($61):
Arduino Duemilanove
WaveShield


FM Transmitter - I made one (shown in the photos below) but any will work ($15+)


RadioShack B&M ($14):
      Wire Terminals (3 packages, 12 connectors) 276-1388
      Printed Circuit Board 276-147 (could use smaller)
      330ohm Resistors (2x 5-packs)
      150ohm Resistors (2x 5-packs)


Home Depot B&M ($25):
      50 ft Landscape/Sprinkler Wire (18ga, 7 conductor) 079407238170
      6' Power Cords (x8 minimum, to use the female 120v connectors)
         -you may need more than 8, depending on the locations of your lights; I used 11
      Clear Plastic Box (my Dollar Tree was out but HD had these for $0.87)


Miscellaneous:
      Soldering Iron (I use a butane-powered BernzOmatic from Home Depot; doubles as a heat gun)
      Solder (highly recommended: Soldering Paste)
      Screwdrivers (philips for WaveShield, standard for wire terminals)
      Wire (for WaveShield and connecting to the SSRs, I used extra breadboard jumper wires I had)
      Diagonal Cutters
      Wire Strippers
      SD Card (any size, I used 64MB)
      Electrical Tape
      Power source for Arduino (I used an extra powered USB hub I had)
      Hot glue gun
      Wire nuts (optional)

« Previous StepDownload PDFView All StepsNext Step »
57 comments
1-40 of 57next »
Jan 4, 2012. 7:00 PMwirenut1980 says:
Great work! Looks Awesome!
Nov 27, 2011. 6:09 PMGoranUvDenRimboe says:
Okay, I must be doing something wrong. I built the circuit using the larger Triacs (4A 400V) and for some reason the lights just don't blink. They just stay lit. On every channel just on never off. I've tried the test sketch with the same results. Lights on, never off. Is it possible I've mis-wired something? Is the pin layout on the larger Triacs different than the ones you used? The Christmas Sketch loops through the SD card nicely and plays all of the songs, but no joy on the lights. Any ideas where I screwed-up?

Thanks!
Dec 13, 2011. 5:39 PMmerkidemis says:
I am having the same issue with my board. All the channels but one stay on. Did you ever get yours figured out? (I used the same parts as the MRedmon)
Dec 14, 2011. 6:44 PMmerkidemis says:
Here are the images (Warning: 18 megapixel)
Front:
http://www.redlightning.net/front.jpg
Back:
http://www.redlightning.net/back.jpg

The pins on my optocoupler are thus (Mouser lists the one in your how-to as obsolete):
1 6
2 5
3 4

Datasheet is here:
http://html.alldatasheet.com/html-pdf/53864/FAIRCHILD/MOC3031M/407/1/MOC3031M.html

Given that, which pins should I short?
Nov 30, 2011. 6:38 PMGoranUvDenRimboe says:
I found a pinout for the 4A triacs. From left to right counting the pins, pin 3 is the gate. I had at first wired pin 2 to the optocoupler thinking it was the gate. I've gone through and resoldered the triacs making pin 3 go to the optocouplers. However now nothing turns on.

I've attached images of the front and back of the pcb.
I added a third ground wire since my plug used the third gound.
So I've also added an extra wire block to handle the extra ground wire.
I also ran the plugs for the lights to actual outlet plugs.
The four plugs fit nicely in a four gang box and the green common ground from all of the plugs goes to the new ground block.

The common wire for the plugs is red and that goes to the wire block where the plug is attached. The black wires all run to the gang box to connect each single plug socket.

Thanks for the assist.

Steve
PCB_front.jpgPCB_back.jpg
Dec 5, 2011. 7:37 AMGoranUvDenRimboe says:
I had a thought as I was checking things with the multimeter. Is it possible that the circuit just isn't sending enough of voltage to trigger the Triacs? Since I used the upgraded ones you mentioned and not the ones you first used to build with, that is about the only thing that makes sense. I tried to look at the specs pdf at mouser but I get a file not found error. So I'm wondering if that is what the problem is. When you measure the trigger voltage what do you get for a reading?

Dec 7, 2011. 9:43 AMkate5593 says:
Hi Matt,

This project is great. I would like to apply it to lighting just our indoor Christmas tree. I'm a newbie so I'm not sure how to streamline the project. If I were to use just 3-4 sets of lights, what would I cut out as far as other parts? Thanks so much for any advice you can offer.
Dec 10, 2011. 4:10 AMkate5593 says:
Thanks so much for your quick response. I'm still gathering parts. So if I end up with 4 channels, is that 10 wire terminals?

And one more rookie question: can I substitute a different optocoupler for the ones you specified above? That part seems to be on backorder for the suppliers I looked at.

Thanks again.
Nov 23, 2011. 6:08 PMsquirtdad says:
ok I am not an electronics guy but I am trying. Where is the FM transmitter connected.....for the life of me I don't see it. Also could you use the same connection for a simple jack and then plug the output into speakers?

thanks
Jan 17, 2011. 10:26 AMrobotjam says:
MRedmon, I was wondering if there were a way to add 1 normally open pushbutton switch to advance to the next song on the SD card. For example lets say that I have 15 songs on the card and I want to listen to the 7th song, as it is setup right now I woulld have to listen to the first 6 songs to get to the one I want, I think it would be nice if I could just push a button 6 times to advance through the first 6 tunes and play the 7th tune, the one i want to hear and see at that moment.
Also would there be a way to add some sort of potentiometer to the circuit to adjust the sensitivity? Like attach it to the common ground wire or something.
Sorry to keep bugging you about this but I think we could make this thing really cool (not that it's not now), I think I have some good ideas but I just have no idea on how to implement them.
May 26, 2011. 5:09 AMmojarabm2 says:
Buddy , lets check out your design again,
why did you draw connectors as common between two triacs?
i can not understand ! let me know about your imaged , or i would show other ways to you , then you may love to make it better.
mojarab@hotmail.com
Sep 25, 2011. 11:35 AMwootin24 says:
I have a quick question.
My question is do i have to make a new program for every song it does or does it manualy sync the music with the light.please help me because I'm thinking about making one for the holidays. Also will this work with my solid state relays that have a input of 3 to 8 volts and a controll of 120 volts. Thanks for the help, ps, iam only 14 so keep it in easy to uder stand terms.
Oct 18, 2011. 8:30 PMbruce-f says:
I was wondering if there was going to be any code improvements for this year?

Could the Arduino possibly do a fast Fourier transform on the WAV file then control different channels to turn on and off depending on the WAVE file frequency? What I mean is a set of lights turning on and off with the "high" notes of the song, and another with the "low" notes or bass? Could there be different patterns depending on the "volume" of the song?

I think you've done great work so far. Thanks!
Jan 16, 2011. 4:08 PMrobotjam says:
MRedmon, I am pleased to announce that I have fixed my problem and it is working quite nicely. The problems came from the way I was converting the music files. If you are interested I have uploaded a new video onto the YouTube, the link is
http://www.youtube.com/watch?v=cepyTHrfWQg
and the video is named Christmas Light Controller 3. I think for next Christmas I am going to have to get a cardboard Santa and his 8 reindeer and have a different light for each of the reindeer, might look pretty cool but I won't know till then.
Jan 11, 2011. 10:28 AMrobotjam says:
I tried using the new code (Christmas_Lights_2010.pde) and all i get is the lights all come on and nothing else.
I did use your test code and it and my box are both working perfectly you got any suggestions on where i might have messed up? Thanks
Dec 31, 2010. 10:28 AMrobotjam says:
Hello MRedmon, I used your controller box for a display i put on my wall and i received quite a few complements as well as a few people want me to build them one for next Christmas. Here is a lin to what i did,

http://www.youtube.com/watch?v=cepyTHrfWQg

I also have 3 more videos of other lighting things, one of them is a video of your box showing it working. As you will notice I have made 2 small changes to your design, one of them I I added 8 blue led's to the circuit to make programming easier even though I have no idea how to program it, it just looks cool. The second change I am going to make is to add one of those little 1.8 inch video/ fm transmitters, this also makes looking at the box more impressive. I hope to get that mounted sometime this week. Check out the videos and let me know what you think i would love to hear your opinion. Thank you for making this possible, I could never have done it without you.
Also check out my Christmas tree ornaments, i have a lot of people wanting me to make some for them.
1-40 of 57next »

Pro

Get More Out of Instructables

Already have an Account?

close

All Steps Viewing
View all steps of an Instructable on the same page when you're a Pro Member.

Upgrade to Pro today!
8
Followers
4
Author:MRedmon(Matt's Photo Gallery)