Arduino has announced their Arduino Nano RP2040 Connect board, a port of the recently announced Raspberry Pi Pico. Along with it, they’ve also decided to port the Arduino core, bringing the Arduino IDE, libraries and more to the Raspberry Pi Pico!
The port will also be available for other microcontroller boards based on the RP2040 – Raspberry Pi Foundation’s very own silicon made for the Raspberry Pi Pico. Read along to learn what this exciting news means for the maker community!
May 2021 Update: New Arduino Core release supports RP2040 Boards!
Arduino recently tweeted about the new Arduino Core mbed 2.0 release that supports Raspberry Pi RP2040 boards including Raspberry Pi Pico and their upcoming Arduino Nano RP2040 Connect. Arduino used mbed previously for their Arduino Nano 33 BLE board as there was no official Arduino core available for the microcontroller. Arduino did it again for the Raspberry Pi RP2040! You may check out a tutorial here by CNX Software!
March 2021 Update: Community Support is Here!
While the official port is still underway, community member Earle F. Philhower has taken things into his own hands to build his own port of the Arduino Core for all RP2040 boards! You can find its contents on his GitHub repository.
Status of the Port: What’s Working?
The port is still in development as Earle intends to add more features such as an installable filesystem, I2S support and an improved debug infrastructure. However, most common features like digitalWriteRead, analogWriteRead, hardware UART, SPI, Servo control are already up and running! For the full list of working features and caveats, I strongly recommend that you read the GitHub repository readme.
One important thing to note is the following procedure that you will need to follow for your first Arduino sketch upload.
According to Earle, you will need to hold the BOOTSEL button down while plugging in the Pico to your computer. Then you can hit the upload button in the Arduino IDE to transfer the sketch to your Pi Pico.
After that, you will have to select the appropriate serial port shown in the Arduino Tools > Port > Serial Port menu once. This allows the auto-reset tool to identify the correct device to reset.
Earle adds that the Pico will occasionally encounter a hard hang and be unable to respond to an auto-reset request. Simply follow the steps above to resolve this issue.
How to Install?
To install it with Arduino IDE, you can follow the instructions below, courtesy of Earle.
Step 1: Open up the Arduino IDE and go to File->Preferences.
Step 2: In the dialog that pops up, enter the following URL in the “Additional Boards Manager URLs” field:
Step 3: Hit OK to close the dialog, then go to Tools > Boards > Board Manager in the IDE.
Step 4: Type “pico” in the search box and select “Add”.
Be sure to visit Earle’s GitHub repository for the full details and future updates!
Arduino & Raspberry Pi
Before 2021, Arduino and Raspberry Pi treaded in parallel towards providing beginner-friendly platforms for students and enthusiasts to learn about electronics and computers.
With the new Raspberry Pi Pico microcontroller and Arduino’s promise to support it, we are seeing a merging of two electronics and computing education platforms that have largely been kept distinct in the last decade.
This is particularly exciting for beginners who are now getting into digital making. Now, with the Raspberry Pi Pico, we can leverage the tools and resources provided by both the Raspberry Pi Foundation and Arduino for learning and building!
Working with the Raspberry Pi Pico
At launch, the Raspberry Pi Pico is officially supported to be programmed in two languages, C/C++ and MicroPython. Programming in MicroPython is easy, with integrated support with the beginner-friendly Thonny Python IDE.
What about C/C++? Unfortunately, using C/C++ with the Raspberry Pi Pico is not as beginner-friendly as its Python counterparts.
To program the Raspberry Pi Pico in C or C++, you would have to write the code, then build it yourself with terminal tools. Or, you would have to set up a workflow with Microsoft Visual Studio Code extensions to flash the code to the Pi Pico.
As you can guess, it’s not the most user-friendly process, especially for hobbyists. Fortunately, Arduino is about to change this with their port of the Arduino IDE, which features their C++-adapted Arduino programming language
Arduino Ecosystem: Tools & Resources
Arduino has built up an extensive development platform over the years. With Arduino support for the Raspberry Pi Pico, we can expect these benefits to spill over from the Arduino ecosystem.
Let’s take a look at what these tools and resources will offer to the Raspberry Pi Pico!
Arduino IDE & Command Line Interface (CLI)
The Arduino IDE is a free-to-use development platform for Arduino boards, where makers can easily write and upload code to their boards. The Arduino IDE is used with Arduino’s own programming language, which is an adaptation of C++ for easier use by beginners.
Probably one of the most popular uses of the Arduino IDE is the built in Arduino Serial Monitor. Although it may lack some functions in comparison to dedicated serial terminals, it allows beginners to use serial communication with their Arduino boards without the hassle of configuring the connection in an unfamiliar environment.
Arduino also offers a suite of command-line tools, so that their boards can be programmed through by any command-line interface! This is especially useful, for example, if we want to use a headless Raspberry Pi 4 to program an attached Raspberry Pi Pico!
Arduino libraries are packages that can be used to extend the Arduino environment. It provides extra functionality that can be readily used so that beginners can interface with hardware or manipulate data easily without having to write all the code from scratch.
For example, you can use the available Grove libraries from Seeed to easily get started with any of the Grove sensors and actuators! You can click here to read more about Grove.
To date, there are over 3500 open source libraries ready for use with Arduino platforms listed on the Arduino library manager. Furthermore, installing libraries is super easy so it’s really convenient to get started!
Arduino & Raspberry Pi Community
At the end of the day, the most exciting thing about the Arduino and Raspberry Pi coming together on the Raspberry Pi Pico is probably the community.
Both platforms pride themselves on open source, community-based development, and each has their fair share of experienced users. And when it comes to open source development, it is needless to say that more minds are always better.
Each of these platforms has its own forums, offering help for any kind of problem you may encounter on your maker journey. This is further backed by thousands upon thousands of tutorials or articles on other online platforms. All the information you need to work with either platform is available with just a simple web search.
With the Raspberry Pi Pico and the upcoming Arduino support, you’ll be able to make use of the information made for both of them. We’re looking forward greatly to seeing what kinds of things will be achieved when two of such brilliant communities come together!
Order Your Own Raspberry Pi Pico!
Are you excited for what the upcoming Arduino support has to offer? If so, you should definitely consider picking one up at its affordable price of $4!
Order yours now from the Seeed Online Store!
Also, if you missed our other articles on the brand new Raspberry Pi Pico: