Introduction: Permanent Digital LED House Holiday Lighting
Digitally addressable RGB LED strips are becoming more available and less expensive through hobbyist electronics stores and direct from factories in China, so it's time to update your holiday house lighting!
This project uses an Arduino to control strips of digitally addressable LEDs, and the idea is to put them up once, and then use different programs for each holiday throughout the year.
In a previous project, I added permanent analog LEDs. Those are good, but the whole strip is always the same color. With digital LEDs, you can do a lot more animation effects since each individual LED can be controlled.
There are many Instructables on using these LEDs - the main effort in this one was finding a way to easily mount them on the outside of the house, while still being able to remove them for repair, painting etc.
The LEDs used were strands of WS2812b LEDs, which is a combination of a 5050 RGB LED + a WS2811 controller chip in a single surface mount package. These are very bright LEDs! You can buy them in 5 meter strips, and they can come with a silicone jacket for waterproofing.
Programming them is easy with a few free Arduino libraries. For this one, I used the "Neopixel" code from Adafruit. FastSPI is another popular library.
One big caveat - this was not an easy project! The Arduino coding part is relatively easy, but there is a lot of soldering of connectors and planning involved. Also, the LEDs are somewhat sensitive to power fluctuations, and seem a bit prone to failure. Even with the precautions mentioned here and elsewhere, I still ended up taking down portions of the strings several times and eventually replacing about 10 of the individual LEDs. Now that they are up and working (so far!), they are very cool - much more interesting than those boring static lights! :-)
Step 1: Parts
The main idea was to come up with a way to mount the LED Strips easily, be able to work on them as needed, and take them down for painting. So, I used some plastic molding as a backing to make the strips rigid, and cup hooks and screw eyes to mount them to the house. That way, each strip can be taken down as needed for any work.
Electronics and Wiring Parts
- LEDs - WS2812 or better WS2812b strips (better reverse polarity protection and slightly brighter). Waterproof - this is usually a silicone jacket for these types. I recommend 30 LEDs per meter since more LEDs will require a lot more power! Also, more than 30 LEDs per meter ends up blending together from a distance. Adafruit has them (called Neopixels). You can also get them at Ali Express (the Ray Wu store is popular, but there are many stores selling them). They come with white or black flexible circuit boards. You can also search for WS2811 since the WS2812 LEDs use the WS2811 chip + a 5050 LED. The other way to go are strands of WS2801 LEDs would also be fine, and since each LED is typically separated by a couple inches of wire, they draw a lot less power and still look great. Get extra LEDs since you will be fixing some of them.
- JST-M 4 conductor connectors - you will need one male and one female per strip, plus a few extras. You only need three conductors. When I built my project, I did not see any 3 pin JST-M connectors for sale, but I see them on AliExpress now, and they should also be good, without that extra wire. The LED strips have different connectors depending on where you buy them, but some of them come with three pin JST-M connectors already soldered on which you may be able to take advantage of if you use those. I live in a fairly dry location, so if you live where it rains a lot, you may want to use waterproof connectors. There are ones that are made for LEDs like these.
- 2 conductor connectors - I used some JST-M 2 conductor connectors first, but then found these Deans type connectors and really prefer them since they are easy to solder, and have obvious polarity, where the JST-M connectors with black wires require you to remember how you used them. Don't forget the mating plugs. These are used for the power connectors. The Deans type connectors allow 18 gauge wire to be soldered directly to the connectors. There are also auto ones like these that might work.
- An Arduino Mega to control the LEDs. Most of the LED libraries use an array to store the pixel values, so the Mega is required so it has enough RAM to hold the array for all these pixels. The array is 3 bytes (R, G, B each 1 byte) per pixel. There are ways to do this without the array, so a simple Arduino could be used.
- Power supplies - 10 amps, 5 volts. You will need about one of these for every 150 LEDs. I used these, or you can use ones like this one. For long runs, though, there will be too much voltage drop on the lines, so I ended up using higher voltage power supplies, and DC to DC step down (buck) converters at the strips, which worked very well. You can also use 5v power supplies with lower wattages, and just use them to run fewer LEDs. The advantage of this approach is that they cost less, and you will need less "power injection" wiring (see next step). The disadvantage is that you will need to run those wires around more unless you have a lot of outlets available along the installation.
- Wire - 18 gauge is recommended, especially for longer runs. 20 gauge can be used for connections from the strips to the 18 gauge wire since the heavier gauge is mostly to minimize voltage drop over longer distances.
- capacitors - 1000 uF electrolytic - you should use one per power supply.
- resistor - one 300 to 500 ohm resistor.
- fuses - adding inline fuses at the power supplies may help if you accidentally mis-wire anything.
- Plastic strips - These were from Home Depot: Royal Mouldings Model 867 1/4 in. x 3/4 in. x 8 ft. PVC Composite White FRP Cap Moulding.
- Silicone RTV to seal up the ends of the LED strips.
- Waterproof kitchen containers - I used these to hold the power supplies. You will need to get the right sized ones for your particular project.
Step 2: Planning the Layout and Wiring
For my single story house, I decided to follow the roof line. So, it made sense to have a separate strip for each section of roof line, and on the longer runs, a couple of of the 8 foot strips end-to-end. Each strip can be taken down to make way for painting etc., or to work on the strip itself. This happens a lot since the LEDs do go bad from time to time (see the Troubleshooting section).
For the electrical wiring, the WS2812b LEDs have a +5V, Gnd, and a data line. Since the digital commands are passed down the data line from LED to LED and strip to strip, that wire needs to form one continuous circuit from the beginning to the end. You can still light up the LEDs in any order, but the single control line will connect them all.
Similarly, all the strips should have their ground wires connected to make sure the signal has the same ground reference across all the strips.
Since each strip needed to wired and tested individually, I used the same input connector for each strip, wired in the same way, even if not all the input pins were needed in normal operation. That way, I can pull and test any strip with the same signal and power connector from the Arduino controller. As mentioned before, I had a few bad LEDs, so I used this system a lot - highly recommended!
The WS27812b LED strips have three wires, and come with a variety of connectors. I ended up discarding all of those and using JST-M 4 conductor connectors on each strip. The lead-in connector only uses three of the wires for testing, and the fourth was sometimes used to bring power from the end to the start of the segment (or a separate 2 pin connector was used). Standardizing on three pin connectors would be fine too, and if I did this project again, I would probably do that, especially if the connectors had color coded wires to make wiring easier. The output connectors were wired differently for each strip - to match the power requirements for the subsequent strip.
For example, if one strip is at the end of a set on one power supply, and the next strip starts a new power supply, the output of the first strip would not connect the +5 wire across. The second strip would have a separate connector for power to come in, and also the main input connector would have the power line connected for testing only.
At the very beginning, use a small resistor in series with the signal wire from the Arduino - 200-500 ohms.
Make sure to use capacitors at the power supplies!
Generally, the female connectors are used as the input side of the strips.
So, all the ground wires for everything are connected together, and the data line runs between all the LEDs in order. The +5 lines should only be shared between sets of LEDs using that power supply - it is best to not cross the +5 lines between the power supplies since they are not all exactly the same voltage and can oppose each other a bit.
Getting enough power to all the LEDs is the hardest part of this project. Since each 5050 LED module can use 60 ma of current, 150 LEDs will draw up to 9 amps. 150 LEDs are what you would get with a single 5 meter LED strip with 30 LEDs per meter.
I highly recommend the Do It Yourself Christmas web site RGB power discussion for it's excellent coverage of power issues with LED lights for houses. I found it after I did my initial work, and it would have saved me a lot of time debugging the system. One key piece of advice is that you should be adding power every 50 LEDs or so since the voltage drop on the strips themselves is significant. I had some runs of up to 76 LEDs, which seemed OK. It might be good to test this before wiring everything up - use bright white (all LEDs on full) to test - see the Troubleshooting section for more info.
For longer runs, power will need to be added at a few places, even if it's from the same power supply as "power injection". Power Injection simply means running multiple wires from your power supply to sections of the LEDs to have less voltage drop than running the power through the strip itself. So, for 150 LEDs in three sets of 50, you can use a single 10 amp 5v supply, but should run power lines to the start, two middle sections (every 50 LEDs) and the end of that string. So, that is 4 power lines - each optimally using 18-2 wire, so it's a lot of wire and connectors. I chose to run those lines along the LEDs, adding connectors at the beginning and end of each strip so I could take them down easier. That was a lot of soldering, but the Deans style connectors are pretty easy to solder (wish I had them at the start!). There are some YouTube videos with demos on how to solder them. You could also run the power wires separately in longer runs independent of the strips. The strips would still be removable and testable individually.
So, you will see a mix of JST-M 2 and Deans style connectors in the photos since I switched in mid-project. I found the Deans style connectors easier to work with - easier to solder, and the polarity was obvious.
For my house, I only had a few locations where there were power outlets available, so I had to carefully plan out where the wall adapters were located and which LEDs they would supply. For my wiring then, I had power going in a couple directions, and the attached diagram shows where I ended up at the planning stage.
Since I had to add power over some long distances, the other technique is to use higher voltage wall adapters and DC to DC converters to convert the higher voltage to 5 volts right at the strips. This seemed to work well, and power injection was still used from the converter to the surrounding LEDs. One trick with the DC to DC converters is keeping them waterproof while allowing them to dissipate heat. I will try a pill bottle and see how it goes.
One other idea is to run separate power adapters or DC to DC converters for each set of 50 or so LEDs. The cost of the converters and power supplies would be lower since they would not need to handle as much power, but the wiring would likely end up being as complex.
The attached plans show what I was thinking before I started wiring, and what I ended up with.
Step 3: Mounting the Strips and Waterproofing
The molding was attached to the eaves with screw eyes and cup hooks. That way, each segment can be taken down as needed for repair or to move for painting etc.
To mount the LED strips, I attached them to thin plastic molding to give them some rigidity. Each strip was cut to the proper length for the portion of the roof they were to go on. I kept them from touching each other since there will be connectors on each end.
The cup hooks go on the house at places that make sense - every few feet. I spray painted mine to match the house. I drilled pilot holes to make it easier to screw them in. Then you can hold the strip up and mark the locations in the bottom of the strip for the screw eyes. I drilled a small pilot hole at the marks (see pictures), and screwed the screw eyes in.
Now, you can cut the LED strips to match each plastic strip. The LED strips have certain locations with solder pads where they can be cut, so the plastic strips may be a bit long in some cases, which is not a big problem - barely noticeable that the LEDS have a small gap with so many lit up. I used zip ties every few inches (every three solder pads) to attach the LED strips to the plastic strips. You will need to solder connectors on the end, so don't put zip ties at the very end until you are done. Leaving a couple off for now will make the soldering easier, and you can add the end zip ties after the soldering is complete and the strip is tested.
Once all the connections were made and the LEDs tested, I used RTV silicone to seal up the ends of the strips.
I used water tight kitchen storage containers to hold the power adapters with holes drilled for the connectors to pass through. I sealed those holes with RTV silicone also.
Step 4: Troubleshooting
I had a number of LEDs that did not work at all or had one color broken. I am not sure if it was inherent in the quality of the LEDs, or from bad voltages/signals in my system.
The first LED can burn out more often than others, especially if you are not using capacitors on the power supplies. If you have a bad LED, generally all LEDs after that one will not go on. To test this, power up just that strip, and use a breadboard jumper wire to connect the data out copper trace from the previous LED to the data input copper trace of the next LED. I pushed the jumper wire pins right through the silicone jacket to make these connections.
Sometimes, a lit LED does not pass the data, and needs to be replaced. Sometimes, the first dark LED is the one that needs to be replaced. By jumping the data line, you should be able to decide which case you have.
Once you have identified the LED to be replaced, cut the silicone jacket between the LEDs next to it - using the space between the LEDs will keep the LED clear when you glue the jacket back together. Cut out the LED at the cut marks - you will want the copper pads of the two surrounding LEDs on the strip to be cut so they are right at the edge so solder can bridge to them. Cut a new LED in the same way - with the copper right up to the edge. Then, solder a bridge for the three lines (+5, Gnd, and Data) to add the new LED to the string.
It is possible that UV light will affect the lifetime of the LEDs.
I had some power distribution issues. Although I spent time making sure I was not exceeding the 10 amps available with each adapter, there was more voltage drop in the wires than I expected.
One symptom for this issue is seeing some flashing lights in random colors in the string. A second, more subtle symptom of power issues is when you have the LEDs on at full white, and some of them seem more orange in color - typically near the end of a string.
One way to verify this as a power issue is to run the strips at low values or brightness for the LEDs, then try them at full brightness, including white. If the dimmer level works while the brighter flickers, then it's most likely a power issue. I also wrote a program to make the whole strip fade from zero to all colors full on in a slow loop to look for those effects.
If you have any of these issues, you will need to improve the power wires, or add more power supplies in the strings. If the power supply is relatively close (a few feet) to the set of LEDs, you can use power injection to help - see the planning step and links.
If the power supply needs to be farther away, you can use a higher voltage power supply and DC to DC converter to step the voltage down nearer to the LED strip.
I used a combination of these techniques to enable full white on my LED strips.
Step 5: Programming
To control the strips, I used an Arduino. In my case, I had 500+ LEDs, so I needed an Arduino Mega to have enough memory to hold the RGB array (3 bytes per LED for the R, G, and B color byte values).
For the LED control, I used the Adafruit Neopixel library, and added a few new animation routines. The code is attached. The signal wires for the LED strip was connected to pin 6, and the ground wire needs to be connected with the Arduino for the signal reference. In addition, I just used the 5 volts from the strip to power the Arduino, so the Arduino is powered from the 5v pin.
There are other libraries like FastSPI and one from Pololu. There is also an Arduino code sample that only needs an Uno since it does not use an array.
You could also use a controller like the T-1000s and LED Edit, though I had a lot of trouble getting that working with the Java version on my machine, so I would not recommend that unless you like to tinker.
Now that I have the LEDs up, the real art is in the programming and animations!
Step 6: More Ideas
Pulling out the Arduino, and downloading a new animation for each holiday can be a hassle, so you could add a panel of push buttons for each holiday. I have now posted another Instructable on how to make this project controllable from the web to make reprogramming easier.
CHMG made it!
We have a be nice policy.
Please be positive and constructive.