cancel
Showing results for 
Search instead for 
Did you mean: 

How to set I2C clock speed for STM32L432....

briancavanagh91
Associate II

A reference to an existing explanation would be fine.

I can't find a reference manual

2 REPLIES 2
HRead
Associate

I do know that SCL is derived from the core's bus clock and there needs to be an even divisor between the bus clock and 400KHz. So you may need to change your bus frequency or if you are using axi, you can just change the frequency of the core's axi clk.

https://percentagescalculator.com/

Amel NASRI
ST Employee

Hi @briancavanagh91​ ,

There is an application note dedicated for STM32F3xxxx and STM32F0xxxx  that describes how to configure I2C_TIMINGR register.

This application note should help you to understand the theory: https://www.st.com/resource/en/application_note/dm00074956.pdf.

Then, if you use the STM32CubeMX tool and enable the I2C peripheral, it will calculate the suitable configuration for TIMINGR register depending on the values you select for timing parameters and on your clock settings.

-Amel

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.