How do I figure out how big a cap I need?

General project help for Adafruit customers

Moderators: adafruit_support_bill, adafruit

How do I figure out how big a cap I need?

Postby jarcher » Mon Jan 23, 2012 11:45 pm

Hi All...

I am trying to build a board with a super capacitor that will keep it up for several seconds after the power goes away. This is because the device is logging data to an SD card and I need to detect that power went away, and then close the files on the SD card gracefully. I am thinking a super cap will hold my board up for a second or so, giving me time to close the files.

But, after lots of googling, I have not learned much. My device accepts 12V to 14.7V in and uses a 5V regulator to make 5V. Some of the board uses 5V and there is also a 3.3V regulator for the SD card, which needs 3.3V. So there is 12V in to a 5V regulator which then feeds a 3.3V regulator.

I did see that I should use a 5.5V cap down stream of the 5V regulator and upstream of the 3.3V regulator, because super caps don't come in much higher voltages. If I needed to put the cap on the 12V line then I would have to string caps together which reduces their capacity.

But I don't know how to figure out the value of the cap that is needed based upon current draw and how much time I want to stay up.

Any help?

Thanks...
jarcher
 
Posts: 40
Joined: Sun Mar 27, 2011 1:49 am

Re: How do I figure out how big a cap I need?

Postby adafruit_support_bill » Tue Jan 24, 2012 5:55 am

To start with, you need to know how much current your board draws. If there is no spec sheet for it, you will have to measure it with a multimeter.
User avatar
adafruit_support_bill
 
Posts: 15982
Joined: Sat Feb 07, 2009 9:11 am

Re: How do I figure out how big a cap I need?

Postby jarcher » Tue Jan 24, 2012 7:33 am

adafruit_support wrote:To start with, you need to know how much current your board draws. If there is no spec sheet for it, you will have to measure it with a multimeter.


Oh, I know that. Measuring at the 12VDC input, it will draw between 170mA and 230mA, depending upon which LEDs are lit.
jarcher
 
Posts: 40
Joined: Sun Mar 27, 2011 1:49 am


Re: How do I figure out how big a cap I need?

Postby jarcher » Tue Jan 24, 2012 8:18 am

Hm, that seems very specific to Maxim RTC chips... I'm not sure how to translate those parameters to my application. I put the current and such in, and it said 0 hours. I suspected it was a rounding issue, so I lowered the current consumption from 240,000,000 banned to 30,000 banned and got some numbers. I read the app note, and it talked quite a bit about keeping a RTC chip up.
jarcher
 
Posts: 40
Joined: Sun Mar 27, 2011 1:49 am

Re: How do I figure out how big a cap I need?

Postby adafruit_support_bill » Tue Jan 24, 2012 8:27 am

Yea, that one is for long-term backup of low-current devices.
This one might be more applicable. But it does require a spreadsheet:
User avatar
adafruit_support_bill
 
Posts: 15982
Joined: Sat Feb 07, 2009 9:11 am

Re: How do I figure out how big a cap I need?

Postby uoip » Tue Jan 24, 2012 10:48 am

Dimensional analysis is your friend. A Farad is a coulomb per volt. An Ampere is a coulomb per second.

To figure how much capacitance is needed, you've got to know how much charge (coulombs) must be delivered, and how much the voltage is allowed to sag while delivering the charge.

To figure the charge, multiply amperage times seconds to get coulombs. If it needs 200mA for 2 seconds, that would be 200mA*2s * 1A/1000mA = 0.4 coulombs

Suppose the capacitor starts at 12V, and is allowed to sag down to 7V before your regulator drops out (you'll need to verify the allowable lower limit on your voltage; you haven't given that). That would mean the voltage can sag 5V while the capacitor delivers 0.4 coulombs. The required capacitance is 0.4coulombs/5V = 0.08F

To guarantee things work right, you'll want to analyze the worst case. Look at the longest time required for saving data, highest current draw during that time, lowest voltage that triggers your "save everything, we're going down" routine, and highest input voltage on your regulator that could cause problems due to dropout issues. Add a safety factor, and look at the tolerances on your capacitors.
uoip
 
Posts: 127
Joined: Wed Sep 23, 2009 4:48 pm

Re: How do I figure out how big a cap I need?

Postby JamesC4S » Tue Jan 24, 2012 12:34 pm

I generally use this to estimate the cap size:

http://www.ehow.com/how_7432556_calcula ... tance.html

The key is the voltage drop as the cap discharges. If you can put a buck/boost converter in the path, you won't need as big of a cap since you aren't trying to hold a 5V rail at 5V.
User avatar
JamesC4S
 
Posts: 114
Joined: Sun Sep 26, 2010 10:49 pm
Location: Austin, TX


Return to General Project help

Who is online

Users browsing this forum: Google [Bot] and 5 guests

Stuff to buy from the Adafruit store and links to product documentation!


New Products [100]

Raspberry Pi[80]
 
FLORA[23]
 
Bunnie Studios[9]
 
FPGA[1]
 
mbed[11]
Arduino[60]
 
NETduino[14]
 
BeagleBone[24]
 
Android[6]
 
XBee[10]
More Dev Boards[30]


 
BoArduino[8]
 
SpokePOV[4]
 
TV-B-Gone[4]
 
MiniPOV[3]
 
SIM reader[3]
 
Microtouch[5]
 
Clocks & Watches[18]
 
Drawdio[4]
 
Brain Machine[1]
 
Game of Life[2]
 
MintyBoost[2]
More DIY Kits[16]


 
MaKey MaKey[3]
 
Tweet-a-Watt[5]
 
Young Engineers[33]
 
Discover Electronics[2]
 
Snap Circuits[4]
 
littleBits[3]
 
Project packs[8]


 
Breakout Boards[33]
LCDs & Displays[48]
Components & Parts[69]
Batteries & Power[49]
EL Wire/Tape/Panel[52]
LEDs[108]
 
Wireless[14]
Cables[60]
 
Lasers[6]
Sensors/Parts[145]
 
Enclosures/Cases[11]
 
Solar[11]
 
RFID / NFC[13]
Prototyping[69]
 
iDevices[13]
Tools[71]
 
Wearables[39]
 
CNC[37]
 
Robotics[29]
 
3D printing[1]
 
Materials[24]


 
Stickers[41]
 
Skill badges[55]
 
Books[25]
 
Circuit Playground[7]
 
Gift Certificates[4]