Raspberry Pi Pico is a development board equipped with RP2040 microcontroller which is the dual ARM Cortex M0+ core, originally developed by the Raspberry Pi Foundation. Unlike the conventional Raspberry Pi, it cannot be equipped with Linux OS and can be developed with C / C ++ or MicroPython. First, I tried to build a development environment with MicroPython.
Preparation
The Raspberry Pi Pico I got was a board only (no accessories such as USB cable included), so I needed to prepare a USB cable (the board side connector is USB micro).Also, download and install “Thonny Python IDE” from the official website as a software (MicroPython) development environment.
How to use
1, First, hold down the BOOTSEL button on the board and connect the Rasberry Pi Pico to your PC with a USB cable. 2, Rasberry Pi Pico looks as removable media from your PC, access index.htm in it. You will be connected to the Rasberry Pi Pico official website, access Getting started MicroPython from the tab below. Download the Rasberry Pi Pico firmware from the link labeled Download UF2 file. 3, Copy the downloaded .uf2 format file onto Rasberry Pi Pico, which is visible as removable media. The folder of Raspberry Pi Pico will be closed and it will be displayed that the USB device has been removed, but this should be normal. 4, Start the Thonny IDE. Make sure that the environment setting at the bottom right of the screen is MicroPython (Raspberry Pi Pico). Write the following program in the Shell tab. Then, the LED on the Raspberry Pi Pico board will light up.As shown below, if you write 0 in the argument of led.value, the LED will turn off.from machine import Pin led = Pin(25, Pin.OUT) led.value(1)
led.value(0)
References
https://www.itmedia.co.jp/news/articles/2102/16/news026_2.htmlhttps://thonny.org/