Couple of months ago, I bought a "Raspberry Pi Pico" to get some hands-on experience of it and to create some amazing projects using it. But since then, it has just been sitting on my desk, collecting dust. Today after a very long wait, I finally have decided to create a short video tutorial to show you guys how to get started with the Raspberry Pi Pico.
Couple of months ago, I bought a Raspberry Pi Pico to get some hands-on experience of it and to
create some amazing projects using it. But since then, it has just been sitting on my desk collecting
dust. Today, after a very long wait, I have finally decided to create a short video tutorial
to show you guys how to get started with Raspberry Pi Pico. In this tutorial, I'm going to discuss
what is a Raspberry Pi Pico, the technical specifications of the board, how to program
Pico using C, C++ and MicroPython using Arduino IDE and Tony's Python IDE and how to install and
blink a LED. Difference between Raspberry Pi Pico and Arduino. And to conclude the tutorial, we'll
have a look at the pros and cons of the board. This video is sponsored by PCBWay. PCBWay
specializes in manufacturing of very high quality, low volume, colored PCBs at a very budgetary price.
In addition to standard PCBs, you can order advanced PCBs, aluminum PCBs, rigid flex PCBs.
They also provide PCB assembly and other related services which can meet your need
at the greatest extent. Raspberry Pi Pico is a low cost microcontroller. It can be used to
control other electronic modules and sensors same as any other microcontroller. Pico is not a Linux
single board computer. Rather, it is a microcontroller like Arduino. Since it's a microcontroller, it
doesn't come with all the overheads that a computer brings. Hence, it consumes less current.
Actually, it's more like Arduino than Raspberry Pi. Pico is not a rival of Raspberry Pi Zero.
It actually can work in conjunction with the regular Pis. Pico is a breadboard friendly and
has 40 GPIO pins operating at 3.3 volt, 20 on each side. It has a dual core ARM Cortex M0 plus
processor. Pico's brain, the RP2040 microcontroller chip is designed by Raspberry Pi in the United
Kingdom. It can be powered either via the micro USB port or via the VSYS GPIO pin by providing
voltage between the range of 1.8 volt to 5.5 volts. Raspberry Pi Pico is absolutely different
from all other Raspberry Pi models. Pico is one of the first microcontroller to use the RP2040
Pi silicon processor. It is a custom system on chip developed by Raspberry Pi team in UK which
features a dual core ARM M0 plus processor running at 133 megahertz with 264 KB of SRAM and 2 MB of
flash memory for storing files on it. The specifications are as follows. The one biggest
disadvantage of Raspberry Pi Pico is that there is no Wi-Fi or Bluetooth on it. ESP32 and ESP8266
which you can buy for the similar price comes with Wi-Fi and Bluetooth. Surely, you can add
wireless connectivity via external components. However, that would require a little bit more
knowledge and experience to get it working. Since Pico is not a computer, we need to write our codes
on a different machine using an external application and then flash the code on the
microcontroller over USB. Here is the top view of the pinouts of the Raspberry Pi Pico. The pin
labels are on the bottom side of the board. Pi Foundation officially supports MicroPython and
CC++. However, high-level programming languages like CircuitPython, a fork of MicroPython created
by Adafruit and drag-and-drop Python editor like PicoPyper which adds further enhancement and can
be used to program the Pico boards. Python and CC++ are both great for programming Picos. However,
the ability to program a Pico just like an Arduino would help us to integrate the Pico
into the Arduino ecosystem. One of the best reasons to do this is because of the availability of
libraries to integrate modules, sensors and other complex stuff without having to write the entire
code from scratch. To start, let's go to Tools, Board, Board Manager and search for Pico. Select
Arduino Embed OS RP2040 Boards and hit the Install button. Connect the micro USB cable to Pico
and then press and hold the boot cell button before plugging the USB cable into the computer.
Release the boot cell once the drive RP1, RP2 appears on your computer. Now go to Tools, Port
and you'll see the port in there. To load the Blink example, go to Files, Examples, Basics,
Blink and click on the Upload button. This will load the code on the Pico board. After the IDE
finishes uploading the code, you will see the Pico's onboard LED blinking. You can now use
your Pico like an Arduino and program it using the Arduino IDE. You can program your Pico using
MicroPython by connecting it to the computer via a USB and then dragging and dropping files to it.
Installation of MicroPython on Pico requires a UF2 file to be copied onto it. A UF2 file
is a binary data file which contains program that can be transferred from a PC to a microcontroller.
To load MicroPython on Pico, download MicroPython UF2 file from the link provided in the description
below. Connect the micro USB cable to Pico and then press and hold the boot cell button before
plugging the USB cable into the computer. Release boot cell once the drive RP1, RP2 appears on your
computer. Drag and drop the UF2 file onto the RP1, RP2 volume. Your Pico will reboot. That's it.
You are now running MicroPython on your Pico. To write code and save files to Pico, we are going
to use Tony's Python IDE. Tony comes with built-in Python 3.7, so just one simple installer is what
you need. To start, download and install Tony free from Tony's website for your version of operating
system. The website link is in the description below. If you are running Raspberry Pi OS,
then Tony is already installed on it. Connect the Pico to your computer. Then in Tony, go to tools,
options, and click on the interpreter tab. From the interpreter drop-down list, select MicroPython
Raspberry Pi Pico. The port drop-down menu can be left to automatically detect the Pico. Click OK
and close. A Python shell called read eval print loop, REPL, will pop up to show that Pico is
connected and working. To load the blink example, enter the following code in the main editor pane
to toggle the on-board LED. Click the run button to execute the code. Tony will ask you whether
you want to save the file on this computer or on the MicroPython device. Choose MicroPython device.
Enter blink.py as the file name. Make sure you enter .py as the file extension so that Tony
recognizes it as a Python file. You should now see the on-board LED switching between on and off
until you click the stop button. Before Raspberry Pi Pico, Raspberry Pi has always been known for
their single-board computers. However, in 2021, Raspberry Pi Foundation stepped a few steps
forward and launched the Raspberry Pi Pico, giving a head-to-head challenge to Arduino and all other
board-based microcontrollers. Arduino was first introduced in 2005, and since then, millions of
Arduino units have been sold in the market. Compared to that, the response Pico received
after its initial launch in 2021 is absolutely mind-blowing. Both units are made for automating
applications that do not involve human intervention. Pico can be used alone or in
combination with Arduino for automation and AI purposes. Both modules are different in terms
of power consumption, value, functionality, and price. Pico boards come unsoldered, however Arduino
comes pre-soldered or unsoldered. Pico module supports MicroPython and C C++, while Arduino
codes are written in C C++ using Arduino IDE. So, which one to go for? Pico or Arduino?
Now, let's have a look at the pros and cons of this microcontroller. Raspberry Pi Pico is cheap,
very small, and easy to use microcontroller. Pico is dual core device coupled with high
performance bus matrix. Pico consumes very low power. Pico is breadboard friendly. It can be
C C++ and MicroPython. Pico can be programmed using Arduino IDE. It has 26 multifunctional
3.3V GPIO pins. 23 of them are digital and 3 are analog. Pico comes with 8 programmable I O,
P I O and 2 analog inputs. Pico boots quickly and does not require a safe shutdown.
The disadvantages include, Pico completely lacks WiFi and Bluetooth without any add-on.
It lacks GPIO markings on the top side of the board. The board comes unsoldered,
so you will have to solder the header pins or surface mount it before using it in your project.
GPIO pins are 3.3V which could be seen as a disadvantage. However, devices designed for
5V can still be used with 3V via a voltage divider or a logic level converter. Pico still uses
micro USB port. If you have a Windows, Apple, Linux or a Raspberry Pi, then you are already
well in your way to program this small, cute and gorgeous Raspberry Pi Pico in your next project.
I bet there must be a lot of project ideas going in your mind. So, get your supplies and start
coding. So, what are you waiting for? Thanks again for watching this video. I hope it helps you.
If you want to support me, you can subscribe to my channel and watch my other videos.
Thanks. See you again in my next video. Bye now.