If you’ve been dipping your toes into the world of embedded systems or DIY electronics, you’ve likely heard whispers about the RP2040. But what exactly makes this tiny chip from Raspberry Pi stand out in a sea of microcontrollers? Released in 2021 as the brain behind the iconic Raspberry Pi Pico, the RP2040 has quietly become a favorite among hobbyists, educators, and even professional engineers. In this deep dive, we’ll explore why this dual-core marvel is redefining what a budget-friendly microcontroller can achieve — and how you can start tinkering with it today.
What is RP2040?
The RP2040 is a Microcontroller Unit (MCU) introduced by the Raspberry Pi Foundation. It serves as the core component for the Raspberry Pi Pico and other development boards. It’s sold at $10 on official site now.

RP2040 Specification
- Dual – core Arm Cortex – M0+ running at 133MHz
- 264KB of on – chip SRAM and 2MB of onboard flash memory
- Supports up to 16MB of off – chip flash memory via a dedicated QSPI bus
- Equipped with a DMA controller
- Features 30 GPIO pins, 4 of which can be used as analog inputs
- Has 2 UARTs, 2 SPI controllers, and 2 I2C controllers
- Offers 16 PWM channels
- Provides USB 1.1 host and device support
- Incorporates 8 Raspberry Pi Programmable I/O (PIO) state machines for custom peripheral support
- Supports the UF2 – enabled USB mass storage boot mode for drag – and – drop programming

RP2040 Naming Explanation
The RP2040’s name reflects its core specifications:
- RP: Stands for Raspberry Pi, the developer.
- 2: Indicates dual – core Arm Cortex – M0+ processors.
- 0: Represents the core type (M0+ in this case).
- 4: Calculated as
floor(log2(SRAM/16k))
, where 264KB SRAM → ~4. - 0: Derived from
floor(log2(non - volatile/16k))
, with 2MB flash → ~7, but simplified to 0 in naming.

RP2040 Pinout
Notably, its Programmable Input/Output (PIO) subsystem has two state machines. This allows creating custom communication protocols, such as easily controlling WS2812 LED strips or building a custom VGA interface, reducing CPU workload.

RP2040 Block Diagram
- 2 UARTs: Serial comms for devices/modules/computers.
- 2 SPIs: High – speed master – slave data transfer (e.g., flash/SD cards).
- 2 I2Cs: Multi – device bus for sensors/EEPROMs via SDA/SCL lines.
- 16 PWMs: Motor speed/LED brightness control via duty cycle modulation.

Development Support for RP2040
Official Development Board - Raspberry Pi Pico
The Raspberry Pi Pico serves as the official development board for the RP2040, and it’s a fantastic entry point for developers. Measuring just 65mm x 17mm, this compact board is incredibly affordable, priced at only $4, making it accessible to a wide range of users, from hobbyists on a budget to students exploring the world of microcontrollers.

One of the great advantages of the Raspberry Pi Pico is its ease of use. It has a simple form factor with a row of GPIO pins on either side, clearly labeled for easy identification. This layout makes it straightforward to connect external components such as sensors, actuators, or displays. For example, connecting a temperature sensor like the DHT11 to the Pico is as simple as connecting the sensor’s data pin to one of the GPIO pins on the Pico, along with the power and ground connections.
The Pico also has a built – in USB connector, which is used for both powering the board and programming it. When connected to a computer, it appears as a mass storage device, allowing for easy “drag – and – drop” programming. For instance, if you’ve written a MicroPython script or a compiled C/C++ binary, you can simply copy the file onto the Pico’s virtual drive, and it will start executing the program.
Programming Languages and Frameworks
from machine import Pin
import time
led = Pin(25, Pin.OUT)
while True:
led.value(1)
time.sleep(1)
led.value(0)
time.sleep(1)
Tools and IDEs
Thonny
VS Code
RP2040 Vs. RP2350 Chips
The RP2040 and RP2350 are microcontrollers developed by Raspberry Pi. The RP2040 was an early offering, while the RP2350 is a more advanced successor with enhanced features. Here’s a comparison between the two:

Feature | RP2040 | RP2350 |
---|---|---|
Core Architecture | Dual Arm Cortex-M0+ | Dual Arm Cortex-M33 or Dual RISC-V Hazard3 |
Clock Speed | 133MHz | 150MHz |
On-chip SRAM | 264KB | 520KB |
Security Features | Basic security features | Arm TrustZone, Signed Boot, SHA-256, TRNG, Fault Detectors |
Peripheral Interfaces | 2×UART, 2×SPI, 2×I2C, ADC, PWM, USB 1.1 | Enhanced peripherals, additional PIO state machines, more GPIO pins, higher power efficiency |
Packaging | Single 7×7mm QFN56 option | 7×7mm QFN60 (RP2350A) with 30 GPIOs or 10×10mm QFN80 (RP2350B) with 48 GPIOs; both with 2MB stacked QSPI flash (RP2354A and RP2354B) |
Conclusion
In conclusion, the RP2040 is a remarkable microcontroller that has made a significant impact in the world of embedded systems and electronics development. Wellcome to share your opnions or experience!