The Raspberry Pi Pico 2 keeps the original Pico's 40-pin layout and swaps the RP2040 for the newer RP2350: a 150 MHz chip with twice the RAM, twice the flash, a hardware floating-point unit, a third PIO block, and a choice of Arm or RISC-V cores. It has no Wi-Fi; that's the Pico 2 W.
Quick answer: the pinout is identical to the original Pico. GP0–GP22 and GP26–GP28 are usable (26 GPIOs); GP26, GP27, GP28 are the analog inputs (ADC0–2); the onboard LED is GP25. Every GPIO can do PWM, and I2C, SPI and UART can each be moved to several pin pairs. Logic is 3.3 V and not 5 V tolerant. Power it from USB or 1.8–5.5 V on VSYS (pin 39). RP2040 firmware won't run; flash a Pico 2 build.
Below: the full pin table with every bus option and PWM slice, power pins, the internal ADC channels, the GPIO erratum on early chips, and what changed from the RP2040.
Pico 2 Pin Table
Hold the board with the USB port at the top: pin 1 (GP0) is top left, pins run down the left side to 20, then up the right side from 21 to 40 (VBUS, top right). Ground pins sit at 3, 8, 13, 18, 23, 28, 33 (analog ground) and 38.
| Pin | GPIO | I2C | SPI | UART | PWM | Extra |
|---|---|---|---|---|---|---|
| 1 | GP0 | I2C0 SDA | SPI0 RX | UART0 TX | 0A | |
| 2 | GP1 | I2C0 SCL | SPI0 CSn | UART0 RX | 0B | |
| 4 | GP2 | I2C1 SDA | SPI0 SCK | 1A | ||
| 5 | GP3 | I2C1 SCL | SPI0 TX | 1B | ||
| 6 | GP4 | I2C0 SDA | SPI0 RX | UART1 TX | 2A | |
| 7 | GP5 | I2C0 SCL | SPI0 CSn | UART1 RX | 2B | |
| 9 | GP6 | I2C1 SDA | SPI0 SCK | 3A | ||
| 10 | GP7 | I2C1 SCL | SPI0 TX | 3B | ||
| 11 | GP8 | I2C0 SDA | SPI1 RX | UART1 TX | 4A | |
| 12 | GP9 | I2C0 SCL | SPI1 CSn | UART1 RX | 4B | |
| 14 | GP10 | I2C1 SDA | SPI1 SCK | 5A | ||
| 15 | GP11 | I2C1 SCL | SPI1 TX | 5B | ||
| 16 | GP12 | I2C0 SDA | SPI1 RX | UART0 TX | 6A | HSTX |
| 17 | GP13 | I2C0 SCL | SPI1 CSn | UART0 RX | 6B | HSTX |
| 19 | GP14 | I2C1 SDA | SPI1 SCK | 7A | HSTX | |
| 20 | GP15 | I2C1 SCL | SPI1 TX | 7B | HSTX | |
| 21 | GP16 | I2C0 SDA | SPI0 RX | UART0 TX | 0A | HSTX |
| 22 | GP17 | I2C0 SCL | SPI0 CSn | UART0 RX | 0B | HSTX |
| 24 | GP18 | I2C1 SDA | SPI0 SCK | 1A | HSTX | |
| 25 | GP19 | I2C1 SCL | SPI0 TX | 1B | HSTX | |
| 26 | GP20 | I2C0 SDA | SPI0 RX | UART1 TX | 2A | |
| 27 | GP21 | I2C0 SCL | SPI0 CSn | UART1 RX | 2B | |
| 29 | GP22 | I2C1 SDA | SPI0 SCK | 3A | ||
| 31 | GP26 | I2C1 SDA | SPI1 SCK | 5A | ADC0 | |
| 32 | GP27 | I2C1 SCL | SPI1 TX | 5B | ADC1 | |
| 34 | GP28 | I2C0 SDA | SPI1 RX | UART0 TX | 6A | ADC2 |
SPI RX is MISO and TX is MOSI. HSTX (GP12–GP19) is the RP2350's new high-speed serial transmit block, used for DVI/HDMI video output.
Three GPIOs are used on the board and aren't on the header: GP23 controls the power supply's mode, GP24 senses VBUS (USB connected), and GP25 is the onboard LED.
# MicroPython
from machine import Pin
from time import sleep
led = Pin(25, Pin.OUT) # Pin("LED") also works
while True:
led.toggle()
sleep(0.5)// Arduino (arduino-pico core)
void setup() { pinMode(LED_BUILTIN, OUTPUT); }
void loop() { digitalWrite(LED_BUILTIN, !digitalRead(LED_BUILTIN)); delay(500); }Reading the table: each bus can sit on several pin pairs, but a pin does one job at a time. MicroPython and the Arduino core let you choose, for example I2C(0, sda=Pin(16), scl=Pin(17)). Two pins with the same PWM letter and slice (GP0 and GP16 are both 0A) output the same signal, so pick PWM pins on different slices when they need different frequencies.
Power Pins
| Pin | Name | Use |
|---|---|---|
| 40 | VBUS | 5 V from USB, only when USB is connected |
| 39 | VSYS | Main power input, 1.8–5.5 V (batteries, external supply) |
| 37 | 3V3_EN | Pull LOW to switch the 3.3 V supply off |
| 36 | 3V3(OUT) | 3.3 V for sensors; keep the load under about 300 mA |
| 35 | ADC_VREF | ADC reference (3.3 V, filtered) |
| 33 | AGND | Analog ground for ADC sensors |
| 30 | RUN | Pull LOW to reset; wire a button to GND for a reset switch |
Battery or external power goes on VSYS, not VBUS. If you power from VSYS and USB at the same time, add a Schottky diode from your supply into VSYS so the two can't fight; the Pico datasheet shows the circuit. A single Li-ion cell (3.0–4.2 V), 3 × AA or a 5 V supply all work on VSYS.
Nothing on the board is 5 V tolerant. A 5 V sensor output needs a divider or level shifter before it reaches a GPIO.
Analog Inputs (ADC)
Three external channels on GP26, GP27, GP28, all 12-bit, 0–3.3 V. Two more are internal: ADC3 on GP29 reads VSYS through a 1:3 divider, and ADC4 is the chip's temperature sensor.
from machine import ADC
pot = ADC(26)
# GP26 = ADC0
vsys = ADC(29)
# internal VSYS/3
temp = ADC(4)
# internal temperature sensor
volts = pot.read_u16() * 3.3 / 65535
battery = vsys.read_u16() * 3 * 3.3 / 65535
t = 27 - (temp.read_u16() * 3.3 / 65535 - 0.706) / 0.001721
print(volts, battery, round(t, 1))For quieter readings, connect sensor grounds to AGND (pin 33), keep wires short and average a few samples. The internal temperature sensor measures the chip, not the room, and is only accurate to a few degrees. For more inputs, add an ADS1115 on I2C.
The RP2350 GPIO Erratum (E9)
Early RP2350 chips (the A2 stepping, on most Pico 2 boards sold in 2024 and early 2025) have a known pad fault, listed as RP2350-E9 in the datasheet. A GPIO set as an input with the internal pull-down enabled can stick at about 2 V after being driven high, so it keeps reading HIGH when it should read LOW.
It mainly affects buttons and sensors wired to 3.3 V with an internal pull-down. The workarounds are simple:
- Wire buttons to GND with the internal pull-up instead (
Pin(14, Pin.IN, Pin.PULL_UP), pressed reads 0). This is the best habit anyway. - If you need a pull-down, use an external resistor of 8.2 kΩ or less to GND.
Later chips (the A4 stepping) fix this. The stepping is printed on the chip.
I2C, SPI and UART Examples
Both I2C buses, both SPI buses and both UARTs can run at once. These defaults match most tutorials and the Pico SDK:
| Bus | Default pins (Pico SDK) |
|---|---|
| I2C0 | SDA GP4, SCL GP5 |
| SPI0 | RX GP16, CSn GP17, SCK GP18, TX GP19 |
| UART0 | TX GP0, RX GP1 |
from machine import I2C, SPI, UART, Pin
i2c = I2C(0, sda=Pin(4), scl=Pin(5), freq=400_000)
print([hex(a) for a in i2c.scan()]) # e.g. ['0x76'] for a BME280
spi = SPI(0, baudrate=10_000_000, sck=Pin(18), mosi=Pin(19), miso=Pin(16))
cs = Pin(17, Pin.OUT, value=1)
uart = UART(0, baudrate=9600, tx=Pin(0), rx=Pin(1))The board has no I2C pull-up resistors. Most breakout modules include them; a bare sensor chip needs 4.7 kΩ from SDA and SCL to 3.3 V.
In the Arduino IDE with the arduino-pico core, Serial is the USB port, Serial1 is UART0 on GP0/GP1, and Wire is I2C0 on GP4/GP5. Call Wire.setSDA(16); Wire.setSCL(17); before Wire.begin() to move it.
PWM
Every GPIO can output PWM. The RP2350 has 12 PWM slices (the RP2040 had 8), each with two channels, A and B, that share a frequency but can have different duty cycles. On the Pico 2 header, pins map onto slices 0–7 exactly as on the original Pico.
from machine import Pin, PWM
servo = PWM(Pin(15), freq=50)
servo.duty_ns(1_500_000) # 1.5 ms pulse = centre
led = PWM(Pin(16), freq=1000) # GP16 is slice 0; the servo on GP15 is slice 7
led.duty_u16(16384) # 25 % brightnessThe servo and LED need different frequencies, so they sit on different slices. Had the LED been on GP14 (slice 7, the same as GP15), setting it to 1 kHz would have changed the servo to 1 kHz too.
PIO: Custom Protocols in Hardware
The RP2350 has three PIO blocks with four state machines each (12 in total, the RP2040 had 8). They run small timing-exact programs independently of the CPU, which is how the Pico drives WS2812 LEDs, extra UARTs, quadrature encoders or VGA output on any GPIO. MicroPython has a built-in neopixel module, so WS2812 strips work without writing PIO code yourself.
What Changed from the RP2040 Pico
| Pico (RP2040) | Pico 2 (RP2350) | |
|---|---|---|
| Cores | 2 × Cortex-M0+ | 2 × Cortex-M33 or 2 × Hazard3 RISC-V |
| Clock | 133 MHz | 150 MHz |
| Floating point | Software | Hardware FPU (Arm cores) |
| SRAM | 264 KB | 520 KB |
| Flash | 2 MB | 4 MB |
| PIO | 2 blocks, 8 state machines | 3 blocks, 12 state machines |
| PWM slices | 8 | 12 |
| Security | None | Secure boot, Arm TrustZone, OTP |
| HSTX (video out) | No | Yes, GP12–GP19 |
| Header pinout | — | Identical |
In practice the Arm cores are noticeably faster than the RP2040 for maths-heavy code thanks to the FPU, and the extra RAM matters for displays, audio buffers and MicroPython programs. The RISC-V cores are interesting to experiment with, but most libraries and MicroPython builds target Arm, so start there. Switching architecture means flashing a different build; it isn't a setting you change at run time.
Firmware isn't interchangeable. A UF2 built for the RP2040 won't run on the Pico 2. Download the RPI_PICO2 MicroPython build, or select Raspberry Pi Pico 2 in the Arduino IDE (arduino-pico core) or PICO_BOARD=pico2 in the C SDK. Your source code usually needs no changes. Setup steps are in installing MicroPython on the Pico W and Pico 2 W; the same process applies to the plain Pico 2.
Which Pico to Buy
| Board | Chip | Wi-Fi / BLE | Choose it when |
|---|---|---|---|
| Pico | RP2040 | No | Cheapest, simplest projects |
| Pico W | RP2040 | Yes | Cheap connected projects |
| Pico 2 | RP2350 | No | More RAM, speed or PIO, no network needed |
| Pico 2 W | RP2350 | Yes | The default for new connected projects |
For a smaller RP2350 board with a LiPo charger, see the Seeed XIAO RP2350.
Troubleshooting
| Problem | Fix |
|---|---|
| No RPI-RP2 / RP2350 drive appears | Hold BOOTSEL while plugging in USB; use a data cable |
| Old UF2 does nothing | It's built for the RP2040; flash a Pico 2 (RP2350) build |
| Button reads HIGH all the time | Erratum E9 with internal pull-down; use a pull-up to GND |
| I2C scan returns nothing | Check SDA/SCL order, the bus number for those pins, and pull-ups |
ValueError: bad SCL pin | That pin isn't on the I2C bus you chose; check the table |
| Two PWM outputs change together | Same slice; move one to a different slice |
| Board resets when a motor starts | Motor on 3V3 or VSYS; give it its own supply and join grounds |
FAQ
Is the Pico 2 pinout the same as the Pico? Yes, pin for pin. Wiring diagrams for the original Pico work unchanged.
Which pin is the Pico 2 onboard LED? GP25. In MicroPython, Pin(25) and Pin("LED") both work. (On the Pico 2 W the LED is on the wireless chip, so only Pin("LED") works there.)
How many analog pins does the Pico 2 have? Three on the header: GP26, GP27, GP28. Internal channels read VSYS and the temperature sensor.
Is the Pico 2 5 V tolerant? No. All GPIOs are 3.3 V only.
Can I power the Pico 2 from a battery? Yes, 1.8–5.5 V on VSYS (pin 39), such as a Li-ion cell or 3 × AA.
Will my RP2040 code run on the Pico 2? Usually yes after recompiling, or with the RP2350 MicroPython firmware. The compiled RP2040 UF2 file itself won't.
Should I use the Arm or RISC-V cores? Arm, unless you're specifically experimenting. Tools and libraries target it first.
Related guides: Pico 2 W pinout · Pico W pinout · Install MicroPython on the Pico · XIAO RP2350 pinout



