Skip to main content
SSaya.1
Associate III
December 15, 2021
Solved

i2c to communicate two STM32F103C8T6

hello,

i am trying i2c to communicate two stm32f103c8t6 . It is not working. logic analyzer output is shown in picture.

what can be done for i2c to communicate two stm32f103c8t6

address 0x000693W00000HoeKxQAJ.png

This topic has been closed for replies.
TDK
TDKBest answer
December 15, 2021

0x00 shouldn't be used as a slave address as it's a general call address. The logic analyzer plot is otherwise a valid I2C signal. If the slave is not responding, it's probably a code issue. Although it seems like it is responding about every other time, so this suggests the slave is not ready when the master sends the message.

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

3 replies

ST Technical Moderator
December 15, 2021

Hello @SSaya.1​ ,

I advise you to have a look at this FAQ: STM32 I2C does not work, which describes few tips related to I2C peripherals.

I suggest also to check the I2C example available in STM32CubeF1 MCU package and compare your own code/configuration to identify what is going wrong with your project.

When your question is answered, please close this topic by choosing Select as Best.

Imen

In order to give better visibility on the answered topics, please click on 'Best answer' on the reply which solved your issue or answered your question. Thanks
TDK
TDKBest answer
December 15, 2021

0x00 shouldn't be used as a slave address as it's a general call address. The logic analyzer plot is otherwise a valid I2C signal. If the slave is not responding, it's probably a code issue. Although it seems like it is responding about every other time, so this suggests the slave is not ready when the master sends the message.

"If you feel a post has answered your question, please click ""Accept as Solution""."
SSaya.1
SSaya.1Author
Associate III
December 16, 2021

thank you, I2C worked, i had no idea about I2C plotting by logic analyzer before