USB Battery charger review

Thread Starter

adam555

Joined Aug 17, 2013
858
Hi,

I needed a battery charger for 2 x AAA batteries that I recharge almost every day. I thought that since due to my work I always have the computer on, I charge them through the USB instead of using the mains charger. In any case, I designed this very simple circuit and it would be great if anyone could review it before I blow up anything...



The circuit is only meant to do 3 things:
- Charge both batteries to 3V... actually they will only charge to 1.2V each.
- Limit the current to the batteries at 50mA at all times; whether they are empty or fully charged (50mA is the current that their charger outputs to each pair of AAA batteries).
- and Light the 3V blue LED once the batteries are charged; which will hopefully take the 50mA current from the batteries once they are charged to 3V, and also let me know when to take them out.
I just tested it and it seems to be working: I placed an ammeter at the collector that marks 50mA at all times, and a voltmeter in parallel with the load that's slowly raising up with the batteries' voltage.

... and that's all. Any thoughts, input or help will be appreciated.
 

Attachments

wayneh

Joined Sep 9, 2010
17,498
Consider what happens to your LED when the transistor is ON. It sees 5V if the battery is not protecting it.

Is that transistor EVER off? No.
 

Ramussons

Joined May 3, 2013
1,409
Fabricate a Current Source of 50 mA.
Feed the 3 V LED.
Connect the battery across the LED.

It does what you want, protects everything.

Ramesh
 

ian field

Joined Oct 27, 2012
6,536
Hi,

I needed a battery charger for 2 x AAA batteries that I recharge almost every day. I thought that since due to my work I always have the computer on, I charge them through the USB instead of using the mains charger. In any case, I designed this very simple circuit and it would be great if anyone could review it before I blow up anything...

.
These days even the cheapo chargers from discount stores have Delta-V end of charge sensing and safe float charge mode. I've long since quit bothering to make my own.
 

Thread Starter

adam555

Joined Aug 17, 2013
858
Consider what happens to your LED when the transistor is ON. It sees 5V if the battery is not protecting it.

Is that transistor EVER off? No.
Well, yes, there are 5v when I replace the batteries; but it's limited to 50mA, and since that's a BLUE 3v LED, it doesn't seem to be damaging it.

The transistor is always on; it's either feeding the batteries or the LED, or both. Would that be a problem?

Of course, the device is meant to be disconnected once the batteries are charged.

Fabricate a Current Source of 50 mA.
Feed the 3 V LED.
Connect the battery across the LED.

It does what you want, protects everything.

Ramesh
That's what the circuit above does; isn't it?

These days even the cheapo chargers from discount stores have Delta-V end of charge sensing and safe float charge mode. I've long since quit bothering to make my own.
My mistake, I shouldn't have said that I need a charger; I already have chargers; just wanted to make a USB one -taking advantage of the computer being on all day- instead of using the ones connected to the mains.
 
Last edited:

wayneh

Joined Sep 9, 2010
17,498
The transistor is always on; it's either feeding the batteries or the LED, or both. Would that be a problem?
Only if adding components that don't do anything is a problem. It's contributing some resistance to limit current, so I'd replace it with a resistor if that's all you want it for. No need to bias the base.
 

Thread Starter

adam555

Joined Aug 17, 2013
858
Only if adding components that don't do anything is a problem. It's contributing some resistance to limit current, so I'd replace it with a resistor if that's all you want it for. No need to bias the base.
I literally did what Ramussons proposed when designing the circuit: looked for a fixed current source and modified it to my needs.

If I replace the transistor with a resistor, then I won't have the 50mA constant current source. I guess it won't matter much for the batteries; since I assume they would get more current -limited by the resistor- when they are discharged, and less when they are charged. I really don't know if this would be better than a constant current source; just did it this way because the mains charger says 50mA and thought this would be best to preserve the life-span of the batteries.
 

wayneh

Joined Sep 9, 2010
17,498
If I replace the transistor with a resistor, then I won't have the 50mA constant current source.
I suppose you're right. This circuit relies on the current gain of the transistor (about 400 in this circuit) as the throttle on the current, and I'm not familiar at looking at such circuits that way. But I see now how it works; constant current as long as the gain is constant. The transistor is never fully on or off.
 

ian field

Joined Oct 27, 2012
6,536
That is not a constant current source.

Bob
It would be if the poster hadn't forgotten the emitter resistor - it would be even better one with the 23k resistor replaced by some kind of voltage reference, allegedly a green LED is quite well suited to this purpose.
 

wayneh

Joined Sep 9, 2010
17,498
I agree it could be improved, but it is a constant current source with adequate precision for the job, let's say ±10%. Voltage across that 33K resistor is more-or-less constant at 4.3V, so the base current is more-or-less constant and, as I noted, the transistor gain then controls the actual current. The resistor's value may wiggle and the transistor too, but overall these fluctuations are small enough to be tolerable in this application.
 

ian field

Joined Oct 27, 2012
6,536
I agree it could be improved, but it is a constant current source with adequate precision for the job, let's say ±10%. Voltage across that 33K resistor is more-or-less constant at 4.3V, so the base current is more-or-less constant and, as I noted, the transistor gain then controls the actual current. The resistor's value may wiggle and the transistor too, but overall these fluctuations are small enough to be tolerable in this application.
A circuit as posted will LIMIT the current, but it won't be CONSTANT current by any stretch of the imagination!
 

wayneh

Joined Sep 9, 2010
17,498
I just tested it and it seems to be working: I placed an ammeter at the collector that marks 50mA at all times, and a voltmeter in parallel with the load that's slowly raising up with the batteries' voltage.
Are you (Ian) arguing that the OP's observations are flawed?
 

Thread Starter

adam555

Joined Aug 17, 2013
858
What kind of cells are you trying to charge
It's meant to charge 2 x AAA NiMH rechargeable batteries in series.

I suppose you're right. This circuit relies on the current gain of the transistor (about 400 in this circuit) as the throttle on the current, and I'm not familiar at looking at such circuits that way. But I see now how it works; constant current as long as the gain is constant. The transistor is never fully on or off.
It's always 50mA whether the batteries are connected, disconnected, charged or discharged; and it's either used to charge the batteries or light the LED when the batteries are charged or disconnected. I can't figure out how I could achieve that with a resistor instead of the transistor.

That is not a constant current source.

Bob
It would be if the poster hadn't forgotten the emitter resistor - it would be even better one with the 23k resistor replaced by some kind of voltage reference, allegedly a green LED is quite well suited to this purpose.
You're right. The original circuit from where I took the idea for the design had a emitter resistor. What happened is that when I was modifying the resistor values to change it to 50mA I noticed that I could take out the emitter resister and continue to achieve the exact same result. So I ended up taking it out of the design and it continues to maintain a fixed current of 50mA whatever the load.

I agree it could be improved, but it is a constant current source with adequate precision for the job, let's say ±10%. Voltage across that 33K resistor is more-or-less constant at 4.3V, so the base current is more-or-less constant and, as I noted, the transistor gain then controls the actual current. The resistor's value may wiggle and the transistor too, but overall these fluctuations are small enough to be tolerable in this application.
I've modified it a bit -changed the NPN transistor for a PNP- and been testing it now for 2 days... it works as a clock; the ammeter that I have attached to it always marks the exact same current: 52mA -which is fine, since the mains charger states 50-55mA.

I need to review the calculations for biasing transistors, since I got that result by trial and error in a simulator, and then made the real thing with the best values obtained. I'm a bit confused on whether I should use just a base resistor or a voltage divider -and which are the best value combinations for the 2 resistors-, and also about that emitter resistor that I took off.
 
Last edited:

Thread Starter

adam555

Joined Aug 17, 2013
858
This is the PNP version; the one I'm using now. In the simulation the β is 143, but according to my multimeter the transistor I'm using (an A1015-GR) has 225 hFE -which is within what the datasheet states-.

 

Attachments

Thread Starter

adam555

Joined Aug 17, 2013
858
I've been reviewing what are the advantages of using a voltage divider instead of just one base resistor, and using the additional emitter resistor that I took of from the original design. For what I found they are just meant to increase the thermal stability. So, since that wouldn't influence much the final result, and since (I think) neither the LED or the batteries will be damaged, I ended up with just one 15K base resistor.

It seems to continue regulating the current to 50mA at all times in the simulations, but the real think lowers the current by a couple of mA when I take the batteries off; which doesn't matter that much.

My only concern now is shortening the life-span of the batteries by continuously changing them with this device; so, if you can think of a reason why this will happen, please let me know.
 

wayneh

Joined Sep 9, 2010
17,498
The LED sort of helps with that, taking an increasing amount of the total current as the cells charge. You may want to see what the actual battery charge current is at "full charge". Then compare that to the battery capacity and chemistry. It might be OK. If you need a better charger, you'll need a bit more circuitry to avoid overcharge.

You might consider a cheap DC-DC converter off e-bay. It'll only give you a constant voltage, but that is likely superior to the constant current strategy.
 

Thread Starter

adam555

Joined Aug 17, 2013
858
The LED sort of helps with that, taking an increasing amount of the total current as the cells charge. You may want to see what the actual battery charge current is at "full charge". Then compare that to the battery capacity and chemistry. It might be OK. If you need a better charger, you'll need a bit more circuitry to avoid overcharge.
I really don't know how to check if a battery is fully charged. I assumed that both batteries would be charged when they reach their full voltage potential. This is why I chose the 3V LED, because if everything works as it should, the LED will start conducting and light up at that point, taking the current off the batteries as needed to avoid overcharging them.

There is only one problem... these NiMH batteries are supposed to be 1.2V (2.4V between them), while they will be charged to 1.5V (3V both).

You might consider a cheap DC-DC converter off e-bay. It'll only give you a constant voltage, but that is likely superior to the constant current strategy.
I didn't consider that method because I noticed that in all chargers it is the voltage that varies with the battery's charge, while the current is constant.
 
Top