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.

AM1806: I2C SCL was low after toggle SCL to resolve I2C hang

Part Number: AM1806

Dear Champs,

My customer faced I2C line hang and resolve it referring below. As other methods were not help to resolve their hang issue, they used recommendation 1 in below.

But, they found AM1806 I2C block was hang after several trials and SCL was low at this time.

AM1806 I2C block was not recovered even after power on/off.

Can you guess why SCL of AM1806 I2C was low and was not recovered?

Thanks and Best Regards,

SI.

  • Can you share the I2C registers configurations? Maybe there is an erroneous setting.

    Best Regards,
    Yordan
  • Hi,

    The below is the register dump of issued device.

    I2C Controller reg dump (issued core)
    Address Data
    01C22000 00000000 0000007F 00000410 000001EF
    01C22010 000001EF 00000001 000000FF 00000070
    01C22020 00000000 00000000 00000000 00000001
    01C22030 00000002 00004415 00002206 00000003
    01C22040 00000000 00000000 00000000 00000000
    01C22050 00000003 00000000 00000000 00000000


    The below is the dump of normal device.
    I2C Controller reg dump (normal core)
    Address Data
    01C22000 00000000 0000007F 00000410 000001EF
    01C22010 000001EF 00000001 00000055 00000070
    01C22020 00000000 00000000 00000000 00000001
    01C22030 00000002 00004415 00002206 00000003
    01C22040 00000000 00000000 00000000 00000000
    01C22050 00000003 00000000 00000000 00000000


    Thanks and Best Regards,
    SI.
  • And also, they changed pinmux controls as below to resolve I2C communication hang according to wiki .


    void i2c0_change_to_gpio(void)
    {
    int retry = 0;

    // i2c0 -> gpio
    if ( hal_pinmux_config( &pinmuxes_i2c0_to_gpio ) != 0 )
    return ;

    // gpio 설정 ( SCL : output high, SDA : input )
    hal_gpio_configuration( &system_gpio_for_i2c0 , system_gpio_for_i2c0_count);

    // wait for SDA release
    while( hal_gpio_read(I2C0_SDA_GPIO) != 1 )
    {
    // toggle SCL
    hal_gpio_write(I2C0_SCL_GPIO, 0); // Low

    udelay(62);

    hal_gpio_write(I2C0_SCL_GPIO, 1); // High

    udelay(62);

    retry++;

    if(retry == 100)
    break;
    }

    console_printf("\nGPIO SDA [%s] Retry [%d]\n", ((hal_gpio_read(I2C0_SDA_GPIO) == 1)?"HIGH":"LOW"), retry);

    // gpio -> i2c0
    if ( hal_pinmux_config( &pinmuxes_gpio_to_i2c0 ) != 0 )
    return ;
    }


    Thanks and Best Regards,
    SI.
  • Hi SI,

    It's been a while since there's been any activity on this thread, and it sounds like this issue has been resolved in your last post.  I am marking this as "TI thinks resolved."

    Regards,

    Melissa