2023-04-07 03:15 AM - edited 2023-11-20 08:44 AM
Hi everyone, we are using stm32f405rgt6 microcontroller in our robot, when we are using i2c for reading data from BNO055 module suddenly the device get out of the i2c line or maybe can not read the data,
Here are some more details:
we pulled up our i2c lines with 10k resistors.
And this photo that I mentioned is our BNO055 module:
Also, I configured the I2C2 with the following details:
However we didn't have this problem with stm32f103c8t6 microcontroller before.
2023-04-07 04:02 AM
Hello @smhn24 ,
Try to use an Oscilloscope to see the SDA and SCL behavior.
If nothings appears, please check the error flags set in the status register, get the error (HAL_I2C_GetError)
Foued
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.
2023-04-08 04:44 AM - edited 2023-11-20 08:44 AM
Thanks for your responsing, we check our I2C lines with logic analyzer device and we tested our I2C lines when the I2C start and our module sent data but suddenly after many reset the microcontroller, I2C did not start anymore and we must to turn off the power and back on to working again.
Is there any way to find out our I2C start well or not?
However, we suspect that both SCL and SDA lines remain high or low and don't let MCU start I2C.
Here is our data log before this happens:
Also we check (HAL_I2C_GetError) and always returns zero
2023-04-09 08:29 AM
If nothings appears, please check the error flags set in the status register.
If the error is :
Foued
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.