

The ESP32 LOLIN S2 Mini is a compact microcontroller board based on the ESP32-S2 chip. It is designed for Internet of Things (IoT) applications, offering built-in Wi-Fi and Bluetooth capabilities. With its small form factor, multiple GPIO pins, and support for various sensors and peripherals, the ESP32 LOLIN S2 Mini is ideal for projects requiring wireless connectivity and efficient processing power.








The ESP32 LOLIN S2 Mini features a total of 27 GPIO pins, which can be configured for various functions. Below is the pinout description:
| Pin | Name | Function |
|---|---|---|
| 1 | 3V3 | 3.3V power output |
| 2 | GND | Ground |
| 3 | GPIO0 | General-purpose I/O, boot mode selection |
| 4 | GPIO1 | General-purpose I/O, UART TX |
| 5 | GPIO2 | General-purpose I/O, ADC, PWM |
| 6 | GPIO3 | General-purpose I/O, UART RX |
| 7 | GPIO4 | General-purpose I/O, ADC, PWM |
| 8 | GPIO5 | General-purpose I/O, ADC, PWM |
| 9 | GPIO6 | General-purpose I/O, SPI CLK |
| 10 | GPIO7 | General-purpose I/O, SPI MISO |
| 11 | GPIO8 | General-purpose I/O, SPI MOSI |
| 12 | GPIO9 | General-purpose I/O, SPI CS |
| 13 | GPIO10 | General-purpose I/O, ADC, PWM |
| 14 | GPIO11 | General-purpose I/O, ADC, PWM |
| 15 | GPIO12 | General-purpose I/O, ADC, PWM |
| 16 | GPIO13 | General-purpose I/O, ADC, PWM |
| 17 | GPIO14 | General-purpose I/O, ADC, PWM |
| 18 | GPIO15 | General-purpose I/O, ADC, PWM |
| 19 | GPIO16 | General-purpose I/O, ADC, PWM |
| 20 | GPIO17 | General-purpose I/O, ADC, PWM |
| 21 | GPIO18 | General-purpose I/O, ADC, PWM |
| 22 | GPIO19 | General-purpose I/O, ADC, PWM |
| 23 | GPIO20 | General-purpose I/O, ADC, PWM |
| 24 | GPIO21 | General-purpose I/O, ADC, PWM |
| 25 | GPIO22 | General-purpose I/O, ADC, PWM |
| 26 | GPIO23 | General-purpose I/O, ADC, PWM |
| 27 | GPIO24 | General-purpose I/O, ADC, PWM |
Powering the Board:
Programming the Board:
https://dl.espressif.com/dl/package_esp32_index.json. Connecting Peripherals:
Wi-Fi Configuration:
#include <WiFi.h>
// Replace with your network credentials
const char* ssid = "Your_SSID";
const char* password = "Your_PASSWORD";
void setup() {
Serial.begin(115200); // Initialize serial communication at 115200 baud
WiFi.begin(ssid, password); // Start Wi-Fi connection
Serial.print("Connecting to Wi-Fi");
while (WiFi.status() != WL_CONNECTED) {
delay(500); // Wait for connection
Serial.print(".");
}
Serial.println("\nConnected to Wi-Fi!");
Serial.print("IP Address: ");
Serial.println(WiFi.localIP()); // Print the assigned IP address
}
void loop() {
// Add your main code here
}
The board is not detected by the computer:
Wi-Fi connection fails:
GPIO pins not working as expected:
Code upload fails:
Can I use the ESP32 LOLIN S2 Mini with 5V sensors?
No, the GPIO pins operate at 3.3V logic. Use a level shifter for 5V sensors.
Does the ESP32 LOLIN S2 Mini support Bluetooth?
No, the ESP32-S2 chip does not include Bluetooth functionality.
What is the maximum current output of the 3V3 pin?
The 3V3 pin can supply up to 500 mA, depending on the power source.
Can I use the ESP32 LOLIN S2 Mini for battery-powered projects?
Yes, but you will need an external battery management circuit as the board does not include one.