Building a Large LED Matrix (How To)

I’m going to walk through building a 32 x 32 serpentine matrix with 20 LED/meter (5cm pitch) fairy lights. To maximize frame rates, I use two data pins. So physically, we will have two 16 x 32 panels side by side. But WLED will treat them as one 32 x 32 matrix.
The total cost including lights and shipping will be around $70.

  • 60M 1200LED fairy lights - $51
  • 5V 12A power supply - $11
  • 1/2" White PEX Pipe 2x 5 ft - $9

If you don’t regularly dabble with electronics and LEDs, you may also need to pick up 18-20AWG 2 core wire, 22AWG 3 core wire, heat shrink tubing and JST-SM connectors. But I’m going to assume that everyone has boxes of JST connectors, pins, crimpers and wire strippers laying around.

PEX Frame

I’m using 1/2" PEX pipe along the top and bottom of the matrix. Although PEX and Schedule 40 PVC pipe look similar, PVC is too rigid and won’t work. When purchasing the PEX, you will find that you can buy a 10 foot section for the same price as a 5 foot section. However, the 5 foot sections are going to be nice and straight and the 10 foot sections are going to have bends that you will have to work out. The fairy lights have a 2" (5cm) spacing between pixels. But there is only 1.5" (3.8cm) of wire between beads. So you have two options; you can either have 1.5" spacing horizontally and 2" spacing vertically, or you can keep 2" spacing in both directions by 3D printing a triangular hooks that will offset the first pixel of a strand in one direction and the last pixel in a strand in the opposite direction. Because it is easier, I will stick with the 1.5" spacing for this guide. I may show you how to do keep 2" spacing in another guide.

Cutting Slots

We will be cutting 1.5" wide, “U” shaped tabs into the PEX tubing. The fairy lights will hook under the tabs and when completed, the PEX will be rotated so that the slots and tabs will be in the back and not be visible. Rather than marking the PEX with cutting guides, I took a small strip of 1/2" plywood and marked every 1.5". I cut the slots into the PEX using a compound miter saw. If you rested the pipe against the back rest, the blade would cut at a sharp downward angle. I used a small piece of 3/4" x 2.5" hardwood flooring as a back rest so that the center of the pipe is even with the center of the saw blade and the cut is flat. And the groove of the hardwood flooring matched well with the curvature of the pipe, to hold it securely. (If you don’t have a compound miter saw, you can by a hand saw and miter block at Harbor Freight for under $10.) Start by marking the center of the pipe, then offset your first cut 3/4" from the center mark. Make 16 cuts on each side of the center mark. Be careful not to rotate the pipe as you are cutting. Also try to cut each slot to the same depth.

Cutting Tabs

Once all 64 slots are cut (32 in each pipe), you need to take a utility knife and cut the edge between every other slot to make a 1.5" tab to hold the strand of fairy lights. And the tabs must be offset. I’m feeding my wires in from the bottom. So on the bottom pipe, I cut between slots 2-3, 4-5, 6-7… and on the top cut between 1-2, 3-4, 5-6 and so on. We also need some space to feed the start of each strand in at slots 1 and 17 on the bottom pipe. So make a cut between 1-2 and 17-18 on the bottom pipe (there will effectively be a cut between 1-3 and 16-19). Because we want the slots and tabs to be facing away from the viewers when installed, you will be cutting down the left side of the slots on the bottom piece and the right side of the slots on the top piece.

Snaking the Strands

Feed a 2 core 18AWG or 20AWG wire for power injection down the entire length of the bottom pipe. Feed two 3 core 22AWG header wires, pulling one through slot 1 and one through slot 17. Solder the header wire in slot 1 to the beginning of your fairy light strand. Use 1 or 2mm heat shrink tube over each individual wire and 6mm heat shrink over top. If you purchased the 5cm lights I linked to above, the power line is the outside wire with faint gold bands, the ground is the outside plain silver wire. The two center wires are data and backup data. It doesn’t matter which is which because you will solder them together at the start of the string. But if you have to splice on another string, keep the wires separate attaching gold to gold and silver to silver.

Measuring Strands

I marked each 32 pixel strand by sticking a thin piece of masking tape just after the first pixel in each strand. The reason I did it after the first pixel is that I didn’t want the tape getting in the way as I’m adding power injection points and stuffing the wires into the tabs. If you have your controller ready to go, you can hook it up and let WLED do the counting. In WLED, go to segments and set the “spacing” to 31. Now just the first light of every 32 pixel strand is lit. Put a tape marker after each lit pixel. Count the first strand to verify you got it right.

If you don’t have your controller ready to go, you can measure manually. Take a piece of wire or a non-stretch string and cut it to the length of 32 pixels, either by counting or measuring 64" or 160cm. You don’t need to unroll and measure the entire length at once. But you will get fewer twists if you carefully unwind a large section and measure it.

Winding the Serpent

When installed, the cuts in the PEX pipes will be on the back side of the matrix. You will be working from the back side, with the cuts facing up. If slot 1 will be on the left side when installed, it will be on the right side as you build it. I put a bead of hot glue just before the first pixel to hold the first strand taunt. Once the glue cools, lift the first tab with a screwdriver and pull the wire back through until the glue bead is inside and close the tab. Stretch out the first strand of 32 pixels removing all twists before hooking it under the first tab on the top pipe. Repeat a few more times.

Power Injection

Here comes the tedious part. We have to inject power at multiple points in each 16 x 32 panel. You will need power injection at slots 6 and 12 on the first panel, slots 22 and 28 on the second panel. Mark those slots with tape so you know where to inject power when you get to them. When you get to a power injection point, cut the length of the wire between the two pixels between the data, ground and power. Solder in 3" pieces of 22AWG wire with a piece of 2mm heat shrink tube to protect the joint.
power_injection_bead

Pull back the tab at slot and fish out the power injection wires a few inches. Solder the short leads to the power injection cables and stuff back into the pipe. Pay close attention that you attach power to power and ground to ground.

Finishing Up Construction

After your second power injection point, the rest of the first panel should come together quickly. At the end of the 16th strand, you will need to cut off the remainder of that roll. Do not cut it off flush with the end of the pixel. Instead leave a short tail and add another bead of hot glue to hold the strand taunt. Repeat the process to build the second panel. After you attach the fourth injection point, you can remove the remainder of the power injection line. Attach female JST-SM connectors to the 3 wire leads. Wire a 10A inline fuse into the power injection line and attach to your power supply.

To mount my matrix, I cut a 3/4" x 1.5" trim board to the width of my window. I attached the top pipe to the board by stapling a loop of plastic strapping. Once the matrix was attached to the trim board, I mounted the trim board to the walls with screws. To help hold the strands straight, I weighted the bottom pipe with a lead wire for fishing.

Setting up WLED

You will need to be using WLED 0.14+. In LED preferences, configure your two data pins. For each pin, set the length to 512 and if you got the 4 pin lights from Know Shine, set the color order to BGR.

In 2D settings, change it to “2D Matrix” and even though it is technically two 16 x 32 panels on 2 pins, if you set the correct number of LEDs in the previous step, you can configure as a single 32x32 panel here. Set the location of the first pixel, mine is bottom left. The orientation is vertical. Select the “Serpentine” checkbox.

That is pretty much it. Sit back and enjoy your work.

4 Likes

If there is an area you think needs covered in more detail or you would like a picture or illustration, please let me know.

2 Likes

In the 1.5" between pixels at the ends of the successive strands, it would seem that the wire needs to twise a couple of times. The wire being flat from the front, will need to twist 90 degrees before it will bend sideways. I have tried not to bend the flat cable too close to the epoxy blobs, perhaps being overly cautious.

Did you find the bends to be a problem?

(I assume your beads do face towards the audience; if you face them sideways, that does make the bending easier).

I’m turning the lights sideways and making straight bends in the wire. You would need smaller spacing horizontally to do otherwise and it would put a lot more stress on very thin wire to do otherwise.

1 Like

The epoxy beads do a good job of dispersing the light. The beads have to be facing away before you see the dark spot from the circuitry.

1 Like

OK, thanks. The stress & geometery issues you mention was indeed my concern.

Any comments on the visual effect of putting the beads sideways? I would think it might make alternate strips bright/dim when viewed from an angle, but perhaps it’s not noticable.

Of course, putting a half twist in each crossover between strips (while bending as you do) would be less stressful than needing a twist at the right angle bend adjacent to a bead, and thus one could avoid alternating front faces for adjacent strips - the matrix would be more uniformly bright from one side and dim from the other.

A while back I did one matrix on plywood using the earlier “seperate bare (appearing) solid wire” type addressable fairy lights, but the matrix has something like 3" x 4" spacing, That wire is less directional in its bending, compared to the plastic coated stranded flat cable style. I like and trust the newer flat stranded cables better.

My solution for facing the flat cable style forward in a future project was going to be threading the strands through holes in plywood at each end so the visible strip is flat against the plywood berween the holes, but ‘sacrificing’ one inline pixel in the crossover between each strip (hidden behind the plywood) , and making software adjustments. I may still do that. I do like your pipe arrangement tho!

Thanks for the 50mm spacing fairy lights link, by the way; I have seen many sources for 100mm spacing but I like the finer pitch.

That is certainly an option. If you are doing it on plywood and only viewing from the front you have more flexibility with hiding another bead between strands. But there’s not enough room for that in a 1/2” PEX pipe. And no, you can’t tell every other row is facing in the opposite direction.

2 Likes