Skip to content

ESP8266 ESP32 Compatibility

Rene K. Mueller edited this page Feb 18, 2018 · 18 revisions

This document reflects conflicts between NodeMCU/ESP8266 and NodeMCU/ESP32 and requirements to achieve larger degree of compatibility:

adc

bit

bthci

can

dht

file

gpio

ESP8266:

  • gpio.mode()
    • gpio.INPUT
    • gpio.OUTPUT
    • gpio.OPENDRAIN
    • gpio.INT
  • gpio.trig(pin,type,callback(level,when))
    • types: "up", "down", "both", "low", "high"

ESP32:

  • gpio.config({gpio=..,dir=..,pull=..,opendrain=..})

    • dir:
      • gpio.IN
      • gpio.OUT
      • gpio.IN_OUT
    • pull:
      • gpio.FLOATING disables both pull-up and -down
      • gpio.PULL_UP enables pull-up and disables pull-down
      • gpio.PULL_DOWN enables pull-down and disables pull-up
      • gpio.PULL_UP_DOWN enables both pull-up and -down
  • gpio.trig(pin,types,callback(pin,level))

    • types:
      • gpio.INTR_UP for trigger on rising edge
      • gpio.INTR_DOWN for trigger on falling edge
      • gpio.INTR_UP_DOWN for trigger on both edges
      • gpio.INTR_LOW for trigger on low level
      • gpio.INTR_HIGH for trigger on high level

i2c

ledc

net

node

ESP8266:

  • node.info()
  • node.chipid() return integer (last 3 bytes of the station MAC address)

ESP32:

  • node.info() missing
  • node.chipid() returns string with '0x' as prefix and 8 bytes whereas the last byte is of the MAC address is dropped (risk of 255 identical chipids)

ow (1-Wire)

sdmmc

sigma delta

spi

struct

tmr

u8g2

u8g2 Display

uart

wifi

ws2812

Clone this wiki locally