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.

BQ20Z95 Linux I2C SMBUS SmartBattery (SBS) not Detected

I am working on an embedded Linux project with the OMAP 3730. We are using version 3.2.23 of the Kernel. I2C works fine and I can see various sensors from the board on bus #2. I2C bus #3 only has a Smart Battery attached and I can remove the power cord and the battery keeps the board running. The issue is that I cannot detect or otherwise scan for the smart battery. I've tried the various programs in i2ctools with no luck. We hooked the board up to the scope and can see activity on the bus #3. I have enabled every pertinent option under the Device Drivers > I2C Support in the Kernel. I also enabled the driver under Drivers > Power Supply Class Support > TI BQ20z75 gas gauge. When the board boots with the battery connected this driver is not loaded automatically and if I modprobe it , dmesg says driver loaded but I still cannot seem to find a device in the Kernel for the smart battery.

How can I view my smart battery on the SMB bus and communicate with it? Do I need to enable something else in the Kernel? Thanks -

Standard SMBus slave address assignments for SBS devices include:
0x10 -- SMBus System Host
0x12 -- Smart Battery Charger
0x14 -- Smart Battery Selector
0x16 -- Smart Battery

# ls /dev/i2c-?
/dev/i2c-1
/dev/i2c-2
/dev/i2c-3

# i2cget -y 3 0x10 0x00 w p
Error: Read failed
#
# i2cget -y 3 0x0b 0x00 w p
Error: Read failed

# i2cdetect -r 3
WARNING! This program can confuse your I2C bus, cause data loss and worse!
I will probe file /dev/i2c-3 using read byte commands.
I will probe address range 0x03-0x77.
Continue? [Y/n] y
0 1 2 3 4 5 6 7 8 9 a b c d e f
00: -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --

# i2cdetect -F 3 Functionalities implemented by /dev/i2c-3:
I2C yes SMBus
Quick Command no
SMBus Send Byte yes
SMBus Receive Byte yes
SMBus Write Byte yes
SMBus Read Byte yes
SMBus Write Word yes
SMBus Read Word yes
SMBus Process Call yes
SMBus Block Write yes
SMBus Block Read no
SMBus Block Process Call no
SMBus PEC yes
I2C Block Write yes
I2C Block Read yes

# i2cdetect -l i2c-1 i2c
OMAP I2C adapter I2C adapter i2c-2 i2c
OMAP I2C adapter I2C adapter i2c-3 i2c
OMAP I2C adapter I2C adapter
  • The solution was to decrease the bus speed to 100 KHz for the bus that the gas gauge chip was on. After that I get:

    # i2cdetect -y -r 3 0 1 2 3 4 5 6 7 8 9 a b c d e f 
    00: -- -- -- -- -- -- -- --
    0b -- -- -- --
    10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
    20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
    30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
    40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
    50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
    60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
    70: -- -- -- -- -- -- -- --