Author Topic: Supercapacitors and ESR  (Read 2090 times)

0 Members and 1 Guest are viewing this topic.

Offline skyjumperTopic starter

  • Regular Contributor
  • *
  • Posts: 87
Supercapacitors and ESR
« on: June 19, 2020, 12:31:35 am »
I'm working on a circuit with an ESP32. The device needs to stay up long enough for the mpu to finish writing and closing a file on an SD card when power is lost (there is a circuit that triggers an ISR when input power is lost). I'm experimenting with supercapacitors. I started with a 0.1F capacitor and then tried a 0.3F. Neither held my mpu up long enough. I tacked an additional 0.47F supercap on to the 0.3 and now it works as I need it to. The circuit uses 3.3V logic, and the supercap sits on the V3.3 line.

Okay, it works, but why? The second capacitor I tried is a 330mF (EDLC) Supercapacitor 5.5V Radial, Can 150 Ohm @ 1kHz and this didn't do the job. The cap I added in parallel to it is an Eaton PowerStor Aerogel PM Series 5.0V 0.47F esr = 0.42 Ohm.

So there is a BIG difference in esr. I'm wondering, did adding the second cap work because of the additional 0.47F, or did it work because of the much lower esr? Should I find one cap with a very low esr or one cap with a very high capacity (I found a 1F EDLS with a 300 Ohm esr). Googling about ESR and why it's important didn't reveal much. 

I would appreciate someone helping me understand whats happening, thank you.

« Last Edit: June 19, 2020, 12:34:10 am by skyjumper »
 

Offline unitedatoms

  • Frequent Contributor
  • **
  • !
  • Posts: 324
  • Country: us
Re: Supercapacitors and ESR
« Reply #1 on: June 19, 2020, 12:57:41 am »
SD card can draw up to 200mA. So the esr needs to be very low for that reason.
Interested in all design related projects no matter how simple, or complicated, slow going or fast, failures or successes
 

Offline wraper

  • Supporter
  • ****
  • Posts: 17575
  • Country: lv
Re: Supercapacitors and ESR
« Reply #2 on: June 19, 2020, 01:07:54 am »
Those supercaps are not made for a rapid discharge. They are for small backup power purposes. Like for running a clock or keeping settings while power is off.
Quote
Googling about ESR and why it's important didn't reveal much
Now try to power you circuit from PSU through 150 Ohm resistor and see what happens.
 

Offline skyjumperTopic starter

  • Regular Contributor
  • *
  • Posts: 87
Re: Supercapacitors and ESR
« Reply #3 on: June 19, 2020, 04:20:26 am »
SD card can draw up to 200mA. So the esr needs to be very low for that reason.

Okay, but how does the esr impact the discharge?
 

Online bdunham7

  • Super Contributor
  • ***
  • Posts: 7998
  • Country: us
Re: Supercapacitors and ESR
« Reply #4 on: June 19, 2020, 04:50:24 am »
An ESR rating at 1 kHz is not a perfect model for your application, but lets say it is.  Equivalent Series Resistance means just that--your available voltage will be reduced by the voltage drop across the ESR, which is the current times that resistance.  If your MCU draws 10mA, your 150 ohms of ESR will cause a 1.5V drop, which I assume will cause your MCU to drop out immediately.

You have multiple things working against you here.  First, you are putting the supercap right on the 3.3V line, which means the voltage starts to drop immediately.  If your MCU drops out at 3.0V, you have only used about 10% of the supercaps energy.  If you had a 5V supply feeding your MCU through a 3.3V LDO regulator, you might be able to get four or five times more run time out of the same capacitor.  Second, writing to an SD card is a variable event--it may take much longer one time than another if it decides to erase some blocks or whatever they do behind the scenes.  So you can't conclude that if it works once, it will always work.

To figure all this out, you need to know what voltage your MCU drops out at and what the power-off SD write event looks like in terms of time and current draw in the worst case.  Then you can calculate how much capacitor you need and what the maximum ESR you can tolerate. Or you an just go Captain Overkill and spend a few bucks on a 5F 5.5V 0.2 ohm supercap which will run about 3 bucks.
« Last Edit: June 19, 2020, 04:54:41 am by bdunham7 »
A 3.5 digit 4.5 digit 5 digit 5.5 digit 6.5 digit 7.5 digit DMM is good enough for most people.
 

Offline Berni

  • Super Contributor
  • ***
  • Posts: 5022
  • Country: si
Re: Supercapacitors and ESR
« Reply #5 on: June 19, 2020, 05:14:53 am »
You need to use the right kind of supercap

The ones designed to supply backup power to real time clocks and memory have a high ESR. Sometimes its >100 Ohm and this is just like a resistor in series with the capacitor, so even if you short the capacitor to 0V you only get 10s of mA out of it. Way too little to run a SD card.

Later on they came up with a low ESR supercapacitor design. These caps have a ESR measured in miliOhms and so they can provide many amps of current. These are what you need. I have been using them to run things like a RaspberryPi for a few seconds from a single capacitor. The trick in getting the most runtime out of it is also to use a boost DC/DC. This makes it keep a steady 3.3V or 5V as the cap discharges from say 5V to 1V. This pulls more energy out of the capacitor due to the larger voltage change so a 1F capacitor might now last as long as a 10F capacitor otherwise would.
 

Offline skyjumperTopic starter

  • Regular Contributor
  • *
  • Posts: 87
Re: Supercapacitors and ESR
« Reply #6 on: June 19, 2020, 05:16:25 am »
Thanks very much bdunham7 !!!

As I am researching this I found this web page that calculates discharge time for a supercap:

http://www.circuits.dk/calculator_capacitor_discharge.htm

I had thought about putting the supercap ahead of the voltage converter, but the board accepts from 9VDC up to 40VDC and usually it will be about 12VDC or 24VDC. The ESP32 drops out at 2.55V, but as I check the datasheet for the ESP32-VROOM-32U I'm using I see that its 3.0V, as you said. The WiFi radio and LEDs and all can easily use 200mA without the SD card in play, but the IRS shuts these things down immediately. Assuming 250mA a 1.5F cap with an esr of 0.26ohm might give me nearly a second.

So, I suspect in the case of my board, it's the 0.47 cap doing all the work while the 0.3F cap with the much higher esr is doing very little.

I had not thought about the SD card considerations you mentioned, thanks for that. I think I'll get a 1.5F cap and see how that does.
 

Offline skyjumperTopic starter

  • Regular Contributor
  • *
  • Posts: 87
Re: Supercapacitors and ESR
« Reply #7 on: June 19, 2020, 05:24:37 am »
You need to use the right kind of supercap

.
.
.

The trick in getting the most runtime out of it is also to use a boost DC/DC. This makes it keep a steady 3.3V or 5V as the cap discharges from say 5V to 1V.

Yeah that makes sense. I did a circuit before with a tiny little DC/DC boost converter.

In this case, this board can be powered by 5VDC from a USB or by voltage in from a battery. The supercap is tapped at the output of the circuit that decides which supply to use when both are connected. So it can never charge a 5.5V cap to 5.5V (unless I use a boost converter in front of it) but if I add a boost converter to the output of it I see it would work.

First I'll just try a massive cap as suggested, if that works well enough I might stick with that.

Thanks very much!
 

Offline just4user

  • Newbie
  • Posts: 7
  • Country: 00
Re: Supercapacitors and ESR
« Reply #8 on: September 22, 2024, 10:43:42 am »
Hey fellas. Any idea how one may cap the current to 1A w/o simply using a resistor to charge the capacitor as fast as possible? I.e. 1A goes through the capacitor till it's full and then a sharp decrease to 0A instead of a gradual decrease. (The 1A limit is to avoid damaging the supply.)
 
The following users thanked this post: BILLPOD

Offline jwet

  • Frequent Contributor
  • **
  • Posts: 517
  • Country: us
Re: Supercapacitors and ESR
« Reply #9 on: September 22, 2024, 04:21:09 pm »
> Any idea how one may cap the current to 1A w/o simply using a resistor to charge the capacitor as fast as possible? I.e. 1A goes through the capacitor till it's full >and then a sharp decrease to 0A instead of a gradual decrease. (The 1A limit is to avoid damaging the supply.)

The classic current limiter circuit uses a PNP with a shunt resistor (.6 ohms will drop .6v at 1 amp) between its base and emitter.  The input voltage is fed into this  resistor at the base.  There is a 470 ohm? or so pull down on base to ground.  The transistor is on and saturated normally (drops about .15v), if the current gets too high the shunt will develop more than .6 and throttle things down. You need a transistor with good beta and high current.  Xetex (now Diodes Inc) make good parts in the "E Line" parts, something like ZTX751 is a favorite- beta is high at 200, Ic is 2A max and Pd is 1W.  While its limiting current, it will dissipate power- its good for a watt which should be enough.

You can get fancier with current mirrors of towards IC solutions like high side current sense amps, comparators.  IC companies even make specialty super cap chargers- LTC4425 is one of the originals.

Have Fun,
John
« Last Edit: September 22, 2024, 04:26:46 pm by jwet »
 


Offline jwet

  • Frequent Contributor
  • **
  • Posts: 517
  • Country: us
Re: Supercapacitors and ESR
« Reply #11 on: September 23, 2024, 01:16:23 am »
Sorry my description was not good and I hadn't given it much thought.  See circuit below- play with it in Falstad.


https://tinyurl.com/29bop267

At this current, power is high in PNP, might want to turn down max current to 250 mA, use 2.2 ohm for Rsense and larger base pull down 1k-2k

I'm not too swift at Falstad, its an interesting tool for quick insight.


Have Fun,
John
« Last Edit: September 23, 2024, 02:00:31 am by jwet »
 
The following users thanked this post: just4user

Offline just4user

  • Newbie
  • Posts: 7
  • Country: 00
Re: Supercapacitors and ESR
« Reply #12 on: September 23, 2024, 05:08:36 am »
Thank you very much John. It does work now.
If I don't find a PNP capable of 1A in nearby stores, I thought I could maybe use multiple less capable ones in parallel as in here:

https://www.falstad.com/circuit/circuitjs.html?ctz=CQAgjCAMB0l3BWEBmAHAJmgdgGzoRmACzICcpkORIJI6ICkDApgLRhgBQAbuDk0VR8mrQVHFEmSJjOgJOAJ2Eh2YeukkqO9JlwAudVEPbohp42FzgtdaIKwI0OZ8kqQsyFTAc4skVFjoHO5YYMie6HAgACbMAGYAhgCuADZ6nADuyqr0YPwqYpCK2WKu1KJCuvDFZQVCtYU0fpkoOBZqNMj0OVAtJN3and1dvQDGQyoj-TSVUNAQ3shEpEGkxOjIeKSBvVnmWqYokOWFLXkC9cczu0fUYtOnBuE4KqQvz1pE1BDstvaOqGcOFc-A8XmwCF8-kCwSwoXCdCisUSqXSWQ+rDetzqN2QCAGX1a7R0LTxBOotXYViKe00PXQOypLxpdDpgy6ImI1CKAHsQFgQFQUCAAB4JMCQPIMOYLawwSD4Xp8oRCgSQcjgaCKsDQF4Qej1ThAA

It works fine in the simulator but not sure if there are any gotchas IRL.
Moreover though, aren't shunt resistors usually <0.1Ω ? I replaced 0.6Ω with 1Ω and the current is closer to 1A now, but I'll need a brick resistor to dissipate 1W there. Tried the circuit w/o that resistor as well and the current went to 1.6A which is still adjustable by modifying the pull-down R as you mentioned.



Btw, I was playing around with the idea and I figured out another way as well using an n-MOSFET. Here's the link:

https://www.falstad.com/circuit/circuitjs.html?ctz=CQAgjCAMB0l3BWEBmAHAJmgdgGzoRmACzICcpkORICk4dtNApgLRhgBQA5iuncpGrI+KZDihQOAJRD5x6VKlmQlCpXTpE6YaOI1RoCDgHdeddFnRnZ6apGmyt4XI+0KJmhh4NGAZrIR5RWs1CR0kPnsAY2swF2FzWw9oCCJocnJAsAswOFQsLAM4TgAnV2dxBIrkzgB7Gnokz3IGnT1ZBuQONHAQADEIfRE2EAA1WoAbABcAQy4mDiA

The 0.1Ω is just for modeling the parasitic resistance of the cap and not important. The 1.6v can be achieved with a potentiometer but is subject to β of the transistor IRL. So the only question is whether a 1A n-MOSFET or 1A PNP is more common / cheaper.



P.S. Sorry for the long links, but relying on Tinyurl means relying on a separate server which may not be there tomorrow, whereas Falstad is FOSS. I only wish this site allowed [alias](full-link) style of inserting links, aka Markdown.
 

Online BrianHG

  • Super Contributor
  • ***
  • Posts: 8046
  • Country: ca
Re: Supercapacitors and ESR
« Reply #13 on: September 23, 2024, 05:29:03 am »
Try a normal linear regulator with a built in 1A current limiter.
 

Offline just4user

  • Newbie
  • Posts: 7
  • Country: 00
Re: Supercapacitors and ESR
« Reply #14 on: September 23, 2024, 05:34:50 am »
Quote
Try a normal linear regulator with a built in 1A current limiter.

Isn't that limit what you shouldn't exceed though? Do you know the part number?
 

Online BrianHG

  • Super Contributor
  • ***
  • Posts: 8046
  • Country: ca
Re: Supercapacitors and ESR
« Reply #15 on: September 23, 2024, 05:54:03 am »
Check out the datasheet for TI's LM317.
The have a page in the datasheet which illustrates an example 6v current regulated battery charger.
You would just need to adjust the resistor values for the voltage you want for your supercap.

See pages 24 and 27.
https://www.ti.com/lit/ds/symlink/lm317-n.pdf
 

Offline just4user

  • Newbie
  • Posts: 7
  • Country: 00
Re: Supercapacitors and ESR
« Reply #16 on: September 23, 2024, 06:03:42 am »
Quote
Check out the datasheet for TI's LM317.
Thanks Brian.
I forgot to mention the dropout voltage.
My use-case is in line with the earlier posts in the thread i.e. a UPS sort of manner, so minimizing the dropout would be ideal.
Figure 4 on page 9 shows 2v dropout at 1A and 25ºC which is quite far from ideal.
Thanks again 🙏
 

Offline jwet

  • Frequent Contributor
  • **
  • Posts: 517
  • Country: us
Re: Supercapacitors and ESR
« Reply #17 on: September 23, 2024, 02:42:06 pm »
just4...

The .6 ohms is a magic number, Vbe is .6/.7 or .6 ohm x 1 amp.  When you sense with the upstream 1k, you turn off the PNP.

The pulldown trick won't work as well in real life.  Falstad is a pretty simple simulator and assumes beta is constant- its highly variable and inconsistent and even depends a bit on temp. 

Get out of simulation mode and go burn your fingers.  Its a classic circuit but you'll learn a lot playing with it.  Transistors are very odd beasts.  You'll learn if you dig in deep enough that beta is a lousy parameter- bipolars are transconductive devices- they're Ic is controlled by Vbe in a logarithmic way.  Look up Ebers-Moll equation and get ready to forget what you think you knew about transistors.

Edited this- backwards thinking
This general application is called "inrush" current  limiting and its pretty common- hundreds of ways to solve it.  Another simple way is to use a Negative Tempco Power Thermistor- "NTC".  These have a medium resistance nominally but their R decreases rapidly when they heat up- like when the cap tries to charge like a short- you can get stuff sized to do something similar- they cool off and return to normal after a bit.  When first plugged in, the cap will try to draw like a short but the ohm or so of the NTC won't let it.  It will decreased in value, charge the cap and then go back to their medium value- usually around an ohm.  They're often used in switching power supply so the lights don't dim when you plug them in, etc.

The LM-317 and MOSFET's both have the problem of large drop out and equivalent of high Vbe (1.2V for 317 and ~4v for big fet).

Many ways to skin this cat...
« Last Edit: September 23, 2024, 03:14:26 pm by jwet »
 
The following users thanked this post: just4user

Offline just4user

  • Newbie
  • Posts: 7
  • Country: 00
Re: Supercapacitors and ESR
« Reply #18 on: September 23, 2024, 03:08:28 pm »
Thank you John.

I do not yet understand the magic of the shunt resistor or why the pulldown trick won't work as well in real life.

But I think you meant NTC thermistor, rather than PTC, as it needs to decrease in resistance as the capacitor gets more charged.
I don't like their temperature dependence and their reset time, so I'll try transistor solutions first.

Thanks for pointing out dropout voltages of FETs. I'll keep that in mind.
 

Offline jwet

  • Frequent Contributor
  • **
  • Posts: 517
  • Country: us
Re: Supercapacitors and ESR
« Reply #19 on: September 23, 2024, 03:13:22 pm »
NTC, you're correct, I was editting as you were writing.

Play with parts on the bench.  Set the current limit at 50 mA or something easy and you won't have to use big parts.

You can't parallel bipolars so easily- you generally have to "ballast" them to make up for small differences.

Take Care
 
The following users thanked this post: just4user

Online T3sl4co1l

  • Super Contributor
  • ***
  • Posts: 22307
  • Country: us
  • Expert, Analog Electronics, PCB Layout, EMC
    • Seven Transistor Labs
Re: Supercapacitors and ESR
« Reply #20 on: September 23, 2024, 03:16:19 pm »
Not uncommon to use a parallel resistor and diode: the resistor limits charging current, very dumb and simple solution; when power is lost, the diode directs capacitor charge into the rail, keeping it up (minus a modest drop, say 0.4V using a large schottky).

Most applications, the RC time constant is much less than the expected / average up-time, and the capacitor gets fully charged before it's needed, and a smarter solution isn't needed.

When it [smarter] is needed, a transistor as above, or even a buck converter (more efficient; note, a current-limited type is required, not the foldback or hiccup-mode types that are common) can be used to charge the capacitor; and an ideal diode (discrete circuit, or wired-OR controller) can be used in place of the passive diode.

Related, there are also "energy harvesting" ICs, for diverse sources (PV, thermoelectric, piezo, etc.), storing into a supercap or battery, from which higher peak currents and low average (over sufficient time scales) can be drawn.


Try a normal linear regulator with a built in 1A current limiter.

Not great, as the dropout voltage is huge: at least the VREF, or 1.25V for LM317 for example, but dropout is normally 1.5-2V for that type, useless for a 3.3V supply, barely leaving enough voltage for a CMOS (backup) RAM.

LDOs are better, but have another problem: their internal current limiting is very loose, generally speaking.  And you won't have a floating VREF to use like the LM317.  Instead, you have to shop around to find one with continuous current limiting over a modest band -- perhaps 200-400mA would be an acceptable spread?

Tim
« Last Edit: September 23, 2024, 03:19:42 pm by T3sl4co1l »
Seven Transistor Labs, LLC
Electronic design, from concept to prototype.
Bringing a project to life?  Send me a message!
 

Offline just4user

  • Newbie
  • Posts: 7
  • Country: 00
Re: Supercapacitors and ESR
« Reply #21 on: September 23, 2024, 03:42:16 pm »
Thanks Tim. To add to the many ways of skinning this... :)
A (LDO?!) buck converter with a soft-starter mode. If you choose the ramp slope just right, it'll draw 1A.
 

Online T3sl4co1l

  • Super Contributor
  • ***
  • Posts: 22307
  • Country: us
  • Expert, Analog Electronics, PCB Layout, EMC
    • Seven Transistor Labs
Re: Supercapacitors and ESR
« Reply #22 on: September 23, 2024, 06:10:54 pm »
Nah not soft start -- that'll take too long, and have other drawbacks (e.g. a 100uF+ SS cap being discharged through ESD diodes when powered off, maybe who knows?).  You'd have to somehow match the SS and supercap (initial) voltages and values, or take much longer for it to reach that point, it's weird?

Just current limit, so it delivers constant current into the load, and the load does whatever it does (i.e., I/C = dV/dt).

The downside is if it ever ends up shorted, it's just sitting there cooking forever, drawing supply current and dissipating some power (not necessarily problematic, just that it's more than zero).  Maybe a foldback or hiccup limit, just with a lower threshold voltage, or a much longer timeout before faulting occurs, would be most attractive here?  But again, keep in mind, this is already looking beyond a single failure event, and needless to say, the backup cap isn't backing up anything if it (or something connected to it) has failed shorted, and a lot of designs just aren't concerned with how they fail beyond a single event.

And yeah actually, it might need to be a low dropout buck.  This is usually specified as having a high maximum duty cycle, >95% say, or 100% specifically.  Then the output can be steady on, and the regulator acts like a low-drop switch between VIN and VCAP.  It could also be a regular type, supplied from a higher rail, with the Vout feedback set appropriately (say, 5V supply charging a two-cell cap up to 3.3V for 3.3V logic use).

The LDO comments specifically are in regards to a pure analog solution, using a Low Drop-Out (LDO) regulator instead of switching.  More power is dissipated, but only while charging, and then it can act as a low-drop switch from VIN to VCAP.

You wouldn't usually use "LDO" to describe a switching converter.  But in the same sense that that applies (the maximum duty cycle), yes.

Tim
Seven Transistor Labs, LLC
Electronic design, from concept to prototype.
Bringing a project to life?  Send me a message!
 
The following users thanked this post: just4user


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf