capacitors and power-up loads

I have a device (a 4.3inch Nextion touchscreen) that wants a big whack of current when it starts up (am told that this is typical of backlit tft displays). If it can't get the current it wants (almost 1A!) at startup time, it keeps trying to boot and failing and (they tell me) can eventually damage itself.

So, I'm trying to run it off a not-really-adequate BB power supply because I don't have a better 5v supply lying around. Sometimes (when already warm, as far as I can tell) it starts up OK and sometimes it doesn't, but I'm worried about the damage potential.

I live far, far from parts stores, which means a whole lot of delayed gratification and desperate improvisation. I do have more capable power supplies on order, but what with the holidays it may be weeks before they arrive, and it's frustrating not being able to run the device (safely).

So it occurred to me that I have a separate switch for the Nextion; I can power up the P/S first and then later turn on the screen. And I remember dimly that capacitors can store power and release it on demand. I already have an electrolytic cap across the 5v bus. If I had a big enough cap, and I turned on the p/s first and let the capacitor charge up, then turned on the display, would that take care of the initial demand?

What I don't understand, being not EE-savvy (though I'm learning a lot from tinkering with my Arduini) is the scale factor: how big a capacitor it would take to supply 1A at 5vdc for... I don't know, a few ms? Would this be a great big expensive thing with quarter-inch screw terminals, or could I get by with stuff from my parts box? My caps are rated in uF. Am I a couple of orders of magnitude away from the answer?

When I try to read online about capacitance and so on, I seem always to find texts so technical that I get lost right away :slight_smile: The only wisdom I have managed to glean so far is that capacitors are "backwards" compared to resistors: when connected in parallel their capacitance is summed. So I was wondering if I could just stick several of my biggest electro caps (470uF) across the 5v and gnd bus :slight_smile:

Tazling:
So I was wondering if I could just stick several of my biggest electro caps (470uF) across the 5v and gnd bus

You could do, won't hurt might help.

Tazling:
I live far, far from parts stores

I also live far away from China.

Deva_Rishi:
I also live far away from China.

:stuck_out_tongue_closed_eyes: :stuck_out_tongue_closed_eyes:

If you can find better info about how much current is needed and for how long, it's pretty trivial to get the required capacitance - current (I) = charge (Q)/time (t) and capacitance (C) = charge (Q)/voltage (V), so C = I*t/V
There's more to it than that because there's technically a bit of calculus necessary but as a ballpark/order of magnitude, that should give you a start.

Throwing an inductor in series with the power to the display will also give you a poor man's soft starter. That might be an unnecessary added hassle but it's an option if you happen to have any lying around.

Have you tried reducing the brightness of the backlight at power up?

dims=50

Will set the brightness at 50% next time it is powered up and reduce the current. I don't know if this will fix your problem but maybe worth trying.

@ deva_rishi

"far from China" :slight_smile: good one!! yep but I am even far from spendy storefront parts store options. as in an overnight trip to reach the nearest electronics hobby shop. mail order from digikey or mouser is the quickest way (ouch $$ and a week min) and sale-priced stuff from Banggood and other CN outlets can take... months....

@saximus, you've already lost me (partially)... but this may be a teachable moment...
what are the units?

current (I) = charge (Q)/time (t)

capacitance (C) = charge (Q)/voltage (V), so C = I*t/V

What is "charge"? Current is amps or mA, that I know.
anyway, looks like you cancelled out "charge" so I can ignore it?

Capacitance = current * time / voltage ??

current is, let's say, worst case 1A.
time is, hmm, worst case maybe 100ms.
voltage we know, it's 5vdc.

1 * .10 / 5? .1/5 or .02?

So my capacitance would be 20mF? milliFarads? or is there further unit conversion?

If it is 20mF and my caps are rated in uF then I am indeed a long way out of the ballpark!
2 of my 470uF makes less than 1mf, so I would need, what, about 50 of 'em? pretty sight.

@perrybebbington

that's clever! but I need to fire up the Nextion in order to flash its firmware. right now (today) it doesn't want to start up at all. I see you have spent some time with them. I have a real love/hate relationship with the thing. or more properly with ITEAD. but I gotta admit, for the price, it's amazing.

one more thought: just remembered I have a few small buck converter breakouts (12v to... adjustable). I used a couple to run 6v LED arrays off 12v boat power, years ago. I don't know what the current rating is on those but it seems like I could build my own temporary power supply with a 12v wall wart and the buck converter, to provide a 5v rail. And maybe it would put out 1A for a few ms without burning up :slight_smile: seems worth a try anyway. plenty of 12v wall warts in the bin (I never throw them out after the dc powered toy dies).

Charge is measured in coulombs but yes, it's not really important since it cancelled out.

The maths looks right but don't forget it doesn't need to supply all of the necessary current because your power supply will still be there to do some of the work. It's probably not going to be easy to find but a graphical representation of the startup current will give you a much better idea of what's required.
This may all be over the top though. If you just start with one or two of your 460uF caps, it will either work or not and you can go from there. Since they're electrolytic, just make sure you get the polarity right.

Hi,
What your equations assume is that the voltage will drop to 0v, it won't it will dip because of the power supply you have charging it will also be supplying current.

Try 470uF and even two in parallel.
Wire them at the power terminals of the display to make full use of their storage, or with wires as short as possible if you are fitting a switch between the capacitor and the display positive power terminal.

I don't know what size wire you re using, but its a good practice to have the positive and gnd wires a bit beafier than the others if surge currents are concerned.

Tom... :slight_smile:

Tazling your question got me wondering so I connected a 4.3" Nextion with the power through a 1 ohm resistor and connected my oscilloscope across that. What I found is that on power up the current rises fairy smothly to 200mA (no spike) then there are 880mA spikes every 260ms.

I had been vaguly aware that the Nextion displays were noisy becasue they, for example, interfere with a GPS receiver I am using in one of my projects. You asking this question prompted me to look a bit closer and now I am wondering if I need to include an inductor in the supply, mounted on the back of the display.

You might also be interested to know I have a Nextion 7" enhanced CTP which is powered by an LM2574 SMPS mounted close to it. The LM2574 is rated at 0.5A. This has been working perfectly well for over a year.

I realise you only have the parts you have, and if getting new parts is difficult then that's a pain, but I get the impression the power supply you are using must be really crap. Try the suggestions here, don't be afraid to add more capacitors and try the buck convertor you have.

The differential equation for a perfect capacitor is just:
I dt = C dV
Typically I and V are functions of time and C is constant.

You can rearrange to
dV/dt = I/C

or to
Q = CV (Q, charge, being the integral of current)

Things get more complicated if the capacitance can change (non-linear dielectric, moving capacitor
plates, electret condenser microphone, etc etc).

Just checking back to say that I added an additional 470 uF across 5vdc to ground and it seemed to help! The display blinked a couple of times but then started up and ran (mostly) normally. I think I'll add a third :slight_smile:

I did see something new & odd, which was bits of one page persisting when a different page is loaded (this is a Nextion not an Arduino issue so doesn't really belong here... but maybe Perry has a thought?). Intermittent. Not entirely reproducible. Mysterious, never before encountered.

But as far as running the TS off my feeble 500mA cheapie bb p/s until I can get a beefier one, capacitors look like a good enough hack. As far as noise, yes I had noticed that the Nextion seems to generate some noise as in RF, but not sure how bad it really is. My i2c traffic seems robust so it's not doing much harm (yet).

@Perry forgive my EEdiocy, but an inductor is a wound coil, right? And how does one apply a coil to reduce the noise? (oh boy, something new to google)

@TomGeorge, interesting point about wire. If you had 4 wires going to an i2c breakout for example, would you use 22 for power and ground but 30 would do for sda and scl?

Tazling:
Just checking back to say that I added an additional 470 uF across 5vdc to ground and it seemed to help! The display blinked a couple of times but then started up and ran (mostly) normally. I think I'll add a third :slight_smile:

I did see something new & odd, which was bits of one page persisting when a different page is loaded (this is a Nextion not an Arduino issue so doesn't really belong here... but maybe Perry has a thought?). Intermittent. Not entirely reproducible. Mysterious, never before encountered.

But as far as running the TS off my feeble 500mA cheapie bb p/s until I can get a beefier one, capacitors look like a good enough hack. As far as noise, yes I had noticed that the Nextion seems to generate some noise as in RF, but not sure how bad it really is. My i2c traffic seems robust so it's not doing much harm (yet).

@Perry forgive my EEdiocy, but an inductor is a wound coil, right? And how does one apply a coil to reduce the noise? (oh boy, something new to google)

@TomGeorge, interesting point about wire. If you had 4 wires going to an i2c breakout for example, would you use 22 for power and ground but 30 would do for sda and scl?

I've not seen the problem of pages not loading properly, however, I work on the principal that where you have more than one problem, and one of the problems has a solution you know how to apply then fix that problem first and often the other problems go away or at least get less bad. In this case the problem you know how to fix is the power supply.

An inductor is coil of wire, yes. Inductors tend to block AC. Noise is AC. Inductors block noise. In the case of something like this, one in series with the +ve supply wire as close to the noise source as possible, which probably means unsoldering and disconnecting the +ve connection on the connector to the PCB an inserting an inductor in series between the connector and the board. As to the value, probably a few 100mH, but there are people here better able than me to suggest an appropriate value.

Since my last post I played some more. The only means I have to detect noise is to use and oscilloscope to see the noise on the supply wires. I don't have any equipment to detect radiated RF noise. I don't even have a portable radio, which would probably make an effective detector for radiated RF noise. Anyway, I found that the usual 0.1uF capacitor across the supply is entirely inadequate in this case. On one of my 7" CTPs I added 470uF across the power connector and as far as I am able to detect it that got rid of the noise it was injecting into the power supply.

Hi,
Are you turning on the power and letting the caps charge, then switching the display on?

With gnd connections, if any is going to be conducting significant current in your project, it may help if the heavier current gnds go back to a single connection point as close to the power inlet of your project.
Connect them in a star formation, this way any currents will only be confined to the relevant gnds, and not travelling though gnds connected to other components.

Tom... :slight_smile:

TomGeorge:
Are you turning on the power and letting the caps charge, then switching the display on?

This was my reaction, too.

Maybe I missed something above, but if the display gets juice at the same time as the MCU, the caps will compete for that juice, rather than contributing.

If the display doesn't attempt to start up until the MCU tells it too, the juice could be available.

Alternatively, using a MOSFET switched on by the MCU after the caps have had time to charge is another possibility.