Other Parts Discussed in Thread: BQSTUDIO
Hello. I'm trying to read the battery current using Average Current (address 0x14 and 0x15) and Instantaneous Current (address 0x22 and 0x23). While testing, my battery is drawing ~40mA as verified using a DMM in series. The Technical Reference Manual says that what is returned is a "signed integer value", and the units are mA. I take this to mean a 32 bit value. The bytes returned are the following:
0xd6
0xff
0x00
0x00
0xd6 is 214 decimal, nowhere near 40. If you change the most significant bit from a 1 to a 0 (1 signifying current exiting the battery), this value is now 0x56 or decimal 86, again not near 40. Incorporating the other bytes only makes the value larger. Can someone elaborate as to how to get an accurate current reading?
Thanks,
Rob