Need guidance for selecting appropriate power supply and for connecting a lot of LEDs properly


I need guidance related to my home decoration LED project. I want to power exactly 540 LEDs (WS2812B), and then control them through Arduino Nano. So i did some Math@Physics and found that, all 540 LEDs at their full brightness will NOT require a power supply which is more powerful than 5 volt 32.4 amp 162 watt. So i decided to go for a 5 volt 30 amp 150 watt power supply. But my friend warned me that 30 amp are too high and it will surely melt the wires and can also burn the LED strip. So i came up with 3 different diagrams; Please check the attachment and tell me, which one is the safest and which one is the worse?

Thank you :slight_smile:

Multiple power connections will be needed. You get a voltage drop through the LED strip's built-in power conductors and it might be possible to melt them... Adafruit recommends "injecting power every meter.

The second diagram looks like good enough. Make sure to connect the 3 LED power lines, both positive and ground, directly to the power supply.
Likely each LED strip will do better being injected power, positive and negative, in more than one point. Running 10 amps through the first LED part sounds like too much to me.

It is also recommended that the data line from the Arduino to the first pixel of the first strip have a 470Ω resistor in series and a 1000uF cap across the 5V supply to each strip.

Undersizing a power supply is foolish economy. Generally the power supply takes all of the punishment from the system and adsorbes all faults. By undersizing you will cause them to exceed their rating and greatly reduce there life. When doing a design determine how much power you need, add maybe 10% or so (I usually do 25%) to keep things cool. The cooler they run the longer they last. Size your wire properly to comfortably support your load(s). You may have to add fuses to protect your wire, which fuses do very well as do breakers. Your case is not as straightforward as it appears, your max load exceeds your power source capability but it may never come close depending on how many LEDs are on and at what power level. My experience has taught me to design for worse case. If you get a fault of some type and all the LEDS turn on???

Your friend is wrong. You could use a 1,000 Amp power supply safely because the LEDs will only use the current they need.

In all your diagrams you do not have the Nano ground connected to the strip supply ground.

You must do this as the signal from the Nano is with respect to the Nano gnd, not the strip supply gnd.

Connect the Nano supply gnd at the strip supply -ve terminal.
In the 3rd diagram connect ALL -ve and gnds together.

Tom... :smiley: :+1: :coffee: :australia:

1 Like

@TomGeorge Yes, you're right. I forgot to show the connection between Arduino Nano's GND and LED strip's GND. Thanks for pointing this out :slight_smile:

@SteveMann Are you 100% sure? And if you are then, how much maximum current limit should i set while writing a code in Arduino IDE?

@gilshultz Thank you for your suggestion. I thought, i should buy a power supply below max requirement because i may never go beyond 7 Amp.

@groundFungus Yes, i will surely keep this in my mind. However 470 Ohm resistor was giving me weird issues in my first project of around 100 LEDs last year.

@DVDdoug @Railroader Power injection as shown in 2nd diagram. Thanks for your guidance :slight_smile:

Doesn't matter as long as the power supply is adequately rated.

540 LEDS at 55 mA each on full white is just under 30 Amps so a 30 Amp supply is probably OK.

Now all three of your diagrams have faults. I will explain the grounding in a moment.

You can run the whole strip (presuming a Nano has sufficient RAM for 540 LEDs, I don't recall the figure just at present; that is another matter) as a "single" strip, similar to the first. A Nano is a far better choice than a UNO (and that in general).

It is true that 30 Amps could simply melt the foil on the LED strips, although it would probably just fail to light that many of the LEDs. The point is you must use cable rated for 30 Amps, probably about 4 mm². You run that cable alongside the strip so that it taps in to the strip each 1.5 meres or so - of course to both 5 V and ground.

That means at each tap it feeds power both forward and back along the strip, just as in diagram one you proposed feeding it at both ends.

So, you have a 5 V supply. The Nano requires 5 V to operate. Powering it via "Vin" is always a bad idea. Now to start, the data from the Nano to the beginning of the strip must run as a pair withe the ground, never separately. So what you do is to include with that pair, the 5 V coming back from the beginning of the strip to the "5V" or "Vcc" pin on the Nano. Three wires as a single bundle. This means there is no danger of the strip being powered and not the Nano (or vice versa).

By the same token, if there is any separation of strips in the chain, the data from one to the next must be accompanied by a ground, again as a pair. And that ground might carry some of the power to the LED strips depending on how the power is wired. This represents a major blunder with the second and third diagrams you showed.

As to the suggestion of problems with the 470 Ohm resistor, there will be no problems as long as the resistor is located at the "Data in" connection of the strip and you are using 5 V logic such as a Nano. If you try and operate it from 3.3 V logic such as an ESP8266 you may certainly encounter problems.

1 Like

I've never used the setMaxPower... statement- I just accept the defaults.

@Paul_B You suggested, “Powering Arduino Nano via VIN pin is always a bad idea”. So should i never use a 9 volt 1 amp wall wart power supply to power Nano? Actually i thought, once i upload a FastLED example to Nano, i won’t have to plug it to PC/laptop and instead i will have to use VIN pin of Nano to power it. Can you recommend a proper wall wart adapter to power Nano? I means, volts and amp rating. I have a genuine Arduino Nano and i don’t want to damage it.

Thanks for all of your guidance :slight_smile:

I personally always use VIN, it gives me additional filtering and noise suppression plus it filters some power glitches as well. I try to power it with about 7.5 - 10 volts. Depending on the design I use a switch mode converter, preferably SEPIC to set the voltage to VIN. It is not necessarily the cheapest solution but it works. Remember the Arduino a power supply it is not. The 9V 1A wall wart is great for the Nano. Watch what you connect, and keep the total load below 75 mills if possible. You can delve into the specifications and you will find I am giving relatively conservative numbers. With VIN it isolates itself from the USB and will not feed back into your computer.

Thanks for letting us know. Have a great Holiday season!

@gilshultz That is exactly i want. When Nano is connected to PC/laptop, i want to write some sketches and then upload them to nano and then disconnect Nano from PC/laptop and power it through a 9volt 1amp wall wart (via VIC) power supply and then enjoy different patterns daily at-least for 2 to 3 hours throughout the holiday session. Hope this will not damage my lovely Arduino Nano (Italiano) :slight_smile:

Can i use my old Nokia phone’s wall-wart charger to power Nano through VIN pin? It is rated 5.7 v 800 mA.

Probably not, there is no head room for the regulator to work. I think the spec says 7V minimum. You might check the output, it may be more than 5.7 but I really do not know.

@gilshultz Thanks for your advice sir. I want to thank everyone here at Arduino forum for helping both professionals and non-professionals (like me).

1 Like