cancel
Showing results for 
Search instead for 
Did you mean: 

STC3117 Missing battery detection

johndoeEngg
Associate II

If the IC is powered by the battery, how does missing battery detection work ? I am working on a product which will have a USB interface and a single cell Li-Ion battery with charging circuit and a gas gauge. I need to take care of scenarios where the unit is connected over USB to a PC/Laptop but the battery is not connected. How does the firmware (running on an STM32) know that the battery is missing ? 

8 REPLIES 8
AScha.3
Chief III

AScha3_0-1720804339848.png

So the stc checks, if battery away...

and firmware can check:

AScha3_1-1720804600961.png

batt removed ...

thats it.

...or i dot understand your question.

If you feel a post has answered your question, please click "Accept as Solution".

How is the IC powered if the battery is not connected ?

If the battery is the only supply...not at all, so no problem. :)

cpu is dead , until power coming..

If you feel a post has answered your question, please click "Accept as Solution".

If the IC is powered by the battery, the I2C transactions with the device will fail if the battery is not connected. Probably the SDA and SCL lines will be unable to be pulled up as well. The STM32 (or any microcontroller) can check for and detect this condition.

If you power the IC through USB, it'll work as normal and if the battery is missing it'll return 0 as the voltage.

If you feel a post has answered your question, please click "Accept as Solution".

We are using a different gas gauge IC (MAX17055) in our current design. The I2C lines are pulled up to 3.3V which is being sourced from USB supply. We see I2C reads sometimes succeed even when the battery is absent, returning 3.6V, 0 mA current and 50 % SOC . Could be because the charging IC (BQ24232) is applying a voltage to the VBAT line during it's battery detection procedure. Even MAX17055's datasheet mentions missing battery detection without any explanation. When we contacted MAXIM, they responded saying battery detection is not possible. Now I see STC3117 mention the same but no explanation !!.

How do we handle missing battery scenario ?

 

 

Battery is not the only supply. The board is also USB powered.

We can't power the IC only from USB since the product "also" needs to work standalone on battery power.

Can we use a power mux IC like the TPS2116 to supply both 3.3V (from USB) and voltage from battery with the latter getting priority ? 

 

TDK
Guru

> How is the IC powered if the battery is not connected ?

You tell us. Is it powered by USB as well, or only by the battery? Show the schematic if you can.

If you feel a post has answered your question, please click "Accept as Solution".