SparkFun Forums 

Where electronics enthusiasts find answers.

Have questions about a SparkFun product or board? This is the place to be.
By UNTEngineer
#153358
I know its been awhile since I last posted on this topic, but can anyone verify that this schematic looks correct?

C22 is a Supercap from Sparkfun, and BAT1 is just a socket for a 12mm CR1225 battery. Schematic is this way to have the option between one system or the other.

Dont take notice of the text at the bottom. That was a previous revision, and I forgot to change it.

Image
User avatar
By viskr
#153368
What you have will work, but it is belt and suspenders and duck tape.

The DS1302 can be used to recharge the battery, though a CR1225 is NOT rechargeable, use a ML1220, for an equivalent size. Though a better choice for the internal charging setup of the DS1302 woudl be the ML621. (both available at Digikey)

Why both battery and cap ?? I thought you were worried about space.

You can recharge small batteries through the DS1302, check Figure 5 on page 9 of the spec, so D8 and R13 are redundant, but connect Vcc2 to3.3V for internal charging.
By UNTEngineer
#153373
viskr wrote:What you have will work, but it is belt and suspenders and duck tape.

Why both battery and cap ?? I thought you were worried about space.

You can recharge small batteries through the DS1302, check Figure 5 on page 9 of the spec, so D8 and R13 are redundant
I found the space on the opposite side of the board, so space is a non issue at the moment.

As far as rechargeable battery, cost, packaging and reliability were issues that came up, so I gave myself the option to switch between two reliable power sources with sturdy footprints, during initial configuration of the board.

Why is D8 redundant? Shouldnt I have a protection diode so that the supercap doesnt discharge by mistake back into the 3v3 line?
By UNTEngineer
#153412
viskr wrote:check Figure 5 on page 9 of the spec -- the DS1302 has an internal resistor and diode.
I see what you mean now, but those diodes are meant to protect the RTC, and not the 3v3 power rail, which is what that extra diode was intended to do. I also understood the redundancy with having that resistor, so I removed it from the circuit.
By Sparko
#159643
I'm also looking at using two supercapacitors (10F, 2.7V) to be the power source for a low-voltage, low-current circuit, with the intent that whenever they lose charge you just recharge them via the USB port on your computer. On the first page of this thread there's a circuit diagram that calls for a resistor for charging the capacitor - how do you gauge the size of this resistor to use? Assuming I'm not applying a greater voltage than the capacitor's rated voltage, so is the resistor still required?

Thanks!
User avatar
By viskr
#159673
You will need it to limit the current draw from the USB port, if you draw more than 500 mA the PC will disable the port. You also have to limit the voltage to 2.7V, best way would be with a regulator.

You specifically need to limit the inrush current when the cap is a 0V
By MichaelN
#159803
viskr wrote:You will need it to limit the current draw from the USB port, if you draw more than 500 mA the PC will disable the port...
In theory they should, but most devices will let you draw MUCH more than 500mA before they cut you off. Hence the proliferation of those ridiculous USB drink warmers etc...
By UNTEngineer
#163133
MichaelN wrote: In theory they should, but most devices will let you draw MUCH more than 500mA before they cut you off. Hence the proliferation of those ridiculous USB drink warmers etc...
Two things: either you are going to have to get a separate power supply for the unit, or a usb hub that is separately powered. I wouldn't risk drawing more than 500mA from your motherboard, as that can potentially fry some parts.

Oh, and as a side note, I finally did get the boards made, but havent had the time to assemble and test them. Will let you know if this worked out. Thanks Viskr.
User avatar
By viskr
#163144
Just FYI

From my experience most PCs will limit current to 500 mA, some even limit it more, as according to the USB spec the device is suppose to consume less than 100 mA unless it requests more from the host.

Most USB hubs don't care what kind of power you try to suck out of them.

I use an older Dell for most of my hardware development, and have had a board try to take more than 500 mA (how much more I'm not sure, read on...). When this happens the PC shuts down that bank of USB connections and to re-enable it I have to reboot the PC.

On the hubs (I typically buy cheap ones), I've had a similar board try to draw more power, and in fact have blown away 2 hubs, one popped the USB hub controller IC, the other melted a trace which was repairable.

For reference the board that was being powered in question usually draws about 200 mA, but it had a large FPGA and second CPU. It turned out that the FPGA was enabling drive signals to the second CPU before turning on the power to the CPU. So that most likely that CPU was in latchup with power inputs low and low impedance drive to the IOs.
By UNTEngineer
#163223
Then that pretty much eliminates using a USB hub for powering a device for more than a few hundred mA. Id use an external supply or have a built in power supply independent of the USB line.