Arduino upload error

No accessible RP2040 devices in BOOTSEL mode were found.

A Raspberry Pi Pico takes a new program when it starts in BOOTSEL mode, where it shows up as a drive called RPI-RP2. The upload tool found no Pico in that mode.

  • Upload error
  • 3 common causes
The message

What the Arduino IDE prints

Output window
No accessible RP2040 devices in BOOTSEL mode were found.
Failed uploading: uploading error: exit status 1

The board is not in BOOTSEL mode, the cable carries no data, or the computer does not let the tool reach the device.

Causes

The 3 usual causes in order

1The Pico is not in BOOTSEL mode

Normal running mode is not enough for a first upload.

  1. Unplug the Pico.
  2. Hold the BOOTSEL button, plug the cable in, then let go.
  3. A drive called RPI-RP2 should appear. Upload again.

2The USB cable only carries power

A charge-only cable lights the board and shows no drive.

  1. Try a cable that transfers data, plugged into the computer directly.

3On Linux, the tool may not use the device

Without a udev rule, a normal user cannot reach the device.

  1. Install the udev rules that come with the Raspberry Pi Pico tools, then unplug and plug the board in again.
  2. Or copy the .uf2 file onto the RPI-RP2 drive by hand.
On a real board

What to do at the bench

A .uf2 file can simply be copied onto the RPI-RP2 drive, with no upload tool, which sidesteps this error. Mokxi's "Download for your board (.uf2)" gives you that file for a Pico, a Pico W or a XIAO.

Run the sketch in Mokxi before you blame the board. If it builds and runs there, the code is fine and the problem is the connection to the real board.

Test the sketch in Mokxi first

Run the sketch here before you blame the board. If it builds and runs in Mokxi, the code is fine and the fault is the connection to the real board. Mokxi never uploads in a simulation, so it cannot raise this error itself.

A sketch to try first
void setup() {
  Serial.begin(115200);
  pinMode(LED_BUILTIN, OUTPUT);
  Serial.println("blink ready");
}

void loop() {
  digitalWrite(LED_BUILTIN, HIGH);
  delay(500);
  digitalWrite(LED_BUILTIN, LOW);
  delay(500);
}

Run it in Mokxi

FAQ

Questions and answers

What is BOOTSEL?

A button on the Pico that makes it start as a USB drive, so you can copy a program onto it.

What is a .uf2 file?

A program file the Pico accepts by drag and drop. Copy it onto the RPI-RP2 drive and the Pico restarts with it.

Does the Pico W work the same way?

Yes. Hold BOOTSEL, plug it in, and it appears as RPI-RP2 too.