When you select "ESP32 Dev Module" in the Arduino IDE, you are not selecting a single physical board. You are selecting a generic board definition that maps to dozens of physical clones, primarily the 30-pin DevKit V1 and the 38-pin NodeMCU-32S. The most common baseline is the 30-pin ESP32-WROOM-32 DevKit V1. Below is the exact physical pinout and GPIO capability map for this standard, followed by critical hardware variants and wiring standards.
1. The Master ESP32 Dev Module Pinout Table (30-Pin DevKit V1)
This table maps the physical header pins (left and right sides, USB port facing down) to the internal ESP32-WROOM-32 GPIO numbers and their specific peripheral capabilities. Use this as your primary bench reference.
| Physical Pin | GPIO | Name | Capabilities | Bench Notes & Constraints |
|---|---|---|---|---|
| Left 1 | 3V3 | 3V3 | Power | Output from onboard regulator. Max draw ~500mA. |
| Left 2 | GPIO 36 | VP | Input, ADC1, RTC | Input ONLY. No internal pull-up/pull-down. |
| Left 3 | GPIO 39 | VN | Input, ADC1, RTC | Input ONLY. No internal pull-up/pull-down. |
| Left 4 | GPIO 34 | D34 | Input, ADC1, RTC | Input ONLY. No internal pull-up/pull-down. |
| Left 5 | GPIO 35 | D35 | Input, ADC1, RTC | Input ONLY. No internal pull-up/pull-down. |
| Left 6 | GPIO 32 | D32 | I/O, ADC1, Touch9, RTC | Safe for general use. ADC1 works with WiFi. |
| Left 7 | GPIO 33 | D33 | I/O, ADC1, Touch8, RTC | Safe for general use. ADC1 works with WiFi. |
| Left 8 | GPIO 25 | D25 | I/O, ADC2, DAC1, RTC | Warning: ADC2 fails if WiFi is active. |
| Left 9 | GPIO 26 | D26 | I/O, ADC2, DAC2, RTC | Warning: ADC2 fails if WiFi is active. |
| Left 10 | GPIO 27 | D27 | I/O, ADC2, Touch7, RTC | Warning: ADC2 fails if WiFi is active. |
| Left 11 | GPIO 14 | D14 | I/O, ADC2, Touch6, RTC | Outputs PWM at boot. ADC2 fails with WiFi. |
| Left 12 | GPIO 12 | D12 | I/O, ADC2, Touch5, RTC | Strapping Pin. Boot fails if pulled HIGH. |
| Left 13 | GND | GND | Ground | Common ground reference. |
| Left 14 | GPIO 13 | D13 | I/O, ADC2, Touch4, RTC | ADC2 fails if WiFi is active. |
| Left 15 | GPIO 15 | D15 | I/O, ADC2, Touch3, RTC | Strapping Pin. Outputs PWM at boot. |
| Right 1 | GPIO 23 | D23 | I/O, HSPI | Safe for general use. Common for SPI MOSI. |
| Right 2 | GPIO 22 | D22 | I/O, VSPI | Safe for general use. Common for I2C SCL. |
| Right 3 | GPIO 1 | TX0 | I/O, U0TXD | Debug TX. Outputs boot log at 115200 baud. |
| Right 4 | GPIO 3 | RX0 | I/O, U0RXD | Debug RX. Used for serial flashing. |
| Right 5 | GPIO 21 | D21 | I/O, VSPI | Safe for general use. Common for I2C SDA. |
| Right 6 | GND | GND | Ground | Common ground reference. |
| Right 7 | GPIO 19 | D19 | I/O, HSPI | Safe for general use. Common for SPI MISO. |
| Right 8 | GPIO 18 | D18 | I/O, VSPI | Safe for general use. Common for SPI SCK. |
| Right 9 | GPIO 5 | D5 | I/O, VSPI | Safe for general use. Common for SPI SS. |
| Right 10 | GPIO 17 | TX2 | I/O, U2TXD | Safe for general UART. (N/A on WROVER). |
| Right 11 | GPIO 16 | RX2 | I/O, U2RXD | Safe for general UART. (N/A on WROVER). |
| Right 12 | GPIO 4 | D4 | I/O, ADC2, Touch0 | ADC2 fails if WiFi is active. |
| Right 13 | GPIO 0 | D0 | I/O, ADC2, Touch1 | Strapping Pin. Must be LOW to flash. |
| Right 14 | GPIO 2 | D2 | I/O, ADC2, Touch2 | Strapping Pin. Must be floating/LOW to boot. |
| Right 15 | 5V | VIN | Power | 5V input to regulator, or 5V output from USB. |
Rows People Get Wrong: Strapping Pins and ADC2
The most common bench failures with the ESP32 come from misinterpreting three specific rows in the table above:
- The ADC2 / WiFi Conflict: Pins mapped to ADC2 (GPIO 0, 2, 4, 12, 13, 14, 15, 25, 26, 27) share hardware resources with the WiFi radio. If your sketch initializes
WiFi.begin(), anyanalogRead()calls on these pins will fail and return garbage data. Fix: Always use ADC1 pins (GPIO 32-39) for analog sensors in IoT projects. - GPIO 12 (The Boot Killer): GPIO 12 is a strapping pin that determines the flash voltage. If an external circuit pulls GPIO 12 HIGH during power-on, the ESP32 expects a 1.8V SPI flash chip. Since 99% of DevKit modules use 3.3V flash, the boot will fail with a continuous reset loop. Fix: Never use GPIO 12 for inputs with external pull-up resistors.
- GPIO 34-39 (Input Only): These pins lack output drivers and internal pull-up/pull-down resistors. If you try to use them with a push-button, you must provide an external 10kΩ pull-up resistor to 3.3V.
2. Hardware Variants and DC Wiring Color Standards
The "Dev Module" definition covers multiple physical layouts. Before wiring external sensors, you must identify your physical variant and apply the correct DC wiring color standards for your region.
| Feature | DevKit V1 (30-Pin) | NodeMCU-32S (38-Pin) | ESP32-WROVER DevKit |
|---|---|---|---|
| Physical Headers | 2 x 15 pins (Breadboard friendly) | 2 x 19 pins (Blocks adjacent breadboard rows) | 2 x 18 pins (Often wider board) |
| Module Type | ESP32-WROOM-32 (No PSRAM) | ESP32-WROOM-32 (No PSRAM) | ESP32-WROVER (Includes 4MB/8MB PSRAM) |
| GPIO 16 & 17 | Available for UART2 / General I/O | Available for UART2 / General I/O | Unavailable. Reserved for internal PSRAM. |
| USB-UART Chip | Usually CP2102 or CH340 | Usually CP2102 | Usually CP2102 |
Despite the 5V (VIN) pin on the header, the ESP32 silicon is strictly 3.3V logic. Feeding 5V into any GPIO pin (like RX, TX, or ADC inputs) will degrade the silicon over time due to latch-up, even if it appears to function initially. Always use a logic level shifter (like a BSS138 MOSFET bidirectional shifter) or a simple resistor voltage divider when interfacing with 5V sensors like the HC-SR04 ultrasonic module.
DC Sensor Wiring Color Codes: IEC vs. US/NEC
When wiring external 3.3V DC sensors to your ESP32, the wire colors you choose should match the standard recognized in your region to prevent catastrophic reverse-polarity faults on the bench.
- IEC 60446 (Europe / UK / International): For DC circuits, Brown is positive (3.3V), Blue is negative/ground (GND), and Green/Yellow is protective earth (not used on ESP32). Signal wires are typically Black or Grey.
- US / NEC Practice (North America): While the NEC primarily governs AC mains, standard US DC electronics practice uses Red for positive (3.3V/5V), Black for negative/ground (GND), and Yellow/White for signals.
Bench Rule: If you are mixing sensor modules from different regions, always verify the VCC/GND pinout on the sensor's silkscreen before applying power. Many cheap clone sensors swap the VCC and GND pins compared to the original Adafruit/SparkFun designs, which will instantly destroy the ESP32's 3.3V regulator.
3. Safe Interpretation When Silkscreen Markings Are Faded
Cheap clone boards from bulk AliExpress orders frequently suffer from faded, misaligned, or entirely missing silkscreen pin labels. If you cannot read the GPIO numbers on the PCB, do not guess. Use this systematic bench procedure to safely map the board.
Step 1: Identify Power and Ground via Continuity
Set your multimeter to continuity mode (the diode/beep setting). With the board unpowered:
- Touch the black probe to the metal shield of the USB connector (this is your known ground).
- Probe the header pins with the red probe. Any pin that beeps is a GND pin. On a 30-pin board, you should find exactly two GND pins (Left 13, Right 6).
- The pin directly adjacent to the GND pin on the outer edge is almost always the 5V (VIN) pin.
- The pin on the opposite outer edge is the 3V3 output.
Step 2: Map Unknown GPIOs via Software Toggling
Once power and ground are identified, plug the board into your PC. Upload the following "Pin Mapper" sketch. This code sequentially pulses every available GPIO HIGH for 2 seconds, allowing you to identify the physical pin using a logic probe, an LED with a 330Ω resistor, or a multimeter set to DC voltage.
// ESP32 Pin Mapper - Identifies physical pins via sequential 3.3V output
// Use a multimeter or LED+resistor to probe headers while this runs.
void setup() {
Serial.begin(115200);
Serial.println("ESP32 Pin Mapper Started. Probing pins...");
// Array of safe-to-test GPIOs (Excludes strapping/input-only pins)
int testPins[] = {4, 5, 13, 14, 15, 16, 17, 18, 19, 21, 22, 23, 25, 26, 27, 32, 33};
int pinCount = sizeof(testPins) / sizeof(testPins[0]);
for (int i = 0; i < pinCount; i++) {
pinMode(testPins[i], OUTPUT);
}
}
void loop() {
int testPins[] = {4, 5, 13, 14, 15, 16, 17, 18, 19, 21, 22, 23, 25, 26, 27, 32, 33};
int pinCount = sizeof(testPins) / sizeof(testPins[0]);
for (int i = 0; i < pinCount; i++) {
Serial.print("Pulsing GPIO ");
Serial.println(testPins[i]);
digitalWrite(testPins[i], HIGH);
delay(2000); // 2 seconds to probe the physical header
digitalWrite(testPins[i], LOW);
delay(500); // Brief gap between pins
}
Serial.println("Cycle complete. Restarting...");
delay(3000);
}
By combining the continuity test for power rails and the software toggling for data lines, you can reliably map any unmarked ESP32 clone without risking a short circuit. For deeper architectural details on the ESP32's internal multiplexing, always refer to the official Espressif ESP32 Datasheet and the community-maintained ESP32 GPIO Reference Guide.






