Saturday, March 14, 2020

Wiring to the Pixels

Connecting the Lights

All my pixels are the 3-wire type (not 4-wire). Two wires are for power and the third is the control signal wire. The control signal is how the controller passes its commands to the first pixel, which squares up the signal and passes it to the next pixel and so on. The power cables provide the power to light up the LEDs.

Many people use pre-made cables and connectors which is the easiest to connect the cables and ensure waterproofing. The size of these cables is usually 0.75mm2 which would not be sufficient to carry all the power for my system (minimum is 1mm2 for the 12V and 1.5mm2 for the 5V) so I would require multiple runs from the power supply to the pixels. I think many people do this however I wanted to have just a single run of cables out from the controller to the pixels (actually 2 runs, one for the 5V and one for the 12V). My aim was to make it simpler to connect with less wires.

The Control Wires

The control wire is easy since it carries almost no power. I used solenoid wire from Bunnings that I had left over from my automatic sprinkler system. 

The distance from the controller to the first pixel, and the maximum distance between pixels is limited as the signal is quite a high frequency. In my system the longest run of the signal cable between pixels is about 6m and I didn't have any problems.

If this had been a problem I would have used a 'null pixel' which is never illuminated by the software but re-shapes the control signal so it can travel to the next pixel.

The 5V control cable went like this:

  1. from the controller to the start of the snowflake
  2. from the end of the snowflake to the start of the bauble
  3. from the end of the bauble to the start of the candy cane

The 12V control cable went like this:


  1. from the controller to the first flood
  2. from the first flood to the first string
  3. from the end of the first string to the second flood
  4. from the second flood to the start of the second string
  5. from the end of the second string to the start of the third flood
  6. from the third flood to the fourth flood
  7. from the fourth flood to the fifth flood

The Power Cable

There are two demands on the power cable. One is to deliver the current and the other is to deliver the voltage. Earlier I have calculated the current (different for each string voltage) so now let's think about the voltage...

Voltage drop is caused by the current running through the resistance of the cable. The resistance of the cable is determined by its length and cross sectional area (to be technical it also depends on the type of metal, but in this case it's always copper, and the temperature but let's not get into that detail). Long skinny cables have the greatest resistance, short fat cables the least. The resistance per metre for the different sizes of cable is provided in the 101 guide and other tables on the internet.

5V Pixel Strings Cables

I'll start with the strings of 5V 50 pixels since the cable size and length is fixed - it is 0.75mm2 at 12cm spacing with Ray Wu's products. The resistance per metre for this cable is 24.5mOhm/m. So the resistance from one pixel to the next is 0.12 x 0.0245 x 2 = 5.88mOhms. The x 2 at the end is because the current has to go back over the same length.

Now to calculate the voltage drop. Ohms law tells us that voltage drop = current x resistance. Think about the very last pixel, which at maximum load (white at full brightness) has 55mA through it's cable. [I used 55 not 60mA this time, as an average of some guides that say 50mA and others that say 60mA.] So the voltage drop from the cable is 55mA x 5.88mOhms = 0.3234mV. Notice that the voltage drop is not dependent on whether it is a 5V or 12V pixel. That's because LEDs are constant-current devices.

Now I'll consider the second last pixel. It has 110mA through it's cable because it is powering its pixel and also carrying the current that goes through to the last pixel. So the voltage drop is double that of the last pixel. The third last pixel will have three times the voltage drop. The voltage drop at the very first pixel will be 50 times. The maximum voltage drop which is the voltage drop at the last pixel will be the sum of all the voltage drops is 1 + 2 + 3 + ... + 50 = 1275 x 0.3234mV = 0.412V.

The 12V strings are similar except the distance between the pixels is 14cm so using the same formulas the maximum voltage drop comes to 0.481V.

I experimented with 5V strings connected in series and found that a 5V power supply connected at one end would light all pixels on 2 x 50 pixel strings and some of a third string. Note that the pixels were not white so it was not done at maximum load. When the 5V power supply was connected at both ends, all the pixels in all 3 strings operated. I have read that at the minimum extreme of voltage the colours may not be correct.

Pixels in the Ornaments

The snowflake uses 48 pixels so I cut off 2 pixels from the end of the string. The volt drop multiplier is (1 + 2 + ... + 48) which is 1178, so the maximum volt drop is 1178 x 0.3234mV = 0.381V. The current in the snowflake is 48 x 0.055 = 2.64A.

The bauble has 124 pixels made up of 50 for the outline and 74 for the face. The maximum number of pixels that could be on are the outline (50 pixels) plus the eyes open (20) plus the mouth open (22) = 92 pixels. After seeing the bauble in action my family decided that the face was too creepy so only the outline was used. That makes the maximum volt drop 0.412V (from calc above). The current is 50 x 0.055 = 2.75A.

The candy cane is the same as the snowflake since it also has 48 pixels.

Adding the currents (Kirchoff's current law) gives the currents in all the cables - see the diagram below:




Note how I have designed the circuit so the current for one string does not pass through any others. In other words the strings are connect as a T from the main power supply. This is because the fat supply cable is large enough to carry the current and not drop as much voltage.

Note that this is the power circuit, the control circuit has all the pixels in series as described in the 'Control Wires' section above.

Overall Volt Drop for Ornaments

Now to calculate the voltage drop in the cable connecting the ornaments. Let's do the calcs assuming a 6mm2 cable - I chose this size because it is the largest that can use standard crimp lugs and still bends ok. The resistance of this size cable is 3.08mOhm/m. Let's aim for no more than 5% voltage drop which is 250mV.

The lengths of cable are: 3m from the controller to the snowflake (the first ornament), then 1.5m to the bauble, then 1.5m to the candy cane (the last ornament).

The volt drop in the last connection (from the bauble to the snowflake) is 1.5 x 2.64 x 0.0038 x 2 = 24mV.

The volt drop in the middle connection (from the snowflake to the bauble) is 1.5 x (2.64 + 2.75) x 0.0038 x 2 = 61mV. Need to add the current of the snowflake to the current of the bauble since this cable is supplying both loads.

The volt drop in the first connection (from the controller to the snowflake) is 1.5 x (2.64 + 2.75 + 2.64) x 0.0038 x 2 = 92mV.
Now I'll go through from the start to the end...

The volt drop at the start of the snowflake is 92mV. The volt drop at the start of the bauble is 92 + 61 = 153mV. The volt drop at the start of the candy cane is 153 + 24 = 177mV. 

The volt drop at the end of the snowflake is 92 + 381 = 473mV.
The volt drop at the end of the bauble is 153 + 412 = 565mV.
The volt drop at the end of the candy cane is 177 + 381 = 558mV.



All these are above the nominal limit of 5% drop! I should have added another connection from the power supply to the end of the pixel strings (injection) to fix the volt drop issue. I decided to 'see how it went' and actually it was ok without the injection.

Another alternative would have been to increase the cable size, but I'm not going to go bigger than a 6mm2 cable - too unweildy and more difficult to connect and more expensive.

12V Strings and Floodlights

The pixel strings and floodlights are connected as shown in the diagram. This arrangement best suited the mounting locations for the LEDs.

The maximum string current is 50 x 55mA = 2.75A. The maximum floodlight current is 0.7A from its specification sheet.

By adding the currents (Kirchoff's Current Law) we can find the currents in all the cables:




The maximum volt drop at the end of the 50 pixel string is 0.481V, calculated earlier.

Let's use the same cable, 6mm2 which has 3.08mOhm/m.



Again, should aim for a maximum drop of 5% of 12V which is 600mV.


Volt drop (1) = 4m x 0.7A x 3.08mOhm/m x 2 = 17mV
V (2) = 6 x 0.7 x 3.08 x 2 = 26mV
V (3) = 4 x 2.1 x 3.08 x 2 = 51mV
V (4) = 5 x 5.55 x 3.08 x 2 = 171mV
V (5) = 3 x 2.75 x 3.08 x 2 = 51mV
V (6) = 3 x 9 x 3.08 x 2 = 166mV

Adding the voltages (Kirchoff's voltage law) gives:

Volt drop at flood 1 = V(6) = 166mV
Volt drop at the start of string 1 = V(6) + V(5) = 166 + 51 = 217mV
Volt drop at the end of string 1 = 217 + 481 = 698mV
Volt drop at flood 2 = V(6) + V(4) = 166 + 171 = 337mV
Volt drop at the start of string 2 = flood 2 = 337mV
Volt drop at the end of string 2 = 337 + 481 = 818mV
Volt drop at flood 3 = V(6) + V(4) + V(3) = 166 + 171 + 51 = 388mV
Volt drop at flood 4 = flood 3 + V(2) = 388 + 26 = 414mV
Volt drop at flood 5 = flood 3 + V(1) = 388 + 17 = 405mV

The voltage drops at the end of the strings are above the nominal 600mV limit... the largest is 818mV which is a 7% drop... I'll just live with it (without injection) as I did for the 5V system - and it worked!

I bought a 60m reel of 6mm2 twin core cable from eBay for $150 which is $2.50 per metre, ok I think. This is more length than I need, but will have plenty left over for mistakes and enhancements next year!

No comments:

Post a Comment