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: Communication is happening normally even if the PEC is not send by the microcontroller

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

Hi Team,

In SMB configuration the HPE is 1 i.e PEC on host communication is enabled. The SpecificationInfo() is having the the value 0x31. 

I am communicating over SMbus by not writing or reading the PEC byte but, still teh communication is happening with bq78350.

I need to understand how the commmunication happens with bq78350 even if PEC is not sent by host MCU.

Regards,

Shreyas Shroff

  • Hi Shreyas,

    The BQ78350 will respond to the host with or without the PEC byte. If the PEC byte is sent and it is incorrect, it will respond with a NACK. For example, by default BQStudio sends the PEC byte and the BQ78350.

    The HPE bit is for BQ78350 broadcasts to the host - if this bit is enabled it will include a PEC byte in the broadcasts.

    Best regards,

    Matt

  • Hi Matt,

    Does it mean we can write to bq78350  even if PEC is not sent from micro-controller?. I am using NXP micro-controller.

  • Hi Shreyas, 

    Yes, the BQ78350 can be written with or without PEC. However, if a PEC byte is sent, it will be validated by the BQ78350 before allowing the write. 

    Best regards,

    Matt

  • Hi Matt,

    Thank you for the above inputs. 

    I am not facing issue while reading the PEC value from bq78350-r2 IC. The salve address to read the PEC is 0x17

    1. I am reading 0x1A specificationinfo() from bq78350-r2 and get 2 byte value as 0x31 and 0x10.

    2. If the value the value is 0x31 it support the PEC so, next time I am reading the data with PEC and I get 0x31 , 0x10 and 0xAA. 

    3. When I am calculating the PEC having CRC_KEY(C(x) = x8 + x2 + x1 + 1.) as 7, I get the value after performing CRC8 as 0x28

    I would like to know why bq78350-r2 is sending 0xAA as it PEC value. If this value is correct how it is calculating the PEC?.

    Regards,
    Shreyas Shroff

  • Hi Matt,

    Thank you for the above inputs. 

    I am facing issue while reading the PEC value from bq78350-r2 IC. The salve address to read the PEC is 0x17

    1. I am reading 0x1A specificationinfo() from bq78350-r2 and get 2 byte value as 0x31 and 0x10.

    2. If the value the value is 0x31 it support the PEC so, next time I am reading the data with PEC and I get 0x31 , 0x10 and 0xAA. 

    3. When I am calculating the PEC with CRC_KEY(C(x) = x8 + x2 + x1 + 1.) as 7 on slave address nd received data 0x17 0x31 and 0x10 I get the value after performing CRC8 as 0x28.

    I would like to know why bq78350-r2 is sending 0xAA as it PEC value. If this value is correct how it is calculating the PEC?.

    Regards,
    Shreyas Shroff

  • Hi Shreyas,

    I think the example in this other thread might be helpful: https://e2e.ti.com/support/power-management/f/196/t/869904

    The PEC calculation needs to include the entire sequence: 0x16 0x1A 0x17 0x31 0x10

    I confirmed the 0xAA result using this online tool: https://crccalc.com/

    Best regards,

    Matt