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.

MSP430g2212 USI i2c master mode ,interface with bq27510-G2

Other Parts Discussed in Thread: MSP430G2212, BQ27510-G2, BQ27410-G1


hi,

I am interfacing MSP430g2212 controller with bq27510-G2 fuel gauge through USI-i2c master mode.
I have taken an example code from "http://processors.wiki.ti.com/index.php/I2C_Communication_with_USI_Module"

Based on that ,I have added 16bi read/write API .
If i try to get DEVICE_TYPE from fuel gauge, i am getting always 0xFF10. But if the datasheet of "fuel gauge" says , DEVICE_TYPE like 0x0510 should get.

CRO CAPTURED I2C (PLS ref attached wave form & Code)


S 0xAA A 0x00 A 0x01 A 0x00 A S 0xAB A 0x10 A 0xFF A P

Code snaps:

if(write_reg16(0x00, 0x0001) != TRUE)
{
__no_operation(); // for debugger
}
dataX=0;
// read out DOUTZ register
if(read_reg16(0x00, &dataX) != TRUE)
{
__no_operation(); // for debugger
}


Queries:

1) I would like to know whether i am getting right thing or wrong.
2) Is there any possible ways to test the driver ?

Thanks& Regards
Raghu Ramaraj

**Attention** This is a public forum