Skip to main content
Visitor II
October 22, 2024
Question

HAL_I2C_IsDeviceReady error at 100khz

i am getting sistematically the exact problem described in this post https://github.com/STMicroelectronics/STM32CubeG0/issues/46 at 100kHz I2C frequency. I am using a nucleo with stm32fg031. Even tho i have set up 5 trials, i only get on my analyzer one trial and than i end up with the error. When setting the I2C at 400kHz i no longer get the error from the HAL. How can i get it to work without having to deinit the i2c?

This topic has been closed for replies.

2 replies

Andrew Neil
Super User
October 22, 2024

@kuzi_996 wrote:

 I am using a nucleo with stm32fg031. 


Give details of the rest of your setup - what I2C device? schematic, code, etc

https://community.st.com/t5/community-guidelines/how-to-write-your-question-to-maximize-your-chances-to-find-a/ta-p/575228

What do you see on an oscilloscope? Compare & contrast at 100kHz & 400kHz...

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.
Pavel A.
October 22, 2024

> When setting the I2C at 400kHz i no longer get the error from the HAL

So... set the I2C to 400 kHz? Why do you set it to 100 kHz?