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.

J784S4XEVM: Access one of the GPIO expander on the J784S4XEVM

Part Number: J784S4XEVM

Tool/software:

Hi,

I am facing a problem to access one of the GPIO expander on the J784S4XEVM. 

I would like to access the expander1 on I2C0 at address 0x20 :

However, it is not detected in Uboot and in Linux. This is one of the only devices that are not detected.

On u-boot, with the following commands: 

i2c dev 0
i2c probe 

I get Valid chip addresses: 30 31 40 43 48 49 4A 4B 50 7C

On Linux, with:

 

i2c detect -r -y 0

I get the following chip detected: 30 31 40 43 48 49 4A 4B 50

As shown, the address 0x20 is not detected.

Is there anything specific to do to access this chip? Indeed, I would like to access the P01, P02, P05 and P06 of this chip:

Thanks in advance for your help.

Best Regards.

K.L

  • Hi K.L,

    On u-boot, with the following commands: 

    Fullscreen
    1
    2
    i2c dev 0
    i2c probe
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    I get Valid chip addresses: 30 31 40 43 48 49 4A 4B 50 7C

    On Linux, with:

     

    Fullscreen
    1
    i2c detect -r -y 0
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    I get the following chip detected: 30 31 40 43 48 49 4A 4B 50

    Both methods you have used here are correct to scan an I2C bus for devices. However, the GPIO expander on Main I2C0 is not necessarily guaranteed to be indexed as I2C bus 0. Therefore, you will want to detect and probe various different I2C bus and compare to the adresses of devices on the bus to know for sure which bus is Main I2C0. 

    For example, based on the devices you have detected on the bus, we can conclude that I2C bus 0 is actually WKUP I2C0.

      

    Thanks,

    Neehar

  • Hi, 

    Thanks for your answer. I missed this point.

    The main I2C0 was indeed detected as i2c3. 

    Best Regards,

    K.L

  • Hi K.L,

    I’m glad you were able to detect the bus and access the GPIO expander. Closing the thread.

    Thanks,

    Neehar