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.

TMDX654GPEVM: I2C access to PLL on SERDES board

Part Number: TMDX654GPEVM

Hello,

I am trying to read revision ID of CDCI6214 integrated circuit using I2C protocol on my development board.

I am using the factory SD card provided by TI with Arago Linux OS

R120 and R121 have been short-circuited

Reading CDCI6214 datasheed it looks like I have to perform two different I2C commands:

1) write 0x0018 to device address 0x76

2) read device address 0x76

I would like to use `i2cset` and `i2cget` commands already available in Arago

I can confirm the toolset (i2cset / i2cget) is working because I have been able to light up LEDs (LD8->LD14) on the mainboard

Unfortunately I am not able to find a device at address 0x76 in any of I2C linux devices.

This is the dump of `i2cdetect`:

root@am65xx-evm:~# i2cdetect -y -a -r 0
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- UU -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
50: 50 51 -- -- 54 -- -- -- -- -- -- -- -- -- -- -- 
60: 60 -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
root@am65xx-evm:~# i2cdetect -y -a -r 1
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
50: -- -- 52 -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
root@am65xx-evm:~# i2cdetect -y -a -r 2
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- UU -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
50: -- -- -- -- -- -- -- 57 -- -- -- -- -- -- -- -- 
60: 60 -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
root@am65xx-evm:~# i2cdetect -y -a -r 3
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
root@am65xx-evm:~# i2cdetect -y -a -r 4
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: 40 41 42 43 44 45 46 47 48 49 -- -- -- -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 

Could someone please help me understanding what I am missing?

  • Just a clarification:

    0x76 I2C address is specified in the document named "PROC062E3(003)_SCH.pdf" at page 8:

    Please check "Clock Generator" on Serdes Card

  • Hi Genesio,

    You commented that you shorted R120 and R121.  These are not the correct resistors for enabling the I2C connection to the clock generator.  Resistors R121 and R122 will connect the I2C.   Note that the clock generator provides the correct clock frequencies by default and does not need to be programmed.

    Regards, Bill

  • Sorry, I did not short R120 and R121 as stated, but R121 and R122

    I double checked.

    Sorry for the mistake in my first post.

    I just want to test I2C communication with the Serdes board by reading the Revision ID of the PLL chip

    This is just for initial debugging purpose:

    in the future I will need to access SMCLK and SMDAT on the PCIe connector to send data to a board that will be connected to the PCIe slot, but at the moment the board has not been developed yet.

    I hope this clarifies my intent

  • Hi Genesio,

    There is a know issue with the EVM associated with the MCU_I2C.  There are a set of jumpers on the board that connect the peripherals associated with the MCU_I2C to the SoC I2C1 interface.  The default configuration has the jumpers set to SoC I2C1.  You should try and access the CDCI using that bus. 

    Regards, Bill

  • I think you are referring to jumper J44 and J45

    They are already set to the correct position (left+center)

  • Hi Genesio,

    You have misunderstood my comment.  The MCU_I2C is not functional on the GP EVM.  You will need to use the SoC I2C1 if you want to communicate with the clock generator. 

    Regards, Bill

  • Dear Bill,

    thanks for the clarification.

    By "not functional" you mean that it is not enabled in software (Arago) or that the malfunction is in the hardware part?

    I set J44 and J45 to I2C1_SDL and I2C1_SDA position

    The I booted Arago and tried to find all available I2C devices:

    Unfortunately I am still not able to find the device I am looking for, and now I get errors from device /dev/i2c-1

    Please check following `i2cdetect` dump:

    root@am65xx-evm:/dev# i2cdetect -y -a -r 0
         0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
    00: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    30: -- -- -- -- -- -- -- -- -- UU -- -- -- -- -- -- 
    40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    50: 50 51 -- -- 54 -- -- -- -- -- -- -- -- -- -- -- 
    60: 60 -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    70: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    root@am65xx-evm:/dev# i2cdetect -y -a -r 1
         0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
    00: [  208.313811] omap_i2c 40b00000.i2c: timeout waiting for bus ready
    -- [  209.325823] omap_i2c 40b00000.i2c: timeout waiting for bus ready
    -- [  210.337823] omap_i2c 40b00000.i2c: timeout waiting for bus ready
    -- [  211.349845] omap_i2c 40b00000.i2c: timeout waiting for bus ready
    -- [  212.361846] omap_i2c 40b00000.i2c: timeout waiting for bus ready
    -- [  213.373855] omap_i2c 40b00000.i2c: timeout waiting for bus ready
    -- [  214.385875] omap_i2c 40b00000.i2c: timeout waiting for bus ready
    -- [  215.397875] omap_i2c 40b00000.i2c: timeout waiting for bus ready
    -- ^C[  216.409893] omap_i2c 40b00000.i2c: timeout waiting for bus ready
    
    root@am65xx-evm:/dev# i2cdetect -y -a -r 2
         0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
    00: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    20: -- UU -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    50: -- -- -- -- -- -- -- 57 -- -- -- -- -- -- -- -- 
    60: 60 -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    70: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    root@am65xx-evm:/dev# i2cdetect -y -a -r 3
         0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
    00: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    50: -- -- 52 -- -- -- -- -- -- -- -- -- -- -- -- -- 
    60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    70: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    root@am65xx-evm:/dev# i2cdetect -y -a -r 4
         0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
    00: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    40: 40 41 42 43 44 45 46 47 48 49 -- -- -- -- -- -- 
    50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    70: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    root@am65xx-evm:/dev# i2cdetect -y -a -r 5
         0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
    00: [  226.154005] omap_i2c 2030000.i2c: controller timed out
    -- [  227.209997] omap_i2c 2030000.i2c: controller timed out
    -- [  228.265995] omap_i2c 2030000.i2c: controller timed out
    -- ^C[  229.322049] omap_i2c 2030000.i2c: controller timed out
    

  • Hello Bill,

    I am still not able to find a workaround for this issue.

    I am not sure if there is an hardware bug in the development board or the issue is in the software

    Could you please help me solving this problem?

    Genesio

  • Hi Genesio,

    I am not sure if we have ever attempted to access that device using the I2C interface.  I will have to get one of the software support team members involved.  I will forward your question to them and get back to you as soon as possible.

    Regards, Bill

  • Hi Genesio,

    I am wondering if the MCU_I2C is enabled in the Uboot and Linux device-tree node. By default, we do not enable the MCU_I2C bus but I have attached a reference patch that shows how you could enable the bus. With regards to the pin mux, please use the pin mux tool to specific the bus pins.

    Regards,
    Krunal

    2500.test.txt
    diff --git a/arch/arm/dts/k3-am654-base-board.dts b/arch/arm/dts/k3-am654-base-board.dts
    index 08a9c42199..e5da25aea4 100644
    --- a/arch/arm/dts/k3-am654-base-board.dts
    +++ b/arch/arm/dts/k3-am654-base-board.dts
    @@ -49,6 +49,13 @@
     		>;
     	};
     
    +	mcu_i2c0_pins_default: mcu-i2c0-pins-default {
    +		pinctrl-single,pins = <
    +			AM65X_WKUP_IOPAD(0x00e8, PIN_INPUT, 0) /* (AD8) MCU_I2C0_SCL */
    +			AM65X_WKUP_IOPAD(0x00ec, PIN_INPUT, 0) /* (AD7) MCU_I2C0_SDA */
    +		>;
    +	};
    +
     	mcu_fss0_ospi0_pins_default: mcu-fss0-ospi0-pins-default {
     		pinctrl-single,pins = <
     			AM65X_WKUP_IOPAD(0x0000, PIN_OUTPUT, 0) /* (V1) MCU_OSPI0_CLK */
    @@ -164,6 +171,12 @@
     	};
     };
     
    +&mcu_i2c0 {
    +	pinctrl-names = "default";
    +	pinctrl-0 = <&mcu_i2c0_pins_default>;
    +	clock-frequency = <400000>;
    +};
    +
     &main_i2c0 {
     	pinctrl-names = "default";
     	pinctrl-0 = <&main_i2c0_pins_default>;