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.

Wrong CLK frequency on I2C

Other Parts Discussed in Thread: TPS650732, AM3517

I am trying to write to the TPS650732 PMU from an AM3517 CPU.  The AM3517 seems to program fine--we have several other functions on the board functioning properly.  BUT, our I2C CLK frequency is supposed to be running at 400kHz and is only at ~108kHz.  

When we try the same procedure with the EVM everything works fine.  Our I2C interface is operating from the I2C_2 port on the AM3517 and it's only destination is the PMU.  We started with 4.7k pullups and have switched to a 2.2k pullup without any change.  

Has anyone seen this before?  Without the I2C interface we can't generate our LCD voltage and thus verify it's functionality.  

  • Hello Dave,

    Are you using the exact same driver or register settings for I2C2 module on both platform ? What is your OS ?

  • We are using the same code on both platforms.  The code was downloaded from Logic's website.  We are not using an OS.  The EVM I2C runs at 400kHz and our board runs at ~108kHz.

     

  • Could you read below registers after you run the code on both platforms. PRCM registers set a functional clock frequency to I2C modules. I2C2 registers set I2C2 SCLK clock frequency.

    PRCM
    CM_FCLKEN1_CORE 0x4800 4A00
    CM_CLKEN_PLL 0x4800 4D00
    CM_CLKSEL1_PLL 0x4800 4D40
    CM_CLKSEL2_PLL 0x4800 4D44
    CM_CLKSEL3_PLL 0x4800 4D48

    I2C2
    I2C_PSC 0x4807 2030
    I2C_SCLL 0x4807 2034
    I2C_SCLH 0x4807 2038

  • Hi Dave,

    Have you verified that the source which you are using to derive the clock and that of EVM has the same value?

    Also, it may be possible that EVM uses a default file (called as GEL file for Davinci and other processors, not sure what it is for AM3517) which initialises the PLL on startup to a predefined frequency by setting default multiplier and divider values. You may have to set up the same for your custom board. It doesnt seem a problem with pull-up resistor values, because then I2C wont work at all..

    Regards,

    Sid