Raspberry Pi Pico programmed using Arduino IDE

If you are interested in learning how to program the new Raspberry Pi Pico microcontroller, recently launched by the Raspberry Pi Foundation and now available to purchase priced at just $5. You may be interested in a new tutorial published to the Hackster.io website this week guiding you through how to program the Raspberry Pi Pico using the Arduino IDE interface.

“From controlling appliances to operating a light display, Raspberry Pi Pico puts the technology that underpins countless everyday operations into your hands. Programmable in C and MicroPython, Pico is adaptable to a vast range of applications and skill levels, and getting started is as easy as dragging and dropping a file. More experienced users can take advantage of Raspberry Pi Pico’s rich peripheral set, including SPI, I2C, and eight Programmable I/O (PIO) state machines for custom peripheral support.”


The Raspberry Pi Pico is equipped with a RP2040 chip featuring a dual-core Arm Cortex-M0+ processor with 264KB internal RAM and support for up to 16MB of off-chip Flash. A wide range of flexible I/O options includes I2C, SPI, and — uniquely — Programmable I/O (PIO). These support endless possible applications for this small and affordable package.


Source: Raspberry Pi Pico programmed using Arduino IDE


The Raspberry Pi Pico is a microcontroller board that is compatible with the Arduino Integrated Development Environment (IDE). You can use the Arduino IDE to write and upload code to the Raspberry Pi Pico, as well as interact with its various inputs and outputs.

Here are a few examples of how you can use the Arduino IDE with the Raspberry Pi Pico:

  1. Blink an LED: This is a classic Arduino example that involves using a digital output pin to control an LED. You can use the Arduino IDE to write a simple program that turns the LED on and off at regular intervals.

  2. Read a temperature sensor: You can use the Raspberry Pi Pico's analog input pins to read data from sensors such as temperature sensors. The Arduino IDE has libraries that make it easy to read and interpret sensor data.

  3. Control a servo motor: The Raspberry Pi Pico has pulse width modulation (PWM) output pins that can be used to control servo motors. You can use the Arduino IDE to write a program that moves the servo to a specific position based on input from a sensor or user input.


Blink an LED raspberry pi pico example in Arduino ide:

To blink an LED using the program raspberry pi pico with arduino ide, you can follow these steps:

  1. Connect the Raspberry Pi Pico to your computer using a micro USB cable.

  2. Install the Arduino IDE if you don't already have it installed. You can download it from the Arduino website (https://www.arduino.cc/en/Main/Software).

  3. Open the Arduino IDE and select the “Raspberry Pi Pico” board from the “Tools > Board” menu.

  4. In the Arduino IDE, create a new sketch (File > New) and enter the following code:

int ledPin = 0; // LED is connected to pin 0

void setup() {
  pinMode(ledPin, OUTPUT); // Set pin 0 as an output

void loop() {
  digitalWrite(ledPin, HIGH); // Turn on the LED
  delay(1000); // Wait for 1 second
  digitalWrite(ledPin, LOW); // Turn off the LED
  delay(1000); // Wait for 1 second
  1. Connect an LED to pin 0 of the Raspberry Pi Pico. You will need a current-limiting resistor (such as a 220 ohm resistor) in series with the LED to prevent it from being damaged.

  2. Upload the sketch to the Raspberry Pi Pico by clicking on the “Upload” button in the Arduino IDE.

  3. The LED should start blinking at a rate of one second on, one second off. You can adjust the blink rate by changing the delay values in the code.

I hope this helps! Let me know if you have any other questions.

About The Author

Muhammad Bilal

I am highly skilled and motivated individual with a Master's degree in Computer Science. I have extensive experience in technical writing and a deep understanding of SEO practices.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top