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.

TM4C123GH6PM: I2C clock speed

Part Number: TM4C123GH6PM

In TM4C123GH6PM datasheet the formula for setting i2c clock speed is:

SCL_PERIOD = 2 × (1 + TIMER_PRD) × (SCL_LP + SCL_HP) × CLK_PRD

I am confused about  SCL_LP and  SCL_HP, the datasheet says : 

SCL_LP is the low phase of SCL (fixed at 6)
SCL_HP is the high phase of SCL (fixed at 4)

but if they are fixed, how would the clock speed be changed ?

Can anyone please explain what do SCL_LP and SCL_HP really mean?

  • Hello Amr,

    I wouldn't mind looking into the details, but why do you even need to get into that level of detail? TivaWare API handles the clock speed setting if used properly anyways.
  • I am practicing working with controller so my goal is to understand the low level details not just getting something to work.
    I would appreciate if you can explain the meaning of SCL_LP and SCL_HP.
    thank you.
  • Hello Amr,

    Okay, just so you understand we do not support direct register programming and only TivaWare. So if you run into future issues, you will not receive support from TI until you move to TivaWare.

    SCL_LP and SCL_HP are just constants that are required to be understood for the calculation. This is design level details, hence they are fixed, but omitting them would cause incorrect calculations so they are offered as hard values to ensure proper calculation.

    Clock speed is changed by modifying either system clock or the timer period.