# A lot of information was taking from here: https://www.espressif.com/sites/default/files/documentation/esp32_technical_reference_manual_en.pdf GPIO | Input | Output | PWM | ADC* | DAC | UART | I2C | SPI | RTC** | TOUCH*** | HALL SENS**** | Notes 0 | PULLED UP | OK | OK | ADC2 | --- | --- | --- | --- | OK | T1 | --- | outputs PWM signal at boot 1 | TX PIN | OK | OK | --- | --- | 0 TX | --- | --- | --- | --- | --- | debug output at boot 2 | OK | OK | OK | ADC2 | --- | --- | --- | --- | OK | T2 | --- | connected to on-board LED 3 | OK | RX PIN | OK | --- | --- | 0 RX | --- | --- | --- | --- | --- | HIGH at boot 4 | OK | OK | OK | ADC2 | --- | --- | --- | --- | OK | T0 | --- | 5 | OK | OK | OK | --- | --- | --- | --- | V CSO | --- | --- | --- | outputs PWM signal at boot 6 | x | x | x | x | --- | --- | --- | --- | --- | --- | --- | connected to the integrated SPI flash 7 | x | x | x | x | --- | --- | --- | --- | --- | --- | --- | connected to the integrated SPI flash 8 | x | x | x | x | --- | --- | --- | --- | --- | --- | --- | connected to the integrated SPI flash 9 | x | x | x | x | --- | --- | --- | --- | --- | --- | --- | connected to the integrated SPI flash 10 | x | x | x | x | --- | --- | --- | --- | --- | --- | --- | connected to the integrated SPI flash 11 | x | x | x | x | --- | --- | --- | --- | --- | --- | --- | connected to the integrated SPI flash 12 | OK | OK | OK | ADC2 | --- | --- | --- | H MISO | OK | T5 | --- | boot fail if pulled high 13 | OK | OK | OK | ADC2 | --- | --- | --- | H MOSI | OK | T4 | --- | 14 | OK | OK | OK | ADC2 | --- | --- | --- | H CLK | OK | T6 | --- | outputs PWM signal at boot 15 | OK | OK | OK | ADC2 | --- | --- | --- | H CSO | OK | T3 | --- | outputs PWM signal at boot 16 | OK | OK | OK | --- | --- | 2 RX | --- | --- | --- | --- | --- | 17 | OK | OK | OK | --- | --- | 2 TX | --- | --- | --- | --- | --- | 18 | OK | OK | OK | --- | --- | --- | --- | V CLK | --- | --- | --- | 19 | OK | OK | OK | --- | --- | --- | --- | V MISO | --- | --- | --- | 21 | OK | OK | OK | --- | --- | --- | SDA | --- | --- | --- | --- | 22 | OK | OK | OK | --- | --- | --- | SCL | --- | --- | --- | --- | 23 | OK | OK | OK | --- | --- | --- | --- | V MOSI | --- | --- | --- | 25 | OK | OK | OK | ADC2 | DAC1 | --- | --- | --- | OK | --- | --- | 26 | OK | OK | OK | ADC2 | DAC2 | --- | --- | --- | OK | --- | --- | 27 | OK | OK | OK | ADC2 | --- | --- | --- | --- | OK | T7 | --- | 32 | OK | OK | OK | ADC1 | --- | --- | --- | --- | OK | T9 | --- | 33 | OK | OK | OK | ADC1 | --- | --- | --- | --- | OK | T8 | --- | 34 | OK | --- | --- | ADC1 | --- | --- | --- | --- | OK | --- | --- | don’t have internal pull-up/pull-down resistor 35 | OK | --- | --- | ADC1 | --- | --- | --- | --- | OK | --- | --- | don’t have internal pull-up/pull-down resistor 36 | OK | --- | --- | ADC1 | --- | --- | --- | --- | OK | --- | SENSOR VP | don’t have internal pull-up/pull-down resistor 39 | OK | --- | --- | ADC1 | --- | --- | --- | --- | OK | --- | SENSOR VN | don’t have internal pull-up/pull-down resistor * - You can only use analog inputs on ADC1 once WiFi has started! ** - There is RTC GPIO support on the ESP32. The GPIOs routed to the RTC low-power subsystem can be used when the ESP32 is in deep sleep. These RTC GPIOs can be used to wake up the ESP32 from deep sleep when the Ultra Low Power (ULP) co-processor is running. The following GPIOs can be used as an external wake up source. *** - The ESP32 has 10 internal capacitive touch sensors. These can sense variations in anything that holds an electrical charge, like the human skin. So they can detect variations induced when touching the GPIOs with a finger. These pins can be easily integrated into capacitive pads, and replace mechanical buttons. The capacitive touch pins can also be used to wake up the ESP32 from deep sleep. **** - The Hall sensor converts the magnetic field into voltage, feeds it into an amplifier, and then outputs it through pin SENSOR_VP and pin SENSOR_VN. ESP32’s built-in ADC converts the voltage into a digital value for processing by the CPU in the digital domain. The configuration of a Hall sensor for reading is done with registers SENS_SAR_TOUCH_CTRL1_REG and RTCIO_HALL_SENS_REG, which are used to power up the Hall sensor. The subsequent processing is done by SAR ADC1. The result is obtained from the RTC ADC1 controller. For more details, please refer to section 30.3