Because of the Thanksgiving holiday in the U.S., TI E2E™ design support forum responses may be delayed from November 25 through December 2. Thank you for your patience.

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.

PCA9538: During I2C read/write, values are being read and written strangely.

Part Number: PCA9538

Using PCA9538, I constructed the circuit as follows, but I have some questions.
1. In the datasheet, the default value of Register 1 is 0xFF,
The default value of Register 3 was 0xFF.
However, when reading with I2C, Register 1 is read as 0x01 and Register 3 is read as 0x03.

2. The default value of Register 1 is read as 0x01, but the output does not come out unless a new value is written again.

3. If 0x02 is written to Register 1 as shown below, the actual output is shown as 0x02, but when read by I2C, other values are read. Other values such as 0x03 are the same.

4. As for the value of Register 3, if the actual PIN is NC, is the corresponding PIN value not written? For example, when writing 0x05, 0x01 is read.

 

 


  • Hi Park,

    "1. In the datasheet, the default value of Register 1 is 0xFF,
    The default value of Register 3 was 0xFF.
    However, when reading with I2C, Register 1 is read as 0x01 and Register 3 is read as 0x03."

    If you toggle the reset low and then release (back high) and do another read of those registers, do you still read 0x01 and 0x03 respectively?

    "2. The default value of Register 1 is read as 0x01, but the output does not come out unless a new value is written again."

    (In regards to your o-scope shot) Instead of doing a restart condition when you read (write 0x01h then you did a restart), can you try a stop then start condition for the read instead?

    "3. If 0x02 is written to Register 1 as shown below, the actual output is shown as 0x02, but when read by I2C, other values are read. Other values such as 0x03 are the same."

    Below I looked at the transaction bit by bit. I noticed something strange on the last transaction where the read is supposed to be 0x02h. I circled in white the VoL shift. It kind of looks like our device (PCA9538) releases the SDA line but something else pulls the line low since the low levels are different.... Are there any other I2C slaves on the bus?

    Just to experiment, can you set our device in reset (pull the pin to GND) then try to write to our device and see if you get an ACK? We should expect a NACK but if we see an ACK then we know there is an address conflict occurring.

    Second thing we can try, instead of doing a restart condition when you read, can you try a stop then start condition for the read?

    Thanks,

    -Bobby

  • Thanks,

    Just to experiment, can you set our device in reset (pull the pin to GND) then try to write to our device and see if you get an ACK? We should expect a NACK but if we see an ACK then we know there is an address conflict occurring.

    -> In the test with the above method, there was ACK and there was an address conflict. After changing the address, it was confirmed that everything works normally.

    Thanks again.