Random I2C issue

FrancisL
Posts: 21
Joined: Wed Jul 25, 2018 3:34 pm

Random I2C issue

Postby FrancisL » Tue Dec 17, 2019 6:31 pm

We made some boards with ESP32 + I2C device. We tested our firmware on 20 prototypes without encountering any problem.

We launched this week a first production, and tested the final boards...and we are now encountering some strange problems with I2C communication (master with a close single slave):
- some boards work fine (100%),
- some boards do not work at all (I2C communication always fails),
- most of the board work randomly (typically 1/3 of the I2C write work, 2/3 fail..).
Nothing special to say... we tried I2C_0 and I2C_1 and have the same behaviour. We tried different bit rates without seeing any improvement.
Any idea/suggestion?
Thanks for your help
Francis

genedyne
Posts: 18
Joined: Wed Jun 06, 2018 12:47 pm

Re: Random I2C issue

Postby genedyne » Tue Dec 17, 2019 8:34 pm

Have you seen this issue?
This will only apply if you are running git-master esp-idf.
I'd also suggest you slap an oscilloscope on the signals & check for clean transistions on the clock & data. You might need to adjust the pullups if these signals are noisy. Reducing the clock speed can also help if this is the issue.

FrancisL
Posts: 21
Joined: Wed Jul 25, 2018 3:34 pm

Re: Random I2C issue

Postby FrancisL » Wed Dec 18, 2019 3:59 pm

Thanks for your answer. It seems that the problem was not at the ESP32 side (master) but within the slave device...
Everything works fine with the ESP32! Issue is closed.
Francis

Who is online

Users browsing this forum: No registered users and 162 guests