Other Parts Discussed in Thread: BQSTUDIO
We have designed a custom board which is interface with raspberry pi 3 via I2C-0 .
i am able to see the device through i2cdetect command.
i am also able to read temperature, voltage , and current readings from the device.
but when i try to set the capacity the device is not switching into unseal mode.
i am writing the registers as mentioned in bq27441-G1 Technical Reference
the first 2 bytes of the UNSEAL key using the Control(0x8000) command. Without writing any other bytes to the device, i am writing the second (identical) 2 bytes of the UNSEAL key
SET_CFGUPDATE subcommand, Control(0x0013) is written next after writing the unseal command .
i am able to confirm CFGUPDATE mode by polling Flags() register until bit 4 is set.
the issue is when i try to write BlockDataControl() command (0x61) to enable block data memory control.
i get i2c error,{ ioctl(self.fd, I2C_SMBUS, msg)OSError: [Errno 121] Remote I/O error}
i believe the device is not switching to unseal mode, because in data sheet it says the register is only accessible in unsealed mode .
can you please help in setting the capacity of the battery .