Now that you've set up the Arduino IDE with the Philhower RP2040 Arduino core, you're ready to start using Arduino with your RP2040.

RP2040 Arduino Pins

There is no pin remapping for Arduino on the RP2040. Therefore, the pin names on the top of the board are not the pin names used for Arduino. The Arduino pin names are the RP2040 GPIO pin names.

To find the Arduino pin name, check the PrettyPins diagram found on the Pinouts page. Each GPIO pin in the diagram has a GPIOx pin name listed, where x is the pin number. The Arduino pin name is the number following GPIO. For example, GPIO1 would be Arduino pin 1.

The Feather RP2040 has the GPIO pin names listed on the bottom of the board as GPx, where x is the pin number. The Arduino pin name is the number following GP. So, for example, pin GP0 would be Arduino pin 0.

Choose Your Board

Navigate to the Tools > Boards > Raspberry Pi RP2040 Boards menu. The Raspberry PI RP2040 Boards menu name may be followed by a version number.

Once the menu has expanded, you will see three different versions the Feather RP2040 available: Adafruit Feather RP2040Adafruit Feather RP2040 (Picoprobe), and Adafruit Feather RP2040 (pico-debug). Unless you are specifically familiar with the other two, always choose Adafruit Feather RP2040.

Choose Adafruit Feather RP2040 from the menu.

Load the Blink Sketch

Begin by plugging in your board to your computer, and wait a moment for it to be recognised by the OS. It will create a COM/serial port that you can now select from the Tools > Port menu dropdown.

Open the Blink sketch by clicking through File > Examples > 01.Basics > Blink.

Click Upload. A successful upload will result in text similar to the following.

Once complete, the little red LED will begin blinking once every second! Try changing up the delay() timing to change the rate at which the LED blinks.

Manually Enter the Bootloader

If you get into a state with the bootloader where you can no longer upload a sketch, or you have uploaded code that crashes and doesn't auto-reboot into the bootloader, you may have to manually enter the bootloader.

To enter the bootloader, hold down the BOOTSEL button, and while continuing to hold it (don't let go!), press and release the reset button. Continue to hold the BOOTSEL button until the RPI-RP2 drive appears!

Once the RPI-RP2 drive shows up, your board is in bootloader mode. There will not be a port available in bootloader mode, this is expected. Click Upload on your sketch to try again.

This guide was first published on Mar 05, 2021. It was last updated on 2022-01-26 16:20:06 -0500.

This page (Arduino Usage) was last updated on May 24, 2022.

Text editor powered by tinymce.