Use this forum to chat about hardware specific topics for the ESP8266 (peripherals, memory, clocks, JTAG, programming)

User avatar
By Dziastis
#56599 Hello!

I'm new to ESP8266 and I encountered one problem when trying out OLED display:
I can not figure out, which pin's of ESP-12 module are used for I2C when connecting OLED display and programming in ESP8266basic...
Could anyone help me?
Display is working (tested with Arduino example's).

Thanks in advance.
User avatar
By trackerj
#56620 From ESPBasic Version 3.0 Alpha 43 you have also the i2c.setup function available so you can use any GPIO you want and is free, but I recommend you GPIO4 and 5 for SDA/SCL.

i2c.setup():
Will change the default pins for the I2C interface.
i2c.setup({SDA}, {SCL})

After connectiing the display and I2C bus setup you can run the I2C scanbus to see if all OK.

More details in the related I2C setup and scanbus post

I2C scanbus results example in browser :

Image
User avatar
By Dziastis
#56652 Oh I can use i2c.setup in order to change pin's for oled functions :o
Didn't realise myself that those functions could be used together :roll:
Now display is working, thank's very much ;)