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.

BQ78350-R1: ROM Mode commands and updating FW

Part Number: BQ78350-R1
Other Parts Discussed in Thread: , BQSTUDIO

I am using the bq78350-R1 in a product in production, and I was wondering how the ROM Mode works.

I already have functioning code to read and write to the Data Flash.  However, what commands are used to write to the ROM area (i.e. addresses 0x100000 through 0x117FFF)?

The Technical Reference Manual states:

ManufacturerAccess() 0x0F00 ROM Mode
This command sends the device into ROM mode in preparation for re-programming. [...] use 0x08 to
ManufacturerAccess() to return.

Are there a different set of commands available when in ROM mode? Do I write to the ROM area using the Data Flash block write commands?

Is there example code somewhere for re-programming the ROM?

  • Hi Joshua,

    Are you needing to program different firmware to the device (for example some customers program BQ78350-R2 firmware if they need features only available in the R2)? This is the only reason you would need to use ROM mode since the address range 0x100000 onward is instruction flash and should not be written unless you need to update the firmware version.

    In the past, some users have used ROM mode to update the firmware to the latest version. However, the latest version of the R1 firmware is available pre-loaded on the device if you order the BQ78350-R1A.

    There are different commands for ROM mode that are not described in the TRM. I do have some example code I can share with you privately if you send me a friend request on E2E.

    Best regards,

    Matt

  • Hi Matt,

    We have some units that were undergoing some in-house testing that we accidentally put into "Permanent Fail" mode (due to incorrect current threshold settings).  My understanding is that the only way to "reset" the BMS out of this mode is to re-program the firmware, as data flash writes are disabled once Permanent Fail is triggered.

    Is there any documentation regarding the specific changes included in the updated R1A firmware?  How does this differ from the R2 firmware?

    Thank you for the quick reply; I have sent you a friend request..

  • Hi Joshua,

    I understand. In this case, you can send the command 0x0029 (Permanent Fail Data Reset) and then you should once again be able to write to data flash.

    This thread explains the differences between R1, R1A, and R2 firmware: 

    https://e2e.ti.com/support/power-management/f/196/t/879900

    The only difference between R1 and R1A is the Shutdown routine is more robust for the R1A. We recommending using the R1A since it is functionally identical to the R1.

    Let me know if you still need the code example for writing instruction flash.

    Best regards,

    Matt

  • Hi Matt,

    So if I understand correctly, sending the 0x0029 (Permanent Fail Data Reset) clears the saved PF data and takes the gauge out of "Permanent Fail" mode, as if the mode was never triggered?

    I would still like the example code to use for our internal testing.



    I have one last question, about the Permanent Fail data stored in the Data Flash:

    For e.g. Safety Alert, which bytes "A,B,C,D" correspond to which bits of the SatefyAlert register?

    RSVD (Bits 31–21): Reserved
    OC (Bit 20): Overcharge
    CTOS (Bit 19): Charge Timeout Suspend
    RSVD (Bit 18): Reserved
    PTOS (Bit 17): Precharge Timeout Suspend
    RSVD (Bits 16–15): Reserved
    OCDL (Bit 14): Overcurrent During Discharge Latch
    OTF (Bit 13): Overtemperature Fault
    AFE_OVRD (Bit 12): AFE Alert
    UTD (Bit 11): Undertemperature During Discharge
    UTC (Bit 10): Undertemperature During Charge
    OTD (Bit 9): Overtemperature During Discharge
    OTC (Bit 8): Overtemperature During Charge
    ASCDL (Bit 7): Short Circuit During Discharge Latch
    ASCD (Bit 6): Short Circuit During Discharge
    AOLDL (Bit 5): Overload During Discharge Latch
    AOLD (Bit 4): Overload During Discharge
    OCD (Bit 3): Overcurrent During Discharge
    OCC (Bit 2): Overcurrent During Charge
    COV (Bit 1): Cell Overvoltage
    CUV (Bit 0): Cell Undervoltage


    i.e. is Permanent Fail Safety Alert A bits 24-31 or bits 0-7?

    Thank you,

    Joshua

  • Yes, that is correct.

    For the SafetyAlert bytes, BQStudio helps to clarify which bits are A,B,C,D (see image below). D is the most significant byte and A is the least significant byte.

    I will send you the sample code via private message.

    Regards,

    Matt