This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

BQ27220: Inquiry for Fuel Guage

Part Number: BQ27220
Other Parts Discussed in Thread: BQSTUDIO, EV2400

Hi, TI support team

My customer is developing for using BQ27220.

Then currently there are some problems.

1. Differences in detecting level of gauge IC depending on power source

There is a significant difference in the remaining capacity of the battery indicated by the gauge IC when the device is turned on with battery power and when turned on with USB power.

- This is the logarithm of the voltage (0x08, 0x09), remaining capacity (0x10, 0x11), and current current (0x0C, 0x0D) values indicated by the gauge IC when the device is turned on with battery power.

bq27220_update_status: 3548 mV, 86 mAh, 26 %, Current 11 mA

bq27220_update_status: 3548 mV, 86 mAh, 26 %, Current 11 mA

bq27220_update_status: 3547 mV, 86 mAh, 26 %, Current 11 mA

bq27220_update_status: 3547 mV, 86 mAh, 26 %, Current 11 mA

bq27220_update_status: 3546 mV, 86 mAh, 26 %, Current 11 mA

bq27220_update_status: 3546 mV, 86 mAh, 26 %, Current 11 mA

- This is the log when the device is turned off, turned on with USB power, and the above items are read.

bq27220_update_status: 3737 mV, 205 mAh, 62 %, Current 332 mA

bq27220_update_status: 3738 mV, 205 mAh, 62 %, Current 332 mA

bq27220_update_status: 3739 mV, 205 mAh, 62 %, Current 332 mA

bq27220_update_status: 3740 mV, 205 mAh, 62 %, Current 332 mA

bq27220_update_status: 3741 mV, 206 mAh, 62 %, Current 332 mA

bq27220_update_status: 3742 mV, 206 mAh, 62 %, Current 332 mA

- This is the log when you turn off the device again and turn it on with battery power.

bq27220_update_status: 3563 mV, 92 mAh, 28 %, Current 11 mA

bq27220_update_status: 3563 mV, 92 mAh, 28 %, Current 11 mA

bq27220_update_status: 3562 mV, 92 mAh, 28 %, Current 11 mA

bq27220_update_status: 3562 mV, 92 mAh, 28 %, Current 11 mA

bq27220_update_status: 3561 mV, 92 mAh, 28 %, Current 11 mA

bq27220_update_status: 3560 mV, 92 mAh, 28 %, Current 11 mA

2. Gauge reset

When you turn the device off and on, the register items listed below that were set and written in the data memory of the gauge IC are initialized. Hardware-wise, the gauge is directly connected to the battery.

0x929D  Full Charge Capacit    336 mAh

0x929D  Design Capacity    336 mAh

0x92A3  Design Voltage    3701 mV

Please refer to below circuit.

Thanks.

Regards,

MJ

  • Hello MJ, 

    Can you please provide me with your log files and the gg file for this? 

    Regards, 

    Jonny. 

  • Hello Jonny,

    Thank you for inviting me to this topic.

    I am currently developing firmware for devices equipped with bq27220 gauge IC, and I have attached the log generated by the device.

    Currently, there are two ways to turn on the device: turning it on with battery power and turning it on by connecting USB power. What is strange is that the resistor values for the battery remaining capacity (0x10, 0x11) and state of charge (0x2C, 0x2D) are very different. To minimize factors that could affect the Gauge IC, no configuration settings were made and only periodic read values were output to the log in the default state.

    The testing procedure is as follows:

    1. Disconnect the battery to set the gauge IC to default.
    2. Connect the battery.
    3. Turn on the device on battery power.
    4. Wait a moment, and output the gauge values.
    5. Turn off the device.
    6. This time, connect the USB power cable to turn on the device.
    7. Wait a moment, and output the gauge values.
    8. Turn off the device.
    9. Now turn on the device using battery power.
    10. Wait a moment, and output the gauge values.

    #----------------------------------------------------------------
    #  1. turn on the device using battery power
    #----------------------------------------------------------------
    00>
    00> HFCLK HFXO start success.
    00>
    00> [00:00:13.129,821] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:14.131,011] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:15.129,913] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:16.130,950] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:17.129,974] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:18.131,011] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:19.130,065] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:20.130,035] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:21.131,072] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:22.132,080] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:23.130,218] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:24.129,241] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:25.130,310] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:26.129,394] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:27.130,432] <dbg> bq27220_update_status: 3594 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:28.129,394] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:29.129,333] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:30.130,371] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:31.131,469] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:32.129,486] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:33.130,523] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:34.129,638] <dbg> bq27220_update_status: 3594 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:35.130,615] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:36.129,669] <dbg> bq27220_update_status: 3594 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:37.130,859] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:38.129,852] <dbg> bq27220_update_status: 3594 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:39.129,852] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:40.130,767] <dbg> bq27220_update_status: 3595 mV, 1037 mAh, 35 %, Current 16 mA
    00> [00:00:41.131,774] <dbg> bq27220_update_status: 3594 mV, 1037 mAh, 35 %, Current 25 mA
    00> [00:00:41.473,571] <inf> main: power off request
    00> [00:00:41.474,090] <inf> main: resource is closed: 0x2000821c
    00> [00:00:41.475,646] <inf> main: final power off
    00>
    00>
    00>
    00>
    #----------------------------------------------------------------
    #  2. turn on the device with USB power
    #----------------------------------------------------------------
    00>
    00> HFCLK HFXO start success.
    00>
    00> [00:00:13.129,486] <dbg> bq27220_update_status: 3722 mV, 1681 mAh, 57 %, Current 463 mA
    00> [00:00:14.130,523] <dbg> bq27220_update_status: 3723 mV, 1681 mAh, 57 %, Current 462 mA
    00> [00:00:15.129,547] <dbg> bq27220_update_status: 3724 mV, 1681 mAh, 57 %, Current 462 mA
    00> [00:00:16.130,584] <dbg> bq27220_update_status: 3725 mV, 1681 mAh, 57 %, Current 462 mA
    00> [00:00:17.129,608] <dbg> bq27220_update_status: 3726 mV, 1681 mAh, 57 %, Current 463 mA
    00> [00:00:18.129,669] <dbg> bq27220_update_status: 3727 mV, 1681 mAh, 57 %, Current 462 mA
    00> [00:00:19.130,676] <dbg> bq27220_update_status: 3728 mV, 1681 mAh, 57 %, Current 463 mA
    00> [00:00:20.129,821] <dbg> bq27220_update_status: 3729 mV, 1682 mAh, 57 %, Current 463 mA
    00> [00:00:21.130,798] <dbg> bq27220_update_status: 3730 mV, 1682 mAh, 57 %, Current 463 mA
    00> [00:00:22.131,835] <dbg> bq27220_update_status: 3731 mV, 1682 mAh, 57 %, Current 462 mA
    00> [00:00:23.129,943] <dbg> bq27220_update_status: 3732 mV, 1682 mAh, 57 %, Current 463 mA
    00> [00:00:24.130,950] <dbg> bq27220_update_status: 3732 mV, 1682 mAh, 57 %, Current 463 mA
    00> [00:00:25.129,913] <dbg> bq27220_update_status: 3733 mV, 1682 mAh, 57 %, Current 463 mA
    00> [00:00:26.130,920] <dbg> bq27220_update_status: 3734 mV, 1682 mAh, 57 %, Current 463 mA
    00> [00:00:27.129,943] <dbg> bq27220_update_status: 3735 mV, 1682 mAh, 57 %, Current 463 mA
    00> [00:00:28.131,072] <dbg> bq27220_update_status: 3735 mV, 1683 mAh, 57 %, Current 463 mA
    00> [00:00:29.130,035] <dbg> bq27220_update_status: 3736 mV, 1683 mAh, 57 %, Current 463 mA
    00> [00:00:30.130,035] <dbg> bq27220_update_status: 3737 mV, 1683 mAh, 57 %, Current 463 mA
    00> [00:00:31.131,134] <dbg> bq27220_update_status: 3737 mV, 1683 mAh, 57 %, Current 463 mA
    00> [00:00:32.129,241] <dbg> bq27220_update_status: 3738 mV, 1683 mAh, 57 %, Current 463 mA
    00> [00:00:33.130,218] <dbg> bq27220_update_status: 3739 mV, 1683 mAh, 57 %, Current 463 mA
    00> [00:00:34.129,302] <dbg> bq27220_update_status: 3739 mV, 1683 mAh, 57 %, Current 463 mA
    00> [00:00:35.130,279] <dbg> bq27220_update_status: 3740 mV, 1683 mAh, 57 %, Current 463 mA
    00> [00:00:36.129,302] <dbg> bq27220_update_status: 3741 mV, 1684 mAh, 57 %, Current 463 mA
    00> [00:00:37.130,279] <dbg> bq27220_update_status: 3741 mV, 1684 mAh, 57 %, Current 463 mA
    00> [00:00:38.129,302] <dbg> bq27220_update_status: 3742 mV, 1684 mAh, 57 %, Current 463 mA
    00> [00:00:39.129,272] <dbg> bq27220_update_status: 3742 mV, 1684 mAh, 57 %, Current 463 mA
    00> [00:00:40.130,401] <dbg> bq27220_update_status: 3743 mV, 1684 mAh, 57 %, Current 463 mA
    00> [00:00:41.131,408] <dbg> bq27220_update_status: 3743 mV, 1684 mAh, 57 %, Current 463 mA
    00> [00:00:42.129,425] <dbg> bq27220_update_status: 3744 mV, 1684 mAh, 57 %, Current 463 mA
    00> [00:00:43.130,462] <dbg> bq27220_update_status: 3744 mV, 1685 mAh, 57 %, Current 463 mA
    00> [00:00:44.129,577] <dbg> bq27220_update_status: 3745 mV, 1685 mAh, 57 %, Current 463 mA
    00> [00:00:45.130,554] <dbg> bq27220_update_status: 3725 mV, 1685 mAh, 57 %, Current 86 mA
    00> [00:00:46.129,638] <dbg> bq27220_update_status: 3640 mV, 1685 mAh, 57 %, Current 16 mA
    00> [00:00:47.130,645] <dbg> bq27220_update_status: 3637 mV, 1685 mAh, 57 %, Current 16 mA
    00> [00:00:48.129,608] <dbg> bq27220_update_status: 3636 mV, 1685 mAh, 57 %, Current 16 mA
    00> [00:00:49.129,577] <dbg> bq27220_update_status: 3634 mV, 1685 mAh, 57 %, Current 16 mA
    00> [00:00:50.130,615] <dbg> bq27220_update_status: 3633 mV, 1685 mAh, 57 %, Current 16 mA
    00> [00:00:51.131,744] <dbg> bq27220_update_status: 3631 mV, 1685 mAh, 57 %, Current 16 mA
    00> [00:00:52.129,730] <dbg> bq27220_update_status: 3631 mV, 1685 mAh, 57 %, Current 16 mA
    00> [00:00:53.130,767] <dbg> bq27220_update_status: 3629 mV, 1685 mAh, 57 %, Current 16 mA
    00> [00:00:54.129,882] <dbg> bq27220_update_status: 3628 mV, 1685 mAh, 57 %, Current 16 mA
    00> [00:00:55.130,889] <dbg> bq27220_update_status: 3627 mV, 1685 mAh, 57 %, Current 16 mA
    00> [00:00:56.129,913] <dbg> bq27220_update_status: 3627 mV, 1685 mAh, 57 %, Current 20 mA
    00> [00:00:57.130,920] <dbg> bq27220_update_status: 3622 mV, 1685 mAh, 57 %, Current 25 mA
    00> [00:00:57.488,677] <inf> main: power off request
    00> [00:00:57.489,410] <inf> main: resource is closed: 0x2000821c
    00> [00:00:57.489,837] <inf> main: final power off
    00>
    00>
    00>
    00>
    #----------------------------------------------------------------
    #  3. turn on the device using battery power
    #----------------------------------------------------------------
    00>
    00> HFCLK HFXO start success.
    00>
    00> [00:00:13.130,493] <dbg> bq27220_update_status: 3614 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:14.129,516] <dbg> bq27220_update_status: 3614 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:15.130,676] <dbg> bq27220_update_status: 3613 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:16.129,608] <dbg> bq27220_update_status: 3613 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:17.130,676] <dbg> bq27220_update_status: 3613 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:18.129,730] <dbg> bq27220_update_status: 3613 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:19.129,577] <dbg> bq27220_update_status: 3613 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:20.130,645] <dbg> bq27220_update_status: 3612 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:21.131,683] <dbg> bq27220_update_status: 3612 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:22.129,821] <dbg> bq27220_update_status: 3612 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:23.130,889] <dbg> bq27220_update_status: 3612 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:24.129,913] <dbg> bq27220_update_status: 3612 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:25.130,920] <dbg> bq27220_update_status: 3611 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:26.130,035] <dbg> bq27220_update_status: 3611 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:27.131,011] <dbg> bq27220_update_status: 3611 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:28.129,974] <dbg> bq27220_update_status: 3611 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:29.129,974] <dbg> bq27220_update_status: 3611 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:30.131,042] <dbg> bq27220_update_status: 3611 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:31.132,049] <dbg> bq27220_update_status: 3611 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:32.130,157] <dbg> bq27220_update_status: 3610 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:33.129,180] <dbg> bq27220_update_status: 3610 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:34.130,157] <dbg> bq27220_update_status: 3610 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:35.129,333] <dbg> bq27220_update_status: 3610 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:36.130,218] <dbg> bq27220_update_status: 3610 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:37.129,394] <dbg> bq27220_update_status: 3610 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:38.129,364] <dbg> bq27220_update_status: 3610 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:39.129,394] <dbg> bq27220_update_status: 3610 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:40.129,302] <dbg> bq27220_update_status: 3609 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:41.130,401] <dbg> bq27220_update_status: 3609 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:42.131,561] <dbg> bq27220_update_status: 3609 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:43.129,821] <dbg> bq27220_update_status: 3609 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:44.131,134] <dbg> bq27220_update_status: 3609 mV, 1137 mAh, 38 %, Current 16 mA
    00> [00:00:45.130,249] <dbg> bq27220_update_status: 3606 mV, 1137 mAh, 38 %, Current 25 mA

    For the GG file, should I solder wires to the I2C line of the device and connect them to the EV2400 and bqStudio?

    Regards,

    Yeongil

  • Hello Yeongil, 

    Can you please provide me with the log and gg file given by bqStudio? In order to obtain the log using bqStudio, you need to press the "start log" button at the top right of the Registers tab (see image below).

    Additionally to obtain the gg file, you can export this by going to the "Data Memory" tab in bqStudio and clicking the "Export" button on the top right (please see the image below). 

    Regards, 

    Jonny. 

  • Hello Jonny,

    Thanks for your kind explanation.

    We soldered the wires and a switch to the I2C lines of the device. Now we can switch the connection between the device and EV2400 and capture logs. I will update the log and gg file soon. Thank you.

    Regards,

    Yeongil

  • Hey Yeongil,

    Today's a federal holiday so no one is in the office. We will get back to you tomorrow.

    Regards,
    Nick Richards

  • Hello Yeongil, 

    Thank you for the update, please provide me with the bqStudio gg and log files when you obtain them. 

    Regards, 

    Jonny.