LiFePO4 pack monitoring - "fuel gauge" IC? - Page 1
Forum section: electronics / projects

author: Clear as mud
author_rank: Regular Contributor
timestamp: June 25, 2019, 03:23:33 am
content: I intend to develop a battery monitoring system for a friend's project. He will have 4 or 5 large lithium iron phosphate cells in series to power his stuff for three days or so, and he wants to be able to monitor the charge level, polling the battery monitor from a nearby USB port. Also the monitoring circuit should provide a signal when the battery gets empty (maybe full too). I'm looking for suggestions regarding initial design decisions such as what IC to use to monitor state of charge.I've read a little bit of background material, but haven't really started. My friend suggests that we probably want to go with a chip with LiFePO4 fuel gauge functionality built in, for increased accuracy and decreased development time. He suggested theBQ78350-R1from TI, but I am not sure. That chip is intended to work with a companion chip they are calling an "analog front end," to monitor the actual voltage level on each cell and provide balancing to the pack. But it's designed for small cells. The ones my friend intends to use are large ones, rated for a maximum charge and discharge current of 130 amps.So it seems I would have to build a custom circuit to take the place of the analog front end chip, and I'm thinking it might be better to start off with a different IC altogether. But the other thing I am thinking is that the balancing may only matter during charging, and perhaps if pack balancing is not needed during discharge, then my circuit doesn't even need to have that functionality. Apparently my friend already has a charger with cell balancing built in.

author: NiHaoMike
author_rank: Super Contributor
timestamp: June 25, 2019, 03:32:30 am
content: The same BMS chipset will work on both small and large cells. It's just a matter of selecting the correct shunt resistor and MOSFETs.

author: Siwastaja
author_rank: Super Contributor
timestamp: June 25, 2019, 06:10:32 am
content: If you want to have cell-level measurement and balancing, using an off-the-shelf chip may be easier because of the complexity of level-shifting or isolating things if you do your own.For coulomb counting, you can do it with your microcontroller direclty; these chips are often more complex to use (and total black boxes which still need configuration to work properly), than just doing it yourself.dt = prev_time - cur_time;charge = current * dt;if(voltage >= high_voltage_limit){charger_enabled = 0;charge = full_capacity;}if(voltage <= low_voltage_limit){load_enabled = 0;charge = 0;full_capacity -= charge/10; // adjust full_capacity a bit each time so it gets closer to the actual measured capacity}soc_percentage_out = charge/full_capacity*100;Do note that TI (or originally BQ) is notorious for totally saturating and dominating the market with unusable and dangerous piece-of-shit lithium-ion management ICs. Some are all right, some have caused a lot of grieve. Beginners like to design them in with blind trust. I have stopped using all TI li-ion ICs completely and if I won't find something else, I full-custom it, understanding the risks in doing custom design, but seeing that trusting a TI li-ion chip is a bigger risk, at least for me. Your mileage may vary.

author: Daixiwen
author_rank: Frequent Contributor
timestamp: June 25, 2019, 06:53:25 am
content: Cell balancing is only needed during charge. If your friend already has a charger with balancing included, and if the battery pack already has a protection circuit against over and under voltage at the cell level, then your circuit doesn't need to monitor individual cell voltages, it can be enough to monitor the current and the full pack voltage. In that case the TI chip is overkill. I too have bad experience with TI battery monitoring chips. They are a lot more complex to use than what you initially think when reading the datasheet, and full or gotchas and black undocumented magic.To monitor the current it's best to use an actual coulomb counter or a very high resolution ADC, especially for long discharges. Some microcontrollers specialized in battery monitoring, such as theATMega406have a high resolution ADC specialized for current and state of charge monitoring, but you will need to write your own software.If you are not afraid of using TI chips maybe theBQ34110would be an easier solution. They say it supports up to 32A but you can support more with some scaling. I have never used it but it seems a bit easier to use than most of the other fully integrated offerings they have. It uses a coulomb counter so I would expect it to be more accurate than the Mega406 over long periods.

author: Clear as mud
author_rank: Regular Contributor
timestamp: June 25, 2019, 10:47:13 pm
content: I've been reading the eevblog forum long enough that I've heard people complain about TI integrated circuits not always working as they are supposed to. And my first thought about the particular chip I mentioned was that it was overkill. So, I'm leaning towards the advice to use a simpler coulomb counter IC. Something with 8 pins, like the STC3100 from ST Microelectronics.But I also need to measure voltage on each cell, because my friend is not buying these as a pack, just individual cells, so we need to build our own solution for making sure the cells don't go undervoltage.So I'm thinking I'll use a coulomb counter IC, a microcontroller with A/D built in to monitor cell voltages, and a serial to USB converter chip to get the data out.

author: Daixiwen
author_rank: Frequent Contributor
timestamp: June 26, 2019, 08:15:19 am
content: If he is using bare cells you probably need a short circuit / overcurrent protection too. Those cells can deliver quite a punchCheck that his charger has cell level overvoltage protection too. If not you will need to have it in the pack.For undervoltage protection you don't need a very high accuracy, so a regular ADC from a microcontroller will be enough. Of course you won't get directly the individual cell voltages, as you measure the voltage between ground and each intermediary point, but you can then do the subtraction in software. There is one catch though: you will surely need to use voltage dividers from each point to the ADC in order to lower the voltage, but those voltage dividers will draw a small current from the cells, and if you are not careful the current from each sampling point will be different and in the long run it can cause an imbalance in the system. Some people use different total resistance in each voltage divider to compensate for that, and some ICs use mosfets to turn on the voltage dividers only when a measurement is made.On the other hand it seems to be a battery with a high capacity, so this may only be a problem if he plans to store the battery for months. And if the charger has a balancing circuit it can compensate for that on the next charge. Be sure to make a calculation and find out how much current your monitoring circuit will draw from each cell to see if this can be an issue in your application.

author: Clear as mud
author_rank: Regular Contributor
timestamp: June 27, 2019, 01:30:30 am
content: There will be a fuse in the system for short circuit and overcurrent protection. That should be OK because we do not plan to use these cells at anything near their maximum current rating. They'll generally only supply 3 amps, maybe 8 amps maximum, so a 10 or 15 amp fuse should work.It was actually a few months ago when my friend first gave me this project, and I just found out that he has changed his mind about what batteries to use. The current plan is to use 50 Ah LiPo cells, actually the ones that are in the battery pack of a 2nd-generation Chevrolet Volt. So, voltage levels change, and the batteries will only last 1 day instead of up to 3, but otherwise the system is similar.I didn't think about the current from each cell being different through the ADC voltage divider, but the voltage divider circuit will draw such a small current that it may not matter.The batteries will be used at events a few times per year. Do you think it would be OK to disconnect everything from the cells and store them for a few months between events? If so, what would be the best state of charge to leave them at during storage?

author: Daixiwen
author_rank: Frequent Contributor
timestamp: June 27, 2019, 06:46:27 am
content: Yes for 50Ah cells it shouldn't matter. It's more of a problem for small cells, where the current drawn in the voltage dividers stop being negligible over long storing periods.A fuse is fine as overcurrent protection but is mandatory. Even if your application only drive a few amps, if you have a short circuit somewhere the cells will happily deliver a hundred amps and unleash the magic smokeIt's perfectly fine to disconnect the circuit for storage. It is recommended to store the cells between 30 and 70 % state of charge. If storing for a long period it's better to have them closer to 70% than 30% to be sure they won't come out of storage too low. The cooler the better, as the self discharge rate increases with temperature. If stored for a long period at a very low temperature, let them time to warm up back to room temperature before attempting to charge them.

author: Miyuki
author_rank: Frequent Contributor
timestamp: June 27, 2019, 09:52:18 am
content: Quote from: Daixiwen on June 25, 2019, 06:53:25 amwow this one looks like a nice chip, little pricey (as most Atmel products) but with nice features