cancel
Showing results for 
Search instead for 
Did you mean: 

I2C timing on STM32u385 Nucleo

RiyadAbd
Associate II

Hi,

I am using NCLEO-U385RG-Q  running STM32u385.  I created a project using the board selector.  I configured I2C2 using STM32CubeIDE to run in fastmode at 400khz for PINs PA6/PB2 per schematics described in MB1841.  My clock sources are all defaults (see attached) also my calculated timings (attached).  

I run the code and the timing doesn't match what I programmed.  I am seeing an I2C clock at around 13.158 MHz.  Can you please assist? 

Thank you

5 REPLIES 5
RiyadAbd
Associate II

Also see io muxing attached and timing

TDK
Super User

Do the example I2C projects work?

STM32CubeU3/Projects/NUCLEO-U385RG-Q/Examples/I2C/I2C_TwoBoards_ComDMA at main · STMicroelectronics/STM32CubeU3

 

The waveform has more things wrong than just the frequency. Start and stop bits are all over the place. Take an analog capture of SDA and SCL at the very start of the transaction to see if rise/fall times are acceptable.

 

You'll need external pullups in the 2 kOhm range to achieve reasonable speeds.

If you feel a post has answered your question, please click "Accept as Solution".
Maxime_MARCHETTO
Community manager
Community manager

Hello @RiyadAbd,

This post has been escalated to the ST Online Support Team for additional assistance. We'll contact you directly.

Best regards,
Maxime


In order 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.

Hi Maxime, 

This is no longer an issue please close.

Thank you


@RiyadAbd wrote:

This is no longer an issue please close.


You close the issue by marking the solution - see:

https://community.st.com/t5/community-guidelines/help-others-to-solve-their-issues/ta-p/575256

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.