Charger termination circuit suggestion. - Page 1
Forum section: electronics / beginners

author: BeBuLamar
author_rank: Super Contributor
timestamp: November 30, 2023, 10:18:08 pm
content: I am builidngi a charger for my LiFePo4 battery. I use a constant voltage / constant current power supply to do it. The Voltage is set for 3.65V and the current limit is 1.2A. I want to build a circuit that can monitor the current and output a signal to shut off the charger when the current is 60mA or below. Any suggestion?

author: Benta
author_rank: Super Contributor
timestamp: November 30, 2023, 10:32:38 pm
content: Why not just monitor the voltage and turn off the charger at 3.65 V? Much simpler.

author: BeBuLamar
author_rank: Super Contributor
timestamp: November 30, 2023, 10:35:58 pm
content: I've been doing that but for long time charging I may not check back in time.

author: Benta
author_rank: Super Contributor
timestamp: November 30, 2023, 10:41:14 pm
content: I don't understand. If the output is at 3.65 V, the charger is off. Nothing happens.

author: BeBuLamar
author_rank: Super Contributor
timestamp: November 30, 2023, 11:34:05 pm
content: You connect the charger and you have to turn it on. The intial current will be 1.2A and the voltage is less than 3.65A. After a while the voltage will reach 3.65V and the current starts to drop. When the current drops to 60mA or below I would have to turn it off. The charging process can take about 8 hours and I may not be there to turn it off when the current gets down to 60mA.

author: IanB
author_rank: Super Contributor
timestamp: November 30, 2023, 11:37:13 pm
content: Right, so you include a circuit that monitors the current and turns off charging when the current drops below the desired threshold. This is what all properly designed lithium ion chargers do. You should also include a latch so charging cannot start up again until the circuit has been manually reset.

author: BeBuLamar
author_rank: Super Contributor
timestamp: November 30, 2023, 11:47:43 pm
content: Yes and my problem is that when I make a circuit that can monitor 1.2A, it's not accurate when it's down to less than 100mA. Also the shunt should be of small resistance value to pass 1.2A but when it goes down to 100mA and below it would yield too low voltage for reiably measure it.

author: Benta
author_rank: Super Contributor
timestamp: December 01, 2023, 12:05:52 am
content: Somehow, circular argumentation is in action here.If your cell is intact, you charge it until it reaches 3,65 V, then it's turnoff time.Again, with an intact cell, the current will drop by itself to zero when you get 3.65 V cell voltage.Same thing.If your cell is defective, you'll keep blasting it with 1.2 A no matter what, unless it's open circuited internally.I just don't see the issue. In both cases it's a cutoff at 3.65 V. We can discuss temperature compensation, but that's a side issue.

author: IanB
author_rank: Super Contributor
timestamp: December 01, 2023, 12:06:05 am
content: Well, let's suppose you want to achieve a 10 mV with a current of 50 mA. Then your current sense resistance would be 10 mV / 50 mA = 200 mΩ or 0.2 Ω.If you pass a current of 1.2 A through 0.2 Ω you will get a voltage drop of 0.24 V and a power dissipation of 0.29 W. That does not seem so bad to me. Where is the problem?

author: IanB
author_rank: Super Contributor
timestamp: December 01, 2023, 12:08:49 am
content: Quote from: Benta on December 01, 2023, 12:05:52 amThis is not how lithium ion chemistry works. In the CV phase of charging the voltage remains at 3.65 V but the current remains significant and takes infinitely long to drop to zero. Therefore real and properly designed chargers have a low current cut-off limit.If you stop charging when the voltage reaches 3.65 V, you can of course do that, but then you only get an 80% charge on the cell. If that's what you want, that is OK.

author: Benta
author_rank: Super Contributor
timestamp: December 01, 2023, 12:18:01 am
content: Quote from: IanB on December 01, 2023, 12:08:49 amUmm, no. A discharged LiFePO4 cell is at around 2...2.5 V. So the main charging cycle is CC, not CV. The cut off point is 3.65 V, where you can switch to a low current CV top-off mode.

author: BeBuLamar
author_rank: Super Contributor
timestamp: December 01, 2023, 12:53:34 am
content: Quote from: IanB on December 01, 2023, 12:06:05 amI think that would work. I have a tiny programable controller with 0-5V ADC input. I think if I built an single ended OP amp to amplify by 20 times then the 0.240V would be 4.8V and the 0.010V would be 0.2V and with its 12bit resolution it's decent resolution.

author: Peabody
author_rank: Super Contributor
timestamp: December 01, 2023, 01:11:52 am
content: A TP5000 module would do all the charging and termination automatically.

author: Buriedcode
author_rank: Super Contributor
timestamp: December 01, 2023, 04:16:31 am
content: Generally the charge termination current doesn't have to be super accurate - and frankly neither does the bulk charging current 5, hell even 10% wouldn't be something I would worry about. The accurate part needs to be the maximum cell voltage.So a variation of +/-10mA probably won't hurt, or pick a higher current current like 100mA and you'll lose out on very little capacity.I've built several "smart" chargers, including ones for Lithium Ion, and I made sure there was an analogue/hardware way to cap the cell voltage - don't let it just be set by software, because a software problem could cause this to be higher.Another nice safety feature was to control the charging power control with a charge pump - the micro has to twiddle a GPIO in software to keep this on. This means if the micro should stop working, crash, or the oscillator fails, it doesn't get stuck on "full charge current", it just stops charging altogether.

author: tooki
author_rank: Super Contributor
timestamp: December 01, 2023, 04:09:08 pm
content: Quote from: Benta on December 01, 2023, 12:18:01 amUmm... you're talking about different phases of the charging cycle.You're talking about the CC phase (which comes first), he's talking about the CV phase (which comes second). IanB expressly said "in the CV phase", so by definition he's not talking about the CC phase. Neither of you is wrong.Well sorta. You're kinda wrong in saying "where you can switch to a low current CV top-off mode". The current will gradually taper off. You don't set a low current, but rather remain at the cutoff voltage, and as the battery charges, the current tapers off until you reach whatever termination current you want. What certainly is not correct is your claim that the charge current reaches zero at the termination voltage; that is absolutely not how it works.

author: PlainName
author_rank: Super Contributor
timestamp: December 01, 2023, 04:16:13 pm
content: Not au fait with the battery chemistry, but surely it is easier to monitor current to detect <60mA than to monitor voltage to within 10mV of an absolute value.

author: tooki
author_rank: Super Contributor
timestamp: December 01, 2023, 04:33:14 pm
content: Quote from: PlainName on December 01, 2023, 04:16:13 pmNot that I think that either of those things is difficult to do, but the relative difficulty is irrelevant, insofar as both are mandatory. (In fact, I'd say it's easier to monitor the voltage, since there are inexpensive ICs that do this to within a few mV.)Lithium charging begins with a constant-current (CC) phase, during which you monitor the voltage until it reaches the predetermined termination voltage. Once there, you switch to the constant-voltage (CV) charging phase, during which you monitor the current, and terminate once it falls below the predetermined termination current.Of course, one can also just use a lithium charger IC which knows all of this and is optimized for the purpose...

author: tooki
author_rank: Super Contributor
timestamp: December 01, 2023, 04:38:02 pm
content: Quote from: BeBuLamar on November 30, 2023, 11:47:43 pmWhat are you using to measure it? What you're describing is well within the capabilities of, say, an INA219 or INA226.Of course, you could just use a proper lithium charger IC that can be programmed with all of your charging parameters.

author: IanB
author_rank: Super Contributor
timestamp: December 01, 2023, 06:28:44 pm
content: Quote from: PlainName on December 01, 2023, 04:16:13 pmThe general way to measure current is to pass it through a sense resistor and measure the resulting voltage drop. So you pass 50 mA through a resistance of 0.2 Ω and this produces a voltage drop of 10 mV, which you can measure.In general, there are no direct electronic ways of measuring small DC currents.

author: Siwastaja
author_rank: Super Contributor
timestamp: December 01, 2023, 06:42:01 pm
content: Don't make a big deal about the exact termination current. I suggest higher termination current than datasheet value anyway, such as C/5 instead of C/20; the last 15 minutes at tiny current adds very little charge to the battery, and you don't have to charge to 100%, let 99% suffice. User experience is better when they see the charging finished more quickly. And then you don't need such accurate measurement.In fact, even if you skip the CV phase completely and just stop when you reach 3.65V, you are already somewhere around 90-95% state-of-charge anyway. This of course depends on the battery condition, how large the charge current initially is, and temperature too. For a weak battery fast-charged in cold, you pretty much want to taper down the current to get beyond 70%. If charging is slow even initially, then don't bother CVing it till the end as it will be nearly full when starting to taper.And answer to your question is, use a microcontroller, a shunt resistor plus amplifier into the ADC.

author: Jwillis
author_rank: Super Contributor
timestamp: December 01, 2023, 07:10:28 pm
content: Why not just use a sense resistor, comparator, reference, and relay.But if this is just for battery protection why don't you use a BMS or PCM on your battery?

author: PlainName
author_rank: Super Contributor
timestamp: December 01, 2023, 07:20:26 pm
content: Quote from: IanB on December 01, 2023, 06:28:44 pmYes, I know that. I'm just saying that with detecting current you could be crude and use 1R0 and look for a drop below 150mV aka 150mA, then switch to a bigger resistor and consequent large voltage drop for the final leg when the current is small.