Getting started with a Raspberry Pi Pico board
This page will guide you in getting started with the Raspberry Pi Pico board or the uPesy RP2040 DevKit board. You will discover the different programming languages and know the other software used.
This tutorial is relevant for all boards based on the RP2040 microcontroller. The most famous board is the Raspberry Pi Pico. Nevertheless, the uPesy RP2040 DevKit board, an improved version of the Pico (created by uPesy), acts precisely the same.
We communicate with the board from a computer via a USB connection. Therefore, the first step is to verify that the computer recognizes the board. To do this, get a USB-C cable (the one used by new phones) and plug the board into a computer.
Remember to take a cable that transfers data and not just one to recharge batteries. It is good if you can hear the characteristic Windows noise when plugged in.
- The Pi Pico can behave in 2 different ways when connected to the computer; it behaves either like:
A simple USB key if its flash memory is empty or if you have kept the BOOT button pressed while connecting to the computer: the board exposes its internal flash memory.
A simple serial link, if there is already a program present (MicroPython or program compiled via the Arduino IDE). You can send and receive messages through the COM ports of the computer.
There is already a script on the uPesy RP2040 DevKit board that blinks the built-in blue LED. It must therefore be seen by the computer as a simple serial link.
The goal is to be ready quickly using the languages and tools suggested by the Raspberry Pi foundation: Micro Python on Thonny IDE.
MicroPython is a Python interpreter optimized for microcontrollers like the RP2040 or ESP32. Therefore, we can develop Python scripts that will be directly executed on the Pi Pico board. To do this, we install MicroPython on the board, and then we use IDE like Thonny that allows you to code and interact with MicroPython.
If you have just received a uPesy RP2040 DevKit board, the latest version of MicroPython is already installed on it, so you can skip this step . If you have the classic Raspberry Pi Pico, I redirect you to the installation guide of MicroPython on the Raspberry Pi Pico .
Thonny is a lightweight IDE, handy for developing Python when you begin. It is also installed by default on Raspberry Pi OS. If you’ve done Python on Raspberry Pi before, you’ve probably used it. It is available on Windows, Linux, and macOS. It integrates MicroPython very well.
To install it, I redirect you to the Thonny IDE installation and configuration guide .
After these steps, you should write your first scripts in MicroPython. To help you, I suggest you take a look at:
The detailed description of the uPesy RP2040 DevKit , if you have a uPesy board