EasyManuals Logo

Raspberry Pi RP2040 User Manual

Raspberry Pi RP2040
77 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #26 background imageLoading...
Page #26 background image
Chapter 7. Using Visual Studio Code
Visual Studio Code (VSCode) is a popular open source editor developed by Microsoft. It is the recommended Integrated
Development Environment (IDE) on the Raspberry Pi 4 if you want a graphical interface to edit and debug your code.
7.1. Installing Visual Studio Code
IMPORTANT
These installation instructions rely on you already having downloaded and installed the command line toolchain (see
Chapter 3), as well as connecting SWD to your board via OpenOCD (Chapter 5) and setting up GDB for command-line
debugging (
Chapter 6).
ARM versions of Visual Studio Code for the Raspberry Pi can be downloaded from https://code.visualstudio.com/
Download
. If you are using a 32-bit operating system (e.g. the default Raspberry Pi OS) then download the ARM .deb file; if
you are using a 64-bit OS, then download the
ARM 64 .deb file. Once downloaded, double click on the .deb package and
follow the instructions to install it.
Install the downloaded
.deb. package from the command line. cd to the folder where the file was downloaded, then use
dpkg -i <downloaded file name.deb> to install.
Once the install has completed, install the extensions needed to debug a Raspberry Pi Pico:
code --install-extension marus25.cortex-debug
code --install-extension ms-vscode.cmake-tools
code --install-extension ms-vscode.cpptools
Finally, start Visual Studio Code from a Terminal window:
$ export PICO_SDK_PATH=/home/pi/pico/pico-sdk
$ code
Ensure you set the
PICO_SDK_PATH so that Visual Studio Code can find the SDK.
NOTE
If PICO_SDK_PATH is not set by default in your shell’s environment you will have to set it each time you open a new
Terminal window before starting vscode, or start vscode from the menus. You may therefore want to add it to your
.profile or .bashrc file.
NOTE
You can configure intellisense for CMake by changing the provider by toggling; View Command Palette C/C++:
Change Configuration Provider… CMake Tools.
Getting started with Raspberry Pi Pico
7.1. Installing Visual Studio Code 25

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Raspberry Pi RP2040 and is the answer not in the manual?

Raspberry Pi RP2040 Specifications

General IconGeneral
ProcessorDual-core Arm Cortex-M0+
Clock Speed133 MHz
SRAM264 KB
GPIO30
USBUSB 1.1 Host/Device
PWM16 channels
UART2
SPI2
I2C2
Temperature Range-20°C to +85°C
Operating Voltage1.8V to 3.3V
FlashExternal QSPI flash
I/O InterfacesSPI, I2C, UART, PWM
ADC4 × 12-bit ADC channels

Related product manuals