The new Raspberry PI Pico brings to RP fans a lot of new ports. One of the most appreciated features is that we can now have analog ports (needed for many sensor projects). Let’s see more closely Raspberry PI Pico pinout
In this tutorial I’m going to show how to identify and map ports on Raspberry PI Pico pinout.
The new Raspberry PI Pico has 40 unpopulated PIN for your project, plus 3 additional PIN for debug purposes.
A common need is adding 20-pin strips for each side, so that connecting your RPI Pico to a breadboard or wiring will be simpler. Soldering these strips requires a bit of attention, as working with a hot soldering iron can drive to burns risk. A good guide to correctly solder these pins is available from MagPI How to solder GPIO pin headers to Raspberry Pi Pico tutorial.
The new Pico comes with a GPIO mapping completely different from common Raspberry PI boards. Following picture shows the official map:
Labels color can be interpretated with following legend:
Besides the physical numbering, we can find the logical PINs number (GPnn, where “nn” goes from 0 to 28). GP25 is reserved for on-board LED (whose use is explained in our first steps with Raspberry PI Pico tutorial).
Some GPIOs are present even if not phisically accessible and are used for internal board functions:
- GPIO29 – in ADC mode (ADC3), used to measure VSYS/3
- GPIO25 – connected to on-board LED
- GPIO24 – VBUS sense (high if VBUS is present, else low)
- GPIO23 – Controls the on-board SMPS Power Save pin
We have 8 ground PINs (GND), from where the physical ground can be connected.
On top-right side of RPI Pico we have PINs giving reference for high level power:
According to Raspberry PI Pico datasheet:
- VBUS is the micro-USB input voltage, connected to micro-USB port pin 1. If you use a 5V power supply from USB, this will be nominally 5V (or 0V if the USB is not connected or not powered).
- VSYS is the main system input voltage, which can vary in the allowed range 1.8V to 5.5V, and is used by the on-board SMPS (Switched Mode Power Supply) to generate the 3.3V for the RP2040 and its GPIO.
- 3V3_EN connects to the on-board SMPS enable pin, and is pulled high (to VSYS) via a 100K resistor. To disable the 3.3V (which also de-powers the RP2040), short this pin low.
- 3V3 is the main 3.3V supply to RP2040 and its I/O, generated by the on-board SMPS. This pin can be used to power external circuitry (maximum output current will depend on RP2040 load and VSYS voltage, it is recommended to keep the load on this pin less than 300mA).
The RPI Pico does not have an on-board reference and therefore uses its own power supply as a reference from its SMPS (3.3V). This is a simple solution which has some minor drawbacks which shouldn’t interfere with common hobbyst purposes. The ADC_VREF pin can be used with an external reference if better ADC performance is required.
AGND is the ground reference for GPIO26-29, as analog ground plane is separated from other ones. You can connect this pin to digital ground if ADC performance is not critical for your project.
The 3 ADC pins (ADC0, ADC1 and ADC2) are the ones which can be used for programming. They have a 12-bit logic, which means that signals from AGND to ADC_VREF are divided into 4096 levels.
Raspberry PI Pico has 8 PWM blocks, each one driving two PWM output signals, for a total of up to 16 controllable PWM outputs (ref. to paragraph 4.5 from RP2040 datasheet). All 30 GPIO pins can be driven by PWM blocks:
This means that when you set a defined PWM on PWM 2A, this signal will be available both on PIN 6 and 26.
If a PWM B pin is used as an input and is selected on multiple GPIO pins, then the PWM slice will see the logical OR of those two GPIO inputs.
Digital Peripherals Interfacing
Raspberry PI Pico includes the capability to interface digital peripherals able to communicate using I2C, UART, or SPI:
RPI Pico supports up to 2 × UART, 2 × I2C, 2 × SP.
The UART allows communicating with enabled devices by performing serial-to-parallel conversion on data received and parallel-to-serial conversion on data transmitted.
I2C is a commonly used 2-wire interface that can be used to connect devices for low speed data transfer using clock SCL and data SDA wires.
SPI is a serial peripheral interface using a 4 lines communication: Serial Clock, transmission, receiving, and chip select (this one to define who is master and slave in the communication).
Besides managing and programming via a USB connection, the Raspberry PI Pico pinout also includes Serial Wire Debug (SWD) port. This allows resetting your board and running code without the need of pressing any button.
This port can be also useful to interact with the RP2040 for debugging.
Now that you know what are the Raspberry PI Pico PINs, you can use my Raspberry PI Pico tutorials for useful and funny projects!
We are sorry that this post was not useful for you!
Let us improve this post!
Tell us how we can improve this post?