AnsweredAssumed Answered

Configure I2c freq register while keeping in mind freq varaition

Question asked by A2 on Jun 25, 2013
Latest reply on Jun 25, 2013 by knik
I am using STM32F205RTB6 with internal oscillator (+- 4%), & APB1 peripheral is clocked at 30Mhz.
So max variation in it is 28.8Mhz to 31.2Mhz
I have to operate I2c in fast mode.

Now while configuring CCR register , I had kept in mind this variation so come up the value of CCR = 21 , to keep within fast mode specs even if freq varies.

1.Now on configuring TRISE register, how to keep this variation in mind. tr = .3us

For 28.8 mhz i come up with = (28.8Mhz * 0.3us)+1 = (8.64 + 1) = 9.64
For 30.0 mhz i come up with = (30.0Mhz * 0.3us) +1= (9.00 + 1) = 10 
For 31.2 mhz i come up with = (31.2Mhz * 0.3us) +1= (9.36 + 1) = 10.36 

What value should be programmed exactly. 

Edit: Where I can freq. I want to operate at 390Khz for safe region. Where to set it, is it by setting tlow or thigh only

Outcomes