Chat freely about anything...

User avatar
By Bilbub
#86561 Hello guys! I’m bilbub... i’m a newbie to the esp01...i tried to do some i2c communication where my esp01 as master and mega as slave...the slave coding is working but the master code for esp01 is not working...for the esp01, i selected the generic module esp8266 as board...i would like to know how the connection between esp01 to arduino mega...

Attached here some pic and coding error
Attachments
49E74EC1-2ED4-42D6-8136-5EC7B9430C6B.jpeg
Pic of hardware circuit
BEEDEADE-87AA-462C-95CE-4FDFC710CE41.jpeg
Port error
User avatar
By eriksl
#86582 I think you will need to give some more information. Although the (standard) I2C implementation by Espressif is horrible, I think it should be able to be working.

Is the hardware okay (i.e. did you apply pull-up resistors)? I see you're using ESP01, that means you'll have to use either one of GPIO 0, 1, 2 or 3. All of these will spew some "garbage" during startup, your I2C slave should be able to cope with that.

What are you using on the ESP01 as base, the NON-OS SDK, the RTOS SDK or some other framework (like Arduino). If the latter, you'd better ask the question in a relevant subforum.