Inquire: Call 0086-755-23203480, or reach out via the form below/your sales contact to discuss our design, manufacturing, and assembly capabilities.
Quote: Email your PCB files to Sales@pcbsync.com (Preferred for large files) or submit online. We will contact you promptly. Please ensure your email is correct.
Notes: For PCB fabrication, we require PCB design file in Gerber RS-274X format (most preferred), *.PCB/DDB (Protel, inform your program version) format or *.BRD (Eagle) format. For PCB assembly, we require PCB design file in above mentioned format, drilling file and BOM. Click to download BOM template To avoid file missing, please include all files into one folder and compress it into .zip or .rar format.
Getting Started with Raspberry Pi Pico: Complete Beginner’s Guide (2025)
The Raspberry Pi Pico changed everything I thought I knew about affordable microcontrollers when it landed on my workbench back in 2021. After designing PCBs professionally for years and working with everything from ATmega chips to STM32 processors, I didn’t expect a $4 board to impress me. It did. Whether you’re completely new to electronics or transitioning from Arduino, this raspberry pi pico tutorial will walk you through everything from unboxing to running your first programs.
This comprehensive pico getting started guide covers the hardware specifications, development environment setup, MicroPython programming basics, and hands-on projects that will have you blinking LEDs and reading sensors within the hour. The Raspberry Pi Foundation designed this board specifically for beginners, and the learning curve reflects that focus on accessibility.
What Is the Raspberry Pi Pico?
The Raspberry Pi Pico represents the Foundation’s first venture into the microcontroller market. Unlike the Raspberry Pi 4 or Zero, which are full single-board computers running Linux, the rpi pico is a microcontroller board. Think of it as a dedicated embedded processor designed to interface directly with hardware, read sensors, control motors, and perform real-time tasks without the overhead of an operating system.
At the heart of every Pico sits the RP2040, Raspberry Pi’s custom-designed silicon. This isn’t a rebadged third-party chip. The engineers in Cambridge designed it from scratch, and that attention to detail shows in features like the Programmable I/O (PIO) state machines that enable custom hardware protocols impossible on comparable boards.
Raspberry Pi Pico Family Overview
The Pico family has expanded since the original launch. Choosing the right variant matters for your projects:
Model
Wireless
Headers
Price (USD)
Best For
Pico
No
No
$4
Cost-sensitive embedded projects
Pico H
No
Pre-soldered
$5
Beginners avoiding soldering
Pico W
Wi-Fi + Bluetooth
No
$6
IoT and wireless projects
Pico WH
Wi-Fi + Bluetooth
Pre-soldered
$7
IoT beginners
Pico 2
No
No
$5
Enhanced performance projects
Pico 2 W
Wi-Fi + Bluetooth
No
$7
Advanced wireless applications
For this raspberry pi pico tutorial, I recommend starting with the Pico H or Pico WH. The pre-soldered headers eliminate the need for soldering equipment while still providing full access to all GPIO pins. The wireless variants add flexibility for IoT projects down the road without significantly increasing cost.
Raspberry Pi Pico Technical Specifications
Understanding the hardware capabilities helps you plan projects appropriately. The RP2040 microcontroller packs impressive specifications for its price point:
RP2040 Microcontroller Specifications
Specification
Details
Processor
Dual-core ARM Cortex-M0+ @ 133MHz
SRAM
264KB on-chip
Flash Memory
2MB external QSPI
GPIO Pins
26 multi-function pins
ADC
3 channels, 12-bit resolution
PWM
16 channels
Communication
2x UART, 2x SPI, 2x I2C
Special Features
8 PIO state machines
Operating Voltage
3.3V (1.8V to 5.5V input range)
Dimensions
51mm x 21mm
The dual-core architecture deserves special attention. Unlike single-core microcontrollers where complex tasks can block sensor readings or communication, the RP2040 lets you dedicate one core to time-critical operations while the second handles everything else. This makes the rpi pico particularly effective for robotics and real-time control applications.
GPIO Pinout Reference
The Pico provides 26 GPIO pins with flexible functionality. Each pin can serve multiple roles depending on your project requirements:
Pin Type
Quantity
Notes
Digital I/O
26
All GPIO pins support digital in/out
PWM Capable
16
Hardware PWM on GP0-GP15
ADC Inputs
3
GP26 (ADC0), GP27 (ADC1), GP28 (ADC2)
I2C Buses
2
Multiple pin options per bus
SPI Buses
2
Multiple pin options per bus
UART
2
TX/RX pairs on multiple pins
Internal ADC
1
Temperature sensor on ADC4
One critical note from experience: the GPIO pins operate at 3.3V logic, not 5V like many Arduino boards. Connecting 5V signals directly to Pico pins can damage the RP2040. Use level shifters when interfacing with 5V components.
What You Need to Get Started
Before diving into the pico getting started process, gather these essential items:
Required Components
Item
Purpose
Approximate Cost
Raspberry Pi Pico (H/WH recommended)
The main microcontroller board
$5-7
Micro USB Cable
Programming and power
$3-5
Computer (Windows/Mac/Linux)
Development environment
Existing
Recommended Accessories for Learning
Item
Purpose
Approximate Cost
Breadboard (400+ points)
Prototyping without soldering
$3-5
Jumper Wire Set
Connections between components
$3-5
LED Assortment
Visual feedback projects
$3-5
Resistor Kit (220Ω, 10kΩ)
Current limiting, pull-ups
$5-8
Push Buttons
Input detection projects
$2-3
Potentiometer (10kΩ)
Analog input testing
$2-3
Many retailers offer starter kits bundling all these components with a Pico board. These kits typically provide better value than purchasing items separately and ensure component compatibility.
Installing MicroPython Firmware
MicroPython provides the gentlest introduction to rpi pico programming. It’s a full implementation of Python 3 optimized for microcontrollers, letting you execute commands interactively and see immediate results.
Step 1: Download the MicroPython UF2 File
Navigate to the official Raspberry Pi MicroPython download page (micropython.org/download/RPI_PICO/ for standard Pico or micropython.org/download/RPI_PICO_W/ for Pico W). Download the latest stable .uf2 firmware file.
Important distinction: Pico and Pico W require different firmware files. The wireless functionality won’t work if you flash standard Pico firmware onto a Pico W.
Step 2: Enter BOOTSEL Mode
This is where beginners often get confused. The Pico has a small white button labeled BOOTSEL. To enter programming mode:
Disconnect the Pico from USB if currently connected
Press and hold the BOOTSEL button
While holding the button, connect the USB cable to your computer
Release the button after connecting
The Pico will appear on your computer as a removable drive named “RPI-RP2”. This is the bootloader mode that accepts firmware updates.
Step 3: Flash the Firmware
Simply drag and drop the downloaded .uf2 file onto the RPI-RP2 drive. The Pico will automatically:
Copy the firmware to its flash memory
Verify the installation
Reboot into MicroPython mode
Disconnect the RPI-RP2 drive
The entire process takes about 10 seconds. If the drive disappears and doesn’t return as RPI-RP2, the firmware installed successfully. The Pico is now running MicroPython and ready for programming.
Setting Up Thonny IDE
While you can program the Pico using any text editor and command-line tools, Thonny provides an integrated development environment specifically designed for Python on microcontrollers. The Raspberry Pi Foundation recommends it for beginners, and after using various alternatives, I agree with that recommendation.
Installing Thonny
Download Thonny from thonny.org and install it for your operating system. The installation process is straightforward on Windows, macOS, and Linux. Accept the default options unless you have specific preferences.
Configuring Thonny for Pico Development
After installation, configure Thonny to communicate with your Pico:
Launch Thonny
Connect your Pico via USB (no need to hold BOOTSEL this time)
Click the interpreter selector in the bottom-right corner
Select “MicroPython (Raspberry Pi Pico)”
If prompted for a port, choose “Try to detect port automatically”
The Shell panel at the bottom should display something like:
MicroPython v1.22.0 on 2024-01-05; Raspberry Pi Pico W with RP2040
Type “help()” for more information.
>>>
This prompt indicates the REPL (Read-Evaluate-Print Loop) is active. You can type Python commands directly and see immediate results.
Testing the Connection
Type the following in the Shell panel and press Enter:
print(“Hello from Pico!”)
If “Hello from Pico!” appears, your development environment is correctly configured. This command executed on the Pico itself, not your computer. Every command you type in this Shell runs directly on the microcontroller.
Your First Raspberry Pi Pico Project: Blinking the Onboard LED
Every raspberry pi pico tutorial starts with the blink example, and for good reason. It confirms your hardware works, your development environment is configured correctly, and introduces fundamental programming concepts with visible feedback.
Understanding the Code
The Pico has an onboard LED connected to GPIO pin 25 (or controlled via the wireless chip on Pico W models). Here’s the complete blink program:
from machine import Pin
import utime
# Setup: Configure GPIO 25 as output for the onboard LED
led = Pin(25, Pin.OUT)
# Loop: Blink forever
while True:
led.value(1) # Turn LED on (HIGH)
utime.sleep(1) # Wait 1 second
led.value(0) # Turn LED off (LOW)
utime.sleep(1) # Wait 1 second
For Pico W users, the LED connects through the wireless chip, requiring slightly different code:
from machine import Pin
import utime
# Pico W onboard LED uses the “LED” designation
led = Pin(“LED”, Pin.OUT)
while True:
led.toggle() # Switch LED state
utime.sleep(0.5) # Wait 0.5 seconds
Running and Saving Your Program
In Thonny, type or paste the appropriate code into the editor panel (the large area above the Shell). Click the green Run button or press F5.
Thonny will ask where to save the file. Choose “Raspberry Pi Pico” and name it something descriptive like “blink.py”. If you name it “main.py”, the program will run automatically whenever the Pico powers on, useful for standalone projects.
The LED should now blink rhythmically. Congratulations, you’ve completed your first pico getting started milestone!
Working with External Components
The onboard LED provides quick verification, but real projects involve external components. Let’s expand with a simple circuit using an external LED and button.
Wiring an External LED
Components needed:
1x LED (any color)
1x 220Ω resistor
2x jumper wires
Breadboard
Connection schematic:
Connect Pico GP15 to the LED’s anode (longer leg) through the 220Ω resistor
Connect the LED’s cathode (shorter leg) to Pico GND
The resistor limits current through the LED, preventing damage to both the LED and the GPIO pin. Never connect LEDs directly to GPIO pins without current limiting.
External LED Blink Code
from machine import Pin
import utime
# External LED on GP15
external_led = Pin(15, Pin.OUT)
while True:
external_led.toggle()
utime.sleep(0.3)
Adding Button Input
Components needed:
1x tactile push button
1x 10kΩ resistor (pull-down)
Additional jumper wires
Connection schematic:
Connect one button leg to Pico GP14
Connect the same leg to GND through the 10kΩ resistor
Connect the opposite button leg to Pico 3V3
This creates a pull-down configuration where the pin reads LOW normally and HIGH when pressed.
Button-Controlled LED Code
from machine import Pin
import utime
led = Pin(15, Pin.OUT)
button = Pin(14, Pin.IN, Pin.PULL_DOWN)
while True:
if button.value() == 1: # Button pressed
led.value(1)
else:
led.value(0)
utime.sleep(0.01) # Small delay for debouncing
Alternatively, use the internal pull-down resistor to simplify wiring:
button = Pin(14, Pin.IN, Pin.PULL_DOWN)
This eliminates the need for the external 10kΩ resistor.
Reading Analog Sensors
The Pico’s three ADC channels open up possibilities for analog sensors like potentiometers, light sensors, and temperature probes.
This sensor measures chip temperature rather than ambient temperature. It’s useful for monitoring board conditions but won’t replace a dedicated environmental sensor.
Communication Protocols: I2C, SPI, and UART
Real-world projects often involve communicating with external devices using standard protocols. The rpi pico supports all major embedded communication interfaces.
I2C Communication Example
I2C is a two-wire protocol commonly used for sensors, displays, and other peripherals. Here’s how to scan for connected I2C devices:
from machine import Pin, I2C
# Initialize I2C bus 0 on GP0 (SDA) and GP1 (SCL)
i2c = I2C(0, scl=Pin(1), sda=Pin(0), freq=400000)
# Scan for devices
devices = i2c.scan()
if devices:
print(f”Found {len(devices)} I2C device(s):”)
for device in devices:
print(f” Address: {hex(device)}”)
else:
print(“No I2C devices found”)
Common I2C Sensors and Their Addresses
Sensor
Function
Typical Address
BME280
Temperature, humidity, pressure
0x76 or 0x77
MPU6050
Accelerometer, gyroscope
0x68 or 0x69
SSD1306
OLED display
0x3C or 0x3D
BH1750
Light intensity
0x23 or 0x5C
DS3231
Real-time clock
0x68
Popular Beginner Projects for Raspberry Pi Pico
Once you’ve mastered the basics, these projects provide excellent next steps:
Getting Started Guide PDF: datasheets.raspberrypi.com/pico/getting-started-with-pico.pdf
Development Tools
Thonny IDE: thonny.org
VS Code with Pico Extension: marketplace.visualstudio.com
Raspberry Pi Pico C/C++ SDK: github.com/raspberrypi/pico-sdk
Community Resources
Raspberry Pi Forums (Pico Section): forums.raspberrypi.com
MicroPython Documentation: docs.micropython.org
Random Nerd Tutorials: randomnerdtutorials.com
The Pi Hut Tutorials: thepihut.com/blogs/raspberry-pi-tutorials
Recommended Books
“Get Started with MicroPython on Raspberry Pi Pico” (Official, free PDF available)
“Programming the Raspberry Pi Pico in MicroPython” by Harry Fairhead
“Raspberry Pi Pico Workshop” by Juniper
Troubleshooting Common Issues
Pico Not Detected by Computer
If your Pico doesn’t appear when connected:
Try a different USB cable (some cables are power-only without data lines)
Test a different USB port
On Windows, check Device Manager for driver issues
Enter BOOTSEL mode to verify the board responds
“Device is busy” Error in Thonny
This occurs when another program is accessing the serial port:
Close any other serial terminal programs
Check if another Thonny instance is running
Disconnect and reconnect the Pico
Restart Thonny
Code Runs Once Then Stops
If your program executes but doesn’t continue:
Ensure you have an infinite loop (while True:)
Check for exceptions crashing the program
Add try/except blocks to catch errors
Use print() statements to debug execution flow
Frequently Asked Questions
What programming languages can I use with Raspberry Pi Pico?
The Pico officially supports MicroPython and C/C++. MicroPython offers the gentlest learning curve with its Python syntax and interactive development capability. C/C++ provides maximum performance and is preferred for production applications requiring precise timing or minimal code size. Additionally, CircuitPython (Adafruit’s MicroPython variant), Arduino IDE support, and Rust are available through community efforts.
Do I need to solder headers onto the Raspberry Pi Pico?
Not necessarily. The Pico H and Pico WH variants come with pre-soldered headers, ready for breadboard use immediately. If you purchase the standard Pico or Pico W without headers, you’ll need soldering equipment to attach pins. For absolute beginners, the pre-soldered versions eliminate this barrier and cost only about $1 more.
Can the Raspberry Pi Pico connect to Wi-Fi and the internet?
Only the Pico W and Pico 2 W variants include wireless connectivity. These models feature the Infineon CYW43439 chip providing 2.4GHz Wi-Fi and Bluetooth 5.2. The standard Pico and Pico 2 lack wireless hardware. If internet connectivity matters for your project, choose a W variant from the start.
What’s the difference between Raspberry Pi Pico and Arduino?
The Pico uses a more powerful dual-core ARM processor running at 133MHz with 264KB RAM, compared to the Arduino Uno’s single-core 16MHz processor with 2KB RAM. The Pico costs approximately $4 versus $20+ for genuine Arduino boards. However, Arduino benefits from a larger ecosystem of shields, libraries, and beginner tutorials. The Pico excels for users comfortable with Python or seeking more processing power at lower cost.
How do I make my program run automatically when the Pico powers on?
Save your program as “main.py” in the Pico’s root directory. MicroPython automatically executes main.py on boot. In Thonny, when prompted to save your file, select “Raspberry Pi Pico” as the destination and name it “main.py”. The program will then run whenever power is applied, without needing a computer connection.
Next Steps in Your Pico Journey
This raspberry pi pico tutorial covered the fundamentals, but the Pico’s capabilities extend far beyond blinking LEDs. Consider exploring:
Intermediate Topics:
PWM for motor control and LED dimming
Interrupt handling for responsive input detection
State machines for complex behavior
Multiple file projects with imported modules
Advanced Topics:
Programmable I/O (PIO) for custom protocols
Dual-core programming with _thread module
USB device emulation (HID, MIDI)
Direct Memory Access (DMA) operations
Wireless Projects (Pico W):
Web server hosting
MQTT for IoT messaging
Bluetooth sensor integration
Over-the-air updates
The Raspberry Pi Pico democratizes embedded development in ways that weren’t possible a few years ago. A board that costs less than a coffee can run real-time control systems, communicate wirelessly, and interface with countless sensors and actuators. Whether you’re building your first LED circuit or designing production-ready IoT devices, the rpi pico provides a solid foundation.
The best way to learn is to build. Pick a project slightly beyond your current skill level, break it into smaller problems, and solve them one at a time. The Pico community is remarkably helpful, and chances are someone has already documented solutions to the challenges you’ll encounter.
Inquire: Call 0086-755-23203480, or reach out via the form below/your sales contact to discuss our design, manufacturing, and assembly capabilities.
Quote: Email your PCB files to Sales@pcbsync.com (Preferred for large files) or submit online. We will contact you promptly. Please ensure your email is correct.
Notes: For PCB fabrication, we require PCB design file in Gerber RS-274X format (most preferred), *.PCB/DDB (Protel, inform your program version) format or *.BRD (Eagle) format. For PCB assembly, we require PCB design file in above mentioned format, drilling file and BOM. Click to download BOM template To avoid file missing, please include all files into one folder and compress it into .zip or .rar format.