I am having power issue lighting up my WS2812b LEDs. I’ve attached a diagram of my setup to help follow along. I have 2 strips w/ 84 LEDs each connected to an Arduino Nano on separate pins for the data line. And the Power/GND is connected to the bread board drawing power from a battery/UBEC, not from the nano. The battery/UBEC does power the nano as well.
I have (3) pots which change color of each of the two strips independently and then the 3rd pot changes the brightness of both strips of LEDs. Then I also have some push buttons that have an LED in each of them (dumb LEDs not WS2812.)
What I have noticed when I get the brightness high enough the WS2812b LEDs tend to “shimmer” is the word I’ll go with. They don’t turn off, but there is definitely something going wrong. I’m just showing a solid color and no animations. My conclusion reading other’s posts and some voltage measuring on my circuit is that it’s happening because the voltage gets too low.
Other’s have noted they will “inject” another power input to the LED strip. Is that what you think my problem is? When I read other’s posts it seams like they are talking about a lot more LEDs than I have setup. So as a noob I didn’t think it would be an issue with this many.
If it is a power issue, how do you go about adding another volt input to the LEDs? In my setup should I connect a 2nd UBEC to the battery and then at the end of the LED strip? Or do you need a separate battery?
Yes, the voltage dropping that much is the problem.
A few things you might try:
Use two UBECs, one for each strip since they are only rated for 3A. You may be maxing out the Amps those can provide when you go full brightness, especially if only one UBEC is powering both strips.
And connect the grounds of both.
Run the positive and ground wires DIRECTLY from the UBEC to the LED strip. ie. Do not have power for the strips go through the breadboard. Always make that connection direct, short, and with appropriately sized wire for the current needed.
Run a second set of positive and ground wires to the far end of each strip so it’s getting power from each end.
Consider adding a 1000uF capacitor (rated 25V or more) across the 5V positive and negative wires near the start of each strip.
After doing the above if you’re still having shimmering you can limit your max brightness to something less then 255 in your code if that will work for your project.
(Thank you for the nice clear diagram of your setup and your measured voltages.)
@DUCKBLOODnSLEWMUD you’ve proven that it’s a power supply issue with 2.7v at the end only the strip on high brightness. Your Bec is likely shutting down on current limit.
You could test the voltage at your bec output. If it drops to a low value it’s your bec shutting down. Those hobbywing ones are pretty good. And the one I have will happily shutdown at 3.1A.
Thanks all for the input. A little more data on my original setup. I do have a 1000uF 16v cap on breadboard on one of the strips and also connected to other strip with jumpers. It physically is only about 6 inches to the first LED (little more for the other via jumpers.) I realize I should have one per strip but only have the one right now. Should I buy some that are 25v or higher? I know I’ve read put it as close to the first LED as you can. But at what distance does it start to really matter? 1 inch away? 10? Haven’t seen any actual values given just “put it close.”
I took some more measurements with my same original setup. With everything turned on, brightness up so I get the shimmering, the voltage at the battery terminals is 6.41v and the voltage on UBEC output side is 3.66v (close to the breadboard reading of 3.4v in original post/picture. So that makes sense you would get a voltage drop going all the way to the opposite side of the breadboard.)
I measured current (full on with shimmering going on) between battery and UBEC input side is 0.652 A and between UBEC output and breadboard was 0.546 A (and I noticed the shimmering starts when this gets around 0.48 A.) So power input = 6.41v*0.652A = 4.18 watts. And on output side P = 3.66v * 0.546 A = 2 watts…is that correct?
I also disconnected the jumpers for the cap so it was only connected to one of the LED strips, no change in the new measurements mentioned.
Next test will be to connect two of the UBECs to power the strips as @marmil mentioned to see what changes.
@Juergen_Bruegl I will have to spend some time looking into your comments and links, at first glance wasn’t sure what that all meant. Need to spend time learning something new now! And FYI the battery says on it “12 Ah.” Is there a “rule of thumb” the top amps you want to draw from a battery, related to Ah rating?
Ok, so my next test, I used (2) UBECs, and set up the same connections as my original, however, with the 2nd UBEC connected to the battery only. I then increased brightness until the shimmer started, and noticed if I connect ONLY the ground of the 2nd UBEC to the end of the LED strip the shimmer stopped. Yes - only the ground. The + was disconnected from everything on the 2nd UBEC. I continued to increase the brightness (with only the ground connected to the end of the strip) and the shimmer started again near the higher brightness levels…so when connecting both the + and - from the 2nd UBEC directly to the end of the LED strip the shimmer stopped. Awesome!
So my question now, after I measured the amps when only using (1) UBEC it was well below the 3A that it is supposedly rated for, why did the shimmer happen? Note they were cheap ones bought off AliEpress so maybe the quality isn’t there with the ones I ordered? Was it not enough volts (which I think was the reason looking at my measured voltages since the measurements show quite a drop at the end of the strip when at higher brightness levels) or not enough amps the UBEC could supply? So the evidence points to a voltage drop, why does that happen? Is that expected over 84 LEDs? Just bad quality UBEC? Other?
Glad you got things working. Can you share a sketch of your new wiring just to confirm how you have it now?
The quality of an LED strip can vary based on the manufacturer and the quality control within their own facility. If the internal traces were a bit on the thin side then that could contribute to more voltage drop over the length of the strip. And yes, there will be some voltage drop after only 84 LEDs. (Providing good power becomes an important part of the design with larger and larger LED creations.)
Thank you all for the help! I’ve attached a link to the PDF schematic of my test setup. Learned a lot and still need to learn more moving forward! Adding in the 2nd UBEC did eliminate the “shimmering” I was seeing. I’ll have to show some pics when the project is finished. I move slow, so may be a while yet! But it is a two player 00-99 scoreboard. The pots change the color for each score, and one to adjust brightness. The buttons change/reset the score. https://drive.google.com/open?id=1Gdv50Nth8wlE9gxhs1kkmWtIG2qhwhUZ
@DUCKBLOODnSLEWMUD
Just on your questions. If the bec measured was supplying below 3A and the voltage at the output of that bec was less than 5V then your bec is faulty. It should maintain 5v until current is greater than 3A.
To measure voltage drop you need to measure voltage coming out minus voltage going in. That is at high brightness was the bec still putting out 5v.
@marmil I have a question in my build the strips are 4meter long an I have put all the power supply at on end. Unless I try to go full white at 255 it seems ok. I have linked all the ground of the other side apparently it’s a mess of noise otherwise ;). Do you suggest that I also try to link 5v on the other side ?
Limiting your max brightness to something a bit less then 255 or using the power management code might be all that you need.
If you have unacceptable inconsistent color (for example it turns more red at the far end due to voltage drop) or you are seeing something like shimmering described above, then you might need to inject power at another location. If the display looks fine though don’t over complicate it.