Notifications
Clear all

I2C ESP32 Arduino Question  


KeithL
(@keith)
Active Member
Joined: 11 months ago
Posts: 11
Topic starter  

I have an ESP32 connected to an Arduino Pro Mini via I2C. The ESP32 is the master and the Arduino is a slave.

The ESP32 is set up to request information from the Arduino and everything works okay.

My question is: As the ESP32 is 3.3v and the Arduino 5v, should I have a voltage level shifter on one, or both, of the I2C lines?

Although everything works okay at the moment I don't want to be slowly damaging the ESP32 with too much voltage.


Quote
byron
(@byron)
Reputable Member
Joined: 2 years ago
Posts: 389
 

@keith - there is a dronbot video on this sort of thing where an arduino 5v logic is connected to a rpi 3.3v logic, so similar considerations for your use case.  Have a search on the youtube and you will find it.


ReplyQuote
KeithL
(@keith)
Active Member
Joined: 11 months ago
Posts: 11
Topic starter  

@byron - Well that was easy. I just watched the video and it would seem that my setup is fine as it is.

Thanks for pointing me in the right direction.


ReplyQuote
MadMisha
(@madmisha)
Eminent Member
Joined: 11 months ago
Posts: 44
 

Keep in mind that the documentation for ESP32 is a little hazy on if it can take 5V logic. Some people say it can and some say you shouldn't.


ReplyQuote
Duce robot
(@duce-robot)
Honorable Member
Joined: 2 years ago
Posts: 502
 

Logic level converter bi directional should work .


ReplyQuote
DroneBot Workshop
(@dronebot-workshop)
Workshop Guru Admin
Joined: 2 years ago
Posts: 856
 
Posted by: @madmisha

Keep in mind that the documentation for ESP32 is a little hazy on if it can take 5V logic. Some people say it can and some say you shouldn't.

Yes, it's a common discussion on the ESP32 forum.

Posted by: @duce-robot

Logic level converter bi directional should work .

Agreed! It's the Data line in this situation that is the problem, as the ESP32 is the master in your configuration the clock signal is fine.  And the keyword in @duce-robot comment is "bidirectional", as the data needs to travel both ways.

😎

Bill

"Never trust a computer you can’t throw out a window." — Steve Wozniak


Robert T. liked
ReplyQuote