designing a usb battery charger for my rechargeable device

Thread Starter

miloshcavitch

Joined Jul 28, 2017
2
Hello all,
I've recently designed a circuit for a device I'm making that runs on this battery:
https://www.adafruit.com/product/1317

This is a 3.7-4.2 volt rechargable battery with 150mAh and is meant to be recharged at around 100mA.
It has a protection circuit, so if you over charge the device or try and drain it too much it will shut off.
Because of this, I'm thinking I can design a USB charger that is simple and just provides a constant current and I'm currently working with a LM317 voltage regulator.
Here is the circuit I'm currently troubleshooting:
batterychargerschematic.PNG
the vIN comes from the USB VBUS, the 2 negative feedback resistors cause a V output of around 3.7 volts.
When i test the current leading to the battery, I'm only getting 5mA.
I know that USB's can output 100mA and even more if required so after a couple days trying to figure this out I'm realizing I'm missing something important. Anyone have any ideas? Thanks
 

IMP002017

Joined Jan 28, 2017
192
maybe looking over the datasheet for the LM317 and at Diagram 8.3.6 Figure 17, might be able to get you the results your looking for?

I don't know much of the chip they do offer a diagram for a battery charger..
 

Thread Starter

miloshcavitch

Joined Jul 28, 2017
2
yea the included diagram is pretty much the circuit i included.
when i dont include the battery and just close the circuit (for a low amount of time) I'm reading that I get 1.4 amps. Is this even possible for the usb to output? Very confusing.
 

dendad

Joined Feb 20, 2016
4,476
Have a better look at the spec sheet. You have it hooked up "normally" as a constant voltage supply, not constant current.
It just so happened I was working on my shed roof today, and put my drill battery pack onto a constant current charge, at pretty high current. My thought was I'd be back soon to check it but my work took longer than expected. There was a THUMP! Straight away I suspected the cause and found this...

OverCharged.jpg
Last time I saw the battery pack, it was nice and neatly one assembled package.
The leads were blown off and the top some distance away from the base.
Be careful with your charger.
Now my shed stinks!
 
Last edited:

DickCappels

Joined Aug 21, 2008
10,174
Did you notice the safety warning on the web page to which you linked?

///start of quote///
it is very important that you only use a LiIon/LiPoly constant-voltage/constant-current charger to recharge them and at a rate of 150mA or less. We suggest our Micro Lipo charger, which has a 100mA default rate.
Like most lipos, the batteries we sell do not have thermistors built in. This is why we suggest charging at 1 C or even less - 100mA is a good rate, and available from any USB port if using a USB-powered charger

Additional safety notes: Do not use a NiMH/NiCad/lead-acid charger! Also, do not abuse these batteries, do not short, bend, crush or puncture. Never charge or use unattended. Always inspect batteries and surrounding circuitry constantly for any damage, loose wiring, or possibility of short circuits. As with all Lithium ion polymer batteries and with any power source - they should be used by experts who are comfortable working with power supplies
///end of quote///

Good words to heed.
 

Dodgydave

Joined Jun 22, 2012
11,302
Hello all,
I've recently designed a circuit for a device I'm making that runs on this battery:
https://www.adafruit.com/product/1317

This is a 3.7-4.2 volt rechargable battery with 150mAh and is meant to be recharged at around 100mA.
It has a protection circuit, so if you over charge the device or try and drain it too much it will shut off.
Because of this, I'm thinking I can design a USB charger that is simple and just provides a constant current and I'm currently working with a LM317 voltage regulator.
Here is the circuit I'm currently troubleshooting:
View attachment 131820
the vIN comes from the USB VBUS, the 2 negative feedback resistors cause a V output of around 3.7 volts.
When i test the current leading to the battery, I'm only getting 5mA.
I know that USB's can output 100mA and even more if required so after a couple days trying to figure this out I'm realizing I'm missing something important. Anyone have any ideas? Thanks
That is a Constant voltage circuit, it's no good you need a constant current circuit set to 100mA using one 12.5 ohms 1/2 W resistor.

Personally i don't understand why you're bothering to make one, when there are several ready made ones on the market...
 

Ficklepickle

Joined Nov 11, 2017
2
Unless you enjoy the process of designing it yourself, I'd buy them off eBay for around a dollar. I use them mostly to charge home made USB power banks. You can also use a USB ecig charger.

For about $2 you can get one that also has a regulated 5v usb-a port.

I have never blown up a cell, mind you I don't use those pouch cells but 18650's instead, and they have a much safer failure mode. In your case, even an 18350 would have way more capacity and is only a 18x35mm cylinder.

The only reason to use a lipo pouch over a li-ion cell is if you can't fit a cylindrical cell in your case, IMHO. Safety first, or at least in the top three ;-)
 
Last edited:
Top