LM338 Constant Current for Battery Charging

Discussion in 'General Electronics Chat' started by tomDC, Aug 2, 2015.

  1. tomDC

    Thread Starter New Member

    Aug 2, 2015
    I'm following the constant current circuit in the datasheet but can't seem to get the current to stay constant for more than 5 seconds. I have a meter inline to monitor the current and it dips about 0.01A every 3-5sec. I have a heatsink on LM338 and resistor along with a fan. Temp on LM338 hovers around 30C and same for the resistor. I'm using a 0.24Ohm 100W resistor to try to get constant 5A out of it. Power supply is a Meanwell 25.8VDC 20A. Battery is 21.6V 4400mAh LiPo and has builtin cell balancer. I adjusted the PS voltage to ~27V to get 25.8V out of LM338.

    Here's how I have it hooked up:

    Power Supply V+ > LM338 VIN
    LM338 VOUT > 0.24Ohm 100W Resistor > Positive terminal of the battery
    LM338 ADJ > Positive terminal of the battery
    Power Supply Ground > Negative terminal of the battery

    The current should stay the same for at least 70% of the charge but it just keeps dropping as the voltage slightly increases. This results to the charging time being nearly 2 hours with the last hour or so doing pulling less than 0.30A when theoretically the charging cycle should be done in about an hour at the most. I tried stock power supply that came with the battery and the current stays at 3A for at least 40 minutes before dropping.

    What am I doing wrong here? I got these LM338T's from Mouser so I doubt that they're fake. Am I going at this the wrong way and should use something other than LM338?

    Any help is greatly appreciated.
  2. cornishlad


    Jul 31, 2013
    perhaps you need to set a couple more volts from the psu. there may not be enough overhead for the regulator after the battery volts have risen a little..
  3. ScottWang


    Aug 23, 2012
    Attach the circuit and breadboard or components on PCB.
  4. ronv

    AAC Fanatic!

    Nov 12, 2008
    You probably won't be happy with this arangement as there is no maximum voltage limit. But I guess you figured that out by trying to limit the voltage with your input voltage. But the circuit needs about 3 1/2 to 4 volts above the battery voltage to allow for the drop across the regulator and the big resistor. That's why the current drops as the battery begins to charge.
    A better circuit using the 338 might be the one lableled simple 12 volt regulator in this data sheet. But you will still need to be careful to shut it off when the batteies reach 4.2 volts each.
  5. AnalogKid

    AAC Fanatic!

    Aug 1, 2013
    I agree with ronv about why the charger is behaving the way it is, and I'm not a LiPo wiz, but...

    5 A seems like an awfully large charging current for a 4.4 A h battery. At that rate a dead battery would be fully changed in less than one hour - if the battery doesn't burst into flame. Plus, LiPo batteries are farv less forgiving when it comes to overcharging, float voltage, etc.

  6. SgtWookie


    Jul 17, 2007
    There will be nearly a 2.2V to the 3v drop from the IN to OUT terminal, and approximately another 1.25v to 1.3v from OUT to ADJ, so you need at least 3v+ 1.3v more than your highest charge voltage coming to the IN terminal. Also, you will need some method to stop the charging, or your batteries will be damaged. One of your big problems will be keeping your regulator cool, particularly when the batteries are depleted.