Guide
ESP32-S2 Mini Pinout
The complete pin reference for the WEMOS/Lolin S2 Mini: native USB, 14 capacitive touch pins, and no Bluetooth at all.
- Single-core Xtensa LX7
- Wi-Fi only, no Bluetooth
- 29 broken-out GPIOs
- Native USB
Overview
The S2 Mini is a compact ESP32-S2 development board made by WEMOS/Lolin, with onboard USB-C, a reset button, a 3.3V regulator, and 29 accessible GPIOs across two header rows. The ESP32-S2 is Espressif’s Wi-Fi-only chip, no Bluetooth, no 802.15.4, which makes it a good fit for USB-powered sensors and gadgets that don’t need a second radio.
No Bluetooth badge here on purpose: unlike every other chip in these guides, the ESP32-S2 genuinely has no Bluetooth radio at all, not even BLE.
Getting started
The S2 Mini uses the chip’s native USB peripheral directly, not a separate USB-to-serial chip, so no extra USB driver is usually needed on modern operating systems.
Hello World: blink an LED
The microcontroller equivalent of “Hello World”: GPIO21 toggles once a second, shown here in two different environments. Wire an LED (with a resistor) to GPIO21, a plain general-purpose pin with no other job on this board.
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
#include "driver/gpio.h"
#define LED_PIN GPIO_NUM_21
void app_main(void)
{
gpio_reset_pin(LED_PIN);
gpio_set_direction(LED_PIN, GPIO_MODE_OUTPUT);
while (1) {
gpio_set_level(LED_PIN, 1);
vTaskDelay(pdMS_TO_TICKS(1000));
gpio_set_level(LED_PIN, 0);
vTaskDelay(pdMS_TO_TICKS(1000));
}
}
#define LED_PIN 21
void setup() {
pinMode(LED_PIN, OUTPUT);
}
void loop() {
digitalWrite(LED_PIN, HIGH);
delay(1000);
digitalWrite(LED_PIN, LOW);
delay(1000);
}
ESP-IDF: build and flash with idf.py build flash monitor. Arduino IDE: install ESP32 board support first, see “Getting started” above.
Specifications
Official specifications for the ESP32-S2 chip and the S2 Mini board.
Compute
| Chip | ESP32-S2 |
| CPU | Single-core Xtensa LX7, up to 240 MHz |
| Flash | 4 MB (varies by revision) |
Radio
| Wi-Fi | 802.11 b/g/n, 2.4 GHz |
| Bluetooth | None |
| USB | Native USB 1.1 (device and host) |
Physical
| Operating voltage | 3.3V |
| GPIOs | 43 total, 29 broken out |
| Touch pins | 14 |
| ADC | 2 × 12-bit, up to 20 channels |
Pinout diagram
The full S2 Mini layout, including the alternate ADC1/ADC2/touch/JTAG functions on each pin.
GPIO quick reference
GPIO19 and GPIO20 are the chip’s native USB D+/D− pins and aren’t broken out on this board, they’re not listed below.
| GPIO | Special function | ADC | DAC | Touch | Boot state |
|---|---|---|---|---|---|
| 0 | Strapping (BOOT) | — | No | Yes | Strapping |
| 1 | Touch1 | ADC1_0 | No | Yes | Free |
| 2 | Touch2 | ADC1_1 | No | Yes | Free |
| 3 | Touch3 | ADC1_2 | No | Yes | Free |
| 4 | Touch4 | ADC1_3 | No | Yes | Free |
| 5 | Touch5 | ADC1_4 | No | Yes | Free |
| 6 | Touch6 | ADC1_5 | No | Yes | Free |
| 7 | Touch7 | ADC1_6 | No | Yes | Free |
| 8 | Touch8, I2C SDA (common default) | ADC1_7 | No | Yes | Free |
| 9 | Touch9, I2C SCL (common default) | ADC1_8 | No | Yes | Free |
| 10 | Touch10 | ADC2_0 | No | Yes | Free |
| 11 | Touch11 | ADC2_1 | No | Yes | Free |
| 12 | Touch12 | ADC2_2 | No | Yes | Free |
| 13 | Touch13 | ADC2_3 | No | Yes | Free |
| 14 | Touch14 | ADC2_4 | No | Yes | Free |
| 15 | Onboard LED, XTAL_32K_P | — | No | No | Free |
| 16 | XTAL_32K_N | — | No | No | Free |
| 17 | — | ADC2_6 | Yes (DAC1) | No | Free |
| 18 | — | ADC2_7 | Yes (DAC2) | No | Free |
| 21 | — | — | No | No | Free |
| 33 | — | — | No | No | Free |
| 34 | SPI CS (default) | — | No | No | Free |
| 35 | SPI MOSI (default) | — | No | No | Free |
| 36 | SPI CLK (default) | — | No | No | Free |
| 37 | SPI MISO (default) | — | No | No | Free |
| 38 | — | — | No | No | Free |
| 39 | JTAG MTCK | — | No | No | Free |
| 40 | JTAG MTDO | — | No | No | Free |
Flashing pins
The S2 Mini flashes over its native USB port, not a separate UART bridge, so there’s no TXD0/RXD0 pin pair to route externally.
| Function | Pin | Description |
|---|---|---|
| EN | EN pin | Resets the board |
| IO0 | GPIO0 | Hold low to enter the bootloader |
Safety notes
Before you wire anything up
- GPIO0 is a strapping pin, check its boot-time state before using it as an output.
- GPIO19 and GPIO20 are reserved for native USB internally, not exposed on this board.
- This board runs at 3.3V logic, a 5V signal on any pin can damage the chip.
- Don’t assume Bluetooth is available, this chip genuinely has none, unlike most other ESP32 variants.
More guides
Keep building.
From ESP32 HomeKit accessories to Arduino and ATtiny reference guides, there’s more where this came from.
All guides