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.

BQ34Z100-G1 write/checksum problem

Other Parts Discussed in Thread: BQ34Z100-G1, BQSTUDIO

Hi,

I'm experiencing a strange problem with BQ34Z100-G1. I can read data and flash successfully. But when I try to modify flash, the device stop responding after writing the checksum. Reading the forum, I can see that this behavior might be caused by a wrong checksum. To eliminate this option, I tried to read the flash, then read the checksum from chip, followed by writing that checksum back (no changes to flash). So, in this case the checksum is correct for sure. But the problem is still there unfortunately.

I appreciate any help!

Thanks
Kir

  • The gauge should reject the block of data, if the checksum is incorrect. I should continue to respond. Can you send the srec file from you pack and the commands and data that you are entering to cause the bad condition?
  • We don't use a dev board at the moment (but I will get it shortly to reproduce the problem). So, currently we do all the communications from a controller to the chip using i2c:

    // select page
    write 0x61, 0
    write 0x3e, 48
    write 0x3f,  0

    //read page
    read 0x40, {32 bytes}

    // read checksum
    read  0x60, chkSum

    // write checksum back
    write 0x60, chkSum

  • I have the same problem at the moment.

    I want to reset the Cycle Count in case the batteries are replaced.

    Reading the 32 bytes works, the data looks correct.

    After writing the changed data back and sending the checksum i want to read the block again and verify the changes.

    But the command after sending the checksum hangs.

    Here is a log from the data analyzer on the I2C bus:

    Is it necessary to wait some time after sending the checksum to let the gas gauge write the data to flash?

    Regards

    Sebastian

  • I verify that the data is correctly read now by reading the checksum and calculating it over the read data.
    Writing back the data and checksum works too. The gas gauge accepts the changed data.
    bqStudio shows my changes when i read back the data from the gas gauge.
    So i am sure everything is ok with the write command.
    But still the next command (0x61) hangs.
  • I tried a sequence and did not encounter the hanging problem. Please provide the sequence where you had the problem.

  • We've finally got a development board + EV2300 and the chip works with it.

    However, EV2300 communicates over i2c using a non-standard and extremely slow baudrate ~35 kbps. Indeed that was the key - slowing down the bus, I can make BQ working. But it won't work over 100k or 400k standard bps bus. I would consider this as a bug of  BQ34Z100-G1.

    I have attached two CRO shots, where the checksum is sent from EV2300 at weird rate and then from my CPU (tm4c1290) at a standard 100 kbps rate. You can see that there is no ASK bit in the latest case.

  • I've tried it with a baudrate down to 20k, but after sending the checksum the next command still timed out (longer than 70ms).
    I've added a long delay (1 second) now after sending the checksum and this way writing the dataflash even works with a baudrate of 100k.
    It seems like the gas gauge needs some time writing the data flash and doesn't respond via I2C. I have not found any specification for this in the datasheet. It would be interesting what maximum time one must wait when the gas gauge writes to the data flash until it is ready again.