Building a battery 12V battery charger

crutschow

Joined Mar 14, 2008
34,469
The circuit in Figure 53 should work for you with the output set to about 13.8V as #12 suggested.
Rs is only needed if you want to limit the maximum current below the LM317 internal limit. As the battery voltage reaches 13.8V the current will reduce to whatever trickle-charge level is needed to maintain 13.8V.
The LM317 will handle the limit current as long as it's on a good heat-sink. If it does overheat it will automatically reduce the current limit value to prevent destruction of itself, but it's not good (from a reliability point of view) to operate for a long time period under such thermal limited conditions.

Note that you should add the recommended input and output capacitors to the LM317 to insure stability.
 

MikeML

Joined Oct 2, 2009
5,444
The TS needs a float charger to prevent self discharge during the winter months. Floating a lead-acid battery long-term requires only a few 10s of mA, so all this discussion about boosting current is not helpful.

The biggest requirement is very accurate setting of float voltage, corrected for ambient temperature. Battery University says:

The recommended float voltage of most low-pressure lead acid batteries is 2.25 to 2.27V/cell. (Large stationary batteries float at 2.25V at 25°C (77°F.) Manufacturers recommend lowering the float charge at ambient temperatures above 29°C (85°F).

Second most important requirement is not to blow anything up if you connect the charger to a flat battery, which was the topic of my original link.
 
Last edited:

Thread Starter

RayInMS

Joined Dec 12, 2012
89
The circuit in Figure 53 should work for you with the output set to about 13.8V as #12 suggested.
Rs is only needed if you want to limit the maximum current below the LM317 internal limit. As the battery voltage reaches 13.8V the current will reduce to whatever trickle-charge level is needed to maintain 13.8V.
The LM317 will handle the limit current as long as it's on a good heat-sink. If it does overheat it will automatically reduce the current limit value to prevent destruction of itself, but it's not good (from a reliability point of view) to operate for a long time period under such thermal limited conditions.

Note that you should add the recommended input and output capacitors to the LM317 to insure stability.
OK. The internal limiting of the LM 317 was my major concern.

So, three caps? One across +/- leads of the power supply, two in parallel across the +/- leads of the LM 317 output?
 

Thread Starter

RayInMS

Joined Dec 12, 2012
89
The TS needs a float charger to prevent self discharge during the winter months. Floating a lead-acid battery long-term requires only a few 10s of mA, so all this discussion about boosting current is not helpful.

The biggest requirement is very accurate setting of float voltage, corrected for ambient temperature. Battery University says:

The recommended float voltage of most low-pressure lead acid batteries is 2.25 to 2.27V/cell. (Large stationary batteries float at 2.25V at 25°C (77°F.) Manufacturers recommend lowering the float charge at ambient temperatures above 29°C (85°F).

Second most important requirement is not to blow anything up if you connect the charger to a flat battery, which was the topic of my original link.
I'm in MS, so winter temperature for us is generally not super cold. The battery will be stored in a garage until it gets warm enough to cut grass, so heat isn't necessarily an issue either.
 

#12

Joined Nov 30, 2010
18,224
Whatever the supply is, then a small capacitor right across the input to ground at the chip, then a small capacitor right across the output to ground at the chip, then you're done.

The important part is the two small capacitors connected right next to the regulator. They stop it from oscillating.
 

Thread Starter

RayInMS

Joined Dec 12, 2012
89
Whatever the supply is, then a small capacitor right across the input to ground at the chip, then a small capacitor right across the output to ground at the chip, then you're done.

The important part is the two small capacitors connected right next to the regulator. They stop it from oscillating.
Something like this, then?

Draft1.PNG

I opted to use a pot for R2 to make sure I could adjust the voltage correctly (to get it to 13.8 or thereabouts).

C1 can be film, correct? .01 uF?
C2 needs to be electrolytic, correct? 100 uF?
I can eliminate C3, correct?
 

#12

Joined Nov 30, 2010
18,224
No. It's the small caps that attenuate the high frequency oscillations. You can often leave out the 100 uf cap.
Read the datasheet for the size and brand of 317 you use. They are maddeningly different from one brand to the next.

Oh yeah, ceramics or film caps usually work, but READ THE DATASHEET!
 

Thread Starter

RayInMS

Joined Dec 12, 2012
89
This lacks the current limiting I posted the link to way back in post #7, and will kill the battery in short order if the AC input goes away. Looks like you are reinventing the wheel.
Mike, could you elaborate on this a bit? I thought the LM 317 had an internal current limiting feature (1.5 A). Do you mean that disconnecting the charger would kill the battery?

Sorry, I'm still learning.
 

Dodgydave

Joined Jun 22, 2012
11,307
R1 240 ohms, R2 is 2.4K , will give 13.8V ,like the datasheet diagram, the batteries will limit their own current as they charge up they take less current.
 

Thread Starter

RayInMS

Joined Dec 12, 2012
89
No. It's the small caps that attenuate the high frequency oscillations. You can often leave out the 100 uf cap.
Read the datasheet for the size and brand of 317 you use. They are maddeningly different from one brand to the next.

Oh yeah, ceramics or film caps usually work, but READ THE DATASHEET!
Roger that. So, smaller values (e.g., 0.01 uF) for filtering (or is it smoothing...argh)?
 

Dodgydave

Joined Jun 22, 2012
11,307
a pot is fine ,but fixed resistors are better for stability, 2.4K is a 2.2K and two 100 ohms in series,

or a 3.3K and a 10K in parallel is approx 2.48K.
 
Last edited:

MikeML

Joined Oct 2, 2009
5,444
Mike, could you elaborate on this a bit? I thought the LM 317 had an internal current limiting feature (1.5 A). Do you mean that disconnecting the charger would kill the battery?
No, connecting the charger can kill the wall-wart. Go and reread the linked article. 1.5A (intrinsic to the LM317) will overheat most wall-warts. The electronic current-limiting is primarily there to protect whatever is supplying the DC input to the LM317 as the charger is first connected to a mostly discharged battery.The current limiter does nothing after the battery recharges.

Don't listen to DodgyDave. Even your lawn-mover battery (~25AH), without purposeful current-limiting), will happily accept a charging current of 30+A if connected to a high-current power supply whose output voltage is greater than a discharged battery's terminal voltage.
A 12V starting battery will accept charging currents of 50A to 100A (it is not good for them, that is why you need a secondary current limit)

You didn't ask about the other point.
 

Dodgydave

Joined Jun 22, 2012
11,307
No, connecting the charger can kill the wall-wart. Go and reread the linked article. 1.5A (intrinsic to the LM317) will overheat most wall-warts. The electronic current-limiting is primarily there to protect whatever is supplying the DC input to the LM317 as the charger is first connected to a mostly discharged battery.The current limiter does nothing after the battery recharges.

Don't listen to DodgyDave. Even your lawn-mover battery (~25AH), without purposeful current-limiting), will happily accept a charging current of 30+A if connected to a high-current power supply whose output voltage is greater than a discharged battery's terminal voltage.
A 12V starting battery will accept charging currents of 50A to 100A (it is not good for them, that is why you need a secondary current limit)

You didn't ask about the other point.
the transformer will limit the maximum amount of current, if he uses a 5 amp one, and puts a trickle charge switch in the charger circuit.
 

Thread Starter

RayInMS

Joined Dec 12, 2012
89
No, connecting the charger can kill the wall-wart. Go and reread the linked article. 1.5A (intrinsic to the LM317) will overheat most wall-warts. The electronic current-limiting is primarily there to protect whatever is supplying the DC input to the LM317 as the charger is first connected to a mostly discharged battery.The current limiter does nothing after the battery recharges.

Don't listen to DodgyDave. Even your lawn-mover battery (~25AH), without purposeful current-limiting), will happily accept a charging current of 30+A if connected to a high-current power supply whose output voltage is greater than a discharged battery's terminal voltage.
A 12V starting battery will accept charging currents of 50A to 100A (it is not good for them, that is why you need a secondary current limit)

You didn't ask about the other point.
The power supply is a laptop brick (19.5V DC, not sure about the current rating...will have to look). If the current rating on the power supply exceeds 1.5 A, would I still need the secondary limiting protection? If so, what would you add to the schematic to accomplish this?
 

Dodgydave

Joined Jun 22, 2012
11,307
Laptop psus usually are 3 to 5 amps, they can be modified to give out 13.8V easy.

look at the datasheet,there are examples for current limiter using a npn transistor on the adjust pin.
 

MikeML

Joined Oct 2, 2009
5,444
I am not that enamored with relying on the LM317 internal current limiting. AFAIK, it is based on the LM317 self-heating and has a thermal-time constant. How long does it take the LM317 to recognize that the load current exceeds 1.5A?
 
Top