I2C & Spi Pins - Adafruit Feather HUZZAH ESP8266 Manual

Table of Contents

Advertisement

I2C & SPI pins
You can use the ESP8266 to control I2C and SPI devices, sensors, outputs, etc. While
this is done by 'bitbanging', it works quite well and the ESP8266 is fast enough to
match 'Arduino level' speeds.
In theory you can use any pins for I2C and SPI but to make it easier for people using
existing Arduino code, libraries, sketches we set up the following:
I2C SDA = GPIO #4 (default)
I2C SCL = GPIO #5 (default)
If you want, you can connect to I2C devices using other 2 pins in the Arduino IDE, by
calling
Wire.pins(sda, scl)
the begining of
setup()
Likewise, you can use SPI on any pins but if you end up using 'hardware SPI' you will
want to use the following:
SPI SCK = GPIO #14 (default)
SPI MOSI = GPIO #13 (default)
SPI MISO = GPIO #12 (default)
©Adafruit Industries
before any other Wire code is called (so, do this at
for example
Page 11 of 53

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the Feather HUZZAH ESP8266 and is the answer not in the manual?

Subscribe to Our Youtube Channel

Table of Contents