Okay, today we are going try to build a computer controlled Christmas Lights in 5 minutes.
I’ve been rolling around the neighborhood this late November and some people already have
their Christmas lights decorated. Well I’ve seen many “static” Christmas lights that always
stay on. Today, I will show you how you can customize your Christmas lights by using a PLC,
a Programmable Logic Controller.
Update: Garrett’s Voice Activated Christmas Controller is now available!
- 1 CuSB22R from cubloc.com
- 1 AC power cord (like the one for your computer or get it here: cubloc.com)
- 3 AC Connectors from Home Depot (You can get more depending on how many Christmas Lights you are trying to control,
remember you can also put Christmas lights in series per relay)
- bunch of wires
First you will need to cut off the AC power cord and you will find 3 wires,
one green, one black, and one white.
Simply splice them and hook up the green wire to the CuSB where its labeled
“FG”, which is frame ground so your house does burn down.
Screw in tightly.
Then put the other Black and White wires onto the terminal headers as shown below.
Black and White wires do not have polarity, so you can put either or onto the CUSB
labels, N and L.
Leave them unscrewed and only screw in the green wire if you haven’t done so in Step One.
Connect a wire from CuSB label COM to CuSB label, N
Connect from CUSB label, P40, to one of screws on the AC connectors.
Polarity doesn’t matter so any of the two screws will work.
Screw in tightly.
Do the rest of the AC connectors.
Connect from CUSB label, P41, to one of screws on the AC connectors.
and also connect from CUSB label, P42, to one of screws on the AC connectors.
Connect from CUSB label, L, the white wire in the picture
to the other screw on the AC connectors for each of them.
When you are done, you should have something like below.
Connect some Christmas lights to each of the AC connectors.
Then connect the serial cable to program the unit.
Copy and paste the following code into CublocStudio and download to your CUSB.
Const Device = CB280
Dim Interval As Long
If Interval>100 Then
Elseif Interval>0 Then
Taking It Further
Well your lights should be working pretty good now.
You can change the Interval=300 line so the lights start
blinking slower or make a completely different program
for your Christmas.
If you put it on a deer structure or something, you can probably
time it so it is animated.
But we will leave that up to you and if you have any questions,
feel free to email me: firstname.lastname@example.org
Happy Holidays! 🙂
Also check out our new stuff like:
Voice Activated Christmas Controller
Pingback: DIY - How to Make Christmas Light controller in 5 minutes! | zedomax.com - blog about DIYs and Review on reviews of gadgets and technologies...
Pingback: Zedomax Christmas DIY - Voice Activated Christmas Lights! | zedomax.com - blog about DIYs and Review on reviews of gadgets and technologies...
Pingback: 2dayBlog - Technology Journal, New Gadget everyday! » Blog Archive » 2day’s How-To: Make a Christmas Light Controller in 5 minutes
Pingback: Hacked Gadgets » Blog Archive » DIY Christmas Lighting Controller
Pingback: 我不喜欢-Blog » How to: Make Computer-Controlled Christmas Lights
Pingback: Comfile Technology Blog » How to make Christmas Light controller in 5 minutes!
$129 seems expensive. for a “static” programmed controller.
Take a look at http://www.d-light.us for a fully featured controller.
I prefer playing with my toy cars and lorries on my play mat, Although being an electronics geek i think i may just be able to sort this pcb out myself as long as mommy and daddy hold my hand for me when i go to plug it into the wall.
If i decided to make one of these units and i got electrocuted would you pay off all of my bills??
hola solo quiero saver donde puedo conseguir este sircuito en mexico agradeseria me ayudaran Bye.
Very stupid question from a beginner but can the CUSB22R’s output AC voltage be controlled so that Christmas lights can be programmed to gradually brighten and then dim to nothing. I would like to get various single colored strings, one per channel and have them one by one gradually brighten, then dim and then the next color would brighten so that it appears the lights are changing colors. Thanks in advance for your time and patience if this is a dumb question!!
Hi there John,
Unfortunately the relays on the CUSB22R cannot control the brightness. There might be a way to hack it but I have not tried it and cannot recommend it.
But you might be able to send an email to Garrett@zedomax.com who might know further about this.
Wow, I’ve wanted to do this for some time but most tutorials involve solid state relays, complicated soldering, I am definatley going to try this, I’ll order it when I get my pay check tomorrow. 2 Questions kinda as fodder for people reading this but also if anyone knows the answers and would like to assist. It looks like as an alternative to the Ac Connectors one would use the typical wall plugs you can get at home depot for about $.42 ea since you are just connecting the wires is that true or would that accidentally set my house on fire? With those and the available coverings you could make a sweet base board to mount everything on.and what is the maximum number of lights you could have on this? Thanks for this awesome tutorial!
What kind of program is used to program the lights?
I used BASIC code, which is a slightly modified version for embedded computers, you need to check out http://cubloc.com for that. Basically their computer chips allow you to code in BASIC, pretty much going back to the 80s, a lot easier than C or C++.
Pingback: Tweak of the Week: Christmas Lights « Boot [F12]
can the cusb-36R also be used to do this?
or can the cb280 proto board be used?
Of course, you will need to hook up the relays to the CB280 though, I find it much easier with the CuSB units because they are pretty much same thing with relay embedded.
and do you know any programs i could use to sync the lights to music?
Well, I provide the program free here, you can use that as skeleton or perhaps you can google “christmas light controllers”, I believe you can buy industrial ones for like $500 or so. Expensive but gets the job done. Or could be cheaper…
Yup, any of the CuSBs can be used, this one is just used as example.
I love this idea
but my laptop certainly doesn’t come with a serial connection anymore,
is there anything with USB capability?
I assume the computer must stay connected to the sequencer
it doesn’t “Remeber the sequence”?
yes go to parallax or radio shack and look for a usb to serial adapter.
Is this possible to make in England?
Yes, of course!