Pin2Code is a visual IoT pinout configurator and code generator. Select your microcontroller, add peripherals, get working code — no datasheet required.
Getting started takes under 60 seconds:
| MCU | Family | Voltage | Flash | WiFi/BT |
|---|---|---|---|---|
| ESP32-WROOM-32 | ESP32 | 3.3V | 4MB | ✓ Both |
| STM32F103C8 | STM32 | 3.3V | 128KB | — |
| ATmega328P | AVR | 5V | 32KB | — |
| RP2040 | Raspberry Pi | 3.3V | 2MB | — |
| Raspberry Pi 4B | Raspberry Pi | 3.3V/5V | SD Card | ✓ Both |
| Raspberry Pi Pico 2W | Raspberry Pi | 3.3V | 4MB | ✓ Both |
DHT22 — Temperature & Humidity (1-Wire)DS18B20 — Digital Temperature (1-Wire)BME280 — Pressure, Humidity, Temperature (I2C)MPU-6050 — 6-axis IMU (I2C)HC-SR04 — Ultrasonic Distance (GPIO)MQ-2 — Gas Sensor (ADC)MAX30102 — Pulse Oximeter (I2C)SSD1306 — 128×64 OLED (I2C)LCD 16×2 — Character LCD via I2C backpackNEO-6M — GPS Module (UART)SIM800L — GSM Module (UART)RFM95W — LoRa 868/915MHz (SPI)TJA1050 — CAN Bus (CAN/TWAI)Blynk IoT — WiFi Cloud (built-in WiFi)LED — Single LED (GPIO)RGB LED — PWM colour controlServo Motor — PWM servo (up to ×4)Relay Module — 5V relay (GPIO)WS2812B — NeoPixel addressable LEDsULN2003 — Stepper motor driver (GPIO)The pin map shows your MCU chip with all pins rendered on left and right sides. Each pin is colour-coded by its protocol type:
Click any pin to see its full alternate function table in the detail panel.
Pin2Code automatically detects two types of conflicts:
Conflicts appear in the Conflicts tab with the bus name, affected peripherals, and a suggested fix. Note: Multiple I2C sensors on the same bus is valid (they