LOLIN S2 Mini
by Wemos
Compact ESP32-S2 board by Wemos with USB-C in a small castellated form factor - great for space-saving embedded builds.

On this page
Pinout
30 pins · 2.54 mm pitch| Pin | GPIO | Labels | Status | Capabilities | Notes |
|---|---|---|---|---|---|
| 1 | - | 5V | power | - | 5V power input for the board |
| 2 | - | GND | ground | - | Ground connection |
| 3 | - | 3V33.3V | power | - | 3.3V power output |
| 4 | 1 | IO1GPIO1 | safe | - | GPIO |
| 5 | 2 | IO2GPIO2 | safe | adc | GPIO, ADC |
| 6 | 3 | IO3GPIO3 | safe | - | GPIO |
| 7 | 4 | IO4GPIO4 | safe | adc | GPIO, ADC |
| 8 | 5 | IO5GPIO5 | safe | - | GPIO |
| 9 | 6 | IO6GPIO5 | safe | - | GPIO |
| 10 | 7 | IO7GPIO5 | safe | - | GPIO |
| 11 | 8 | IO8GPIO5 | safe | - | GPIO |
| 12 | 9 | IO9GPIO5 | strapping | - | GPIO |
| 13 | 10 | IO10GPIO5 | strapping | - | GPIO |
| 14 | 11 | IO11GPIO5 | strapping | - | GPIO |
| 15 | 12 | IO12GPIO12 | strapping | adc | GPIO, ADC |
| 16 | 13 | IO13GPIO13 | strapping | adc | GPIO, ADC |
| 17 | 14 | IO14GPIO14 | strapping | adc | GPIO, ADC |
| 18 | 15 | IO15GPIO15 | strapping | adc | GPIO, ADC |
| 19 | 16 | IO16GPIO16 | strapping | - | GPIO |
| 20 | 17 | IO17GPIO17 | safe | - | GPIO |
| 21 | 18 | IO18GPIO18 | safe | - | GPIO |
| 22 | 21 | IO21GPIO21 | safe | - | GPIO |
| 23 | 33 | IO33GPIO33 | strapping | adc | GPIO, ADC |
| 24 | 34 | IO34GPIO34 | strapping | adc | GPIO, ADC |
| 25 | 35 | IO35GPIO35 | strapping | adc | GPIO, ADC |
| 26 | 36 | IO36GPIO36 | strapping | adc | GPIO, ADC |
| 27 | 37 | IO37GPIO37 | strapping | adc | GPIO, ADC |
| 28 | 38 | IO38GPIO38 | strapping | adc | GPIO, ADC |
| 29 | 39 | IO39GPIO39 | strapping | adc | GPIO, ADC |
| 30 | 40 | IO40GPIO40 | strapping | adc | GPIO, ADC |
Start with these
11 pins with no boot or system involvementFreely assignable - no strapping, flash, USB or JTAG duties. Ideal first picks for buttons, sensors and LEDs.
Fine - with a little care
sampled at boot or shared with debug/serial| Pin | Label | What to know | Role |
|---|---|---|---|
| IO15 | XTAL_32K_P | If an external 32 kHz crystal is used for RTC, this pin is dedicated to the crystal and cannot be used as GPIO. | Other |
| IO16 | XTAL_32K_N | If using an external 32 kHz crystal, this pin is connected to the crystal and should not be used as general I/O. | Other |
| IO39 | MTCK | Used for JTAG debugging interface; using this pin for other purposes will disable JTAG clock input. | Other |
| IO40 | MTDO | Part of JTAG interface (TDO); should be avoided as GPIO if JTAG debugging is needed. | Other |
Only if you know the tricks
wired to flash or USB - expect a fight| Pin | Label | What to know | Role |
|---|---|---|---|
| IO9 | FSPIHD | Typically used as flash/PSRAM IO line in certain configurations; avoid using as GPIO if flash or PSRAM is present. | Flash |
| IO10 | FSPICS0 | Often used as flash chip select in some designs; not available for GPIO when controlling flash. | Flash |
| IO11 | FSPID | Used for flash data transfer in certain configurations; should be avoided for general use if flash is connected. | Flash |
| IO12 | FSPICLK | Used as flash clock line in some boards; not free for GPIO if driving flash. | Flash |
| IO13 | FSPIQ | Used for flash data output in certain configurations; avoid using as GPIO if connected to flash. | Flash |
| IO14 | FSPIWP | Used as flash write-protect/data line on some modules; not recommended for other usage. | Flash |
| IO33 | SPIHD | Connected to SPI flash (hold/data line); not available for general-purpose use. | Flash |
| IO34 | SPIWP | Connected to SPI flash (write-protect/data line); not recommended for other use. | Flash |
| IO35 | FSPID | Used by internal flash/PSRAM on some ESP32-S2 variants; avoid using as GPIO to prevent conflicts. | Flash |
| IO36 | FSPICLK | May be connected to internal flash or used for high-speed SPI; not intended for general GPIO use. | Flash |
| IO37 | FSPIQ | Used for internal flash/PSRAM data in some models; should not be repurposed for GPIO. | Flash |
| IO38 | FSPIWP | Reserved for flash/PSRAM in ESP32-S2 modules with internal memory; not recommended for general I/O. | Flash |
Pinout notes The LOLIN S2 Mini pinout brings out 30 pins at a 2.54 mm pitch - 27 usable GPIO alongside the 5V , GND and 3V3 power rails. On the analog side there are 14…
The LOLIN S2 Mini pinout brings out 30 pins at a 2.54 mm pitch - 27 usable GPIO alongside the 5V, GND and 3V3 power rails.
On the analog side there are 14 ADC-capable pins for sensors and battery monitoring.
If you want zero surprises, IO1, IO2, IO3, IO4 and 7 more are free of any such role - the safest first picks. 4 of the exposed pins carry boot-time or system duties on the ESP32-S2 (IO15, IO16, IO39 and 1 more).
Getting started
flash your first firmware in ~2 minutesBoard: Lolin S2 Mini
USB CDC On Boot: Enabled
Flash Size: 4MB · DIO
Upload Speed: 921600
// blink
pinMode(1, OUTPUT);
digitalWrite(1, LOW); // on (often inverted)[env:lolin_s2_mini]
platform = espressif32
board = esp32-s2-saola-1
framework = arduino
monitor_speed = 115200
upload_speed = 921600esp32:
board: esp32-s2-saola-1
variant: lolin_s2_mini
framework:
type: esp-idf
# blink - GPIO1
output:
- platform: gpio
pin: 1
id: led_out
light:
- platform: binary
name: "LED"
output: led_outesptool.py --chip esp32s2 --port /dev/ttyACM0 \
write_flash 0x0 firmware.binSpecifications
ESP32-S2 · 34.3 × 25.4 mmAbout this board
At its core is the ESP32-S2 - a single-core Xtensa with native USB-OTG and no Bluetooth.
Expect to pay about $5.00 - less than the ~$20 most ESP32-S2 boards go for.
Onboard you'll find 2MB PSRAM, status LEDs (Blue (GPIO15)) and Reset/Button (GPIO0) buttons.
It flashes over native USB - no serial-converter driver needed, which isn't a given among ESP32-S2 boards.
Where to buy
prices are typical street prices
Resources
Similar boards




