Raspberry Pi RP2040 Boards - johnosbb/Automation GitHub Wiki
Raspberry Pi RP2040 Boards
Note: When you initialll plug in the Pico board there may be no serial Port available in device manager or in the dropdown menu of the Arduino IDE. The RP2040 does not actually use a serial port to upload, so it is not unusual if it does not appear. You will see a serial port appear after uploading your first sketch.
Specifications
The RP2040 is a dual-core ARM Cortex-M0+ microcontroller, and while it offers plenty of features like multiple I/O options, PWM, and support for SPI, I2C, and UART, it does not include Wi-Fi or Bluetooth connectivity.
Analog to Digital Conversion
The ADC (Analog-to-Digital Converter) ports on RP2040-based boards, such as the Raspberry Pi Pico, have an input voltage range of 0V to 3.3V. This means that the ADC can measure voltages from 0 volts (corresponding to a digital value of 0) up to 3.3 volts (corresponding to the maximum digital value, which is 4095 for the 12-bit ADC).
Layout
Purple Edition
Offical RP2040
Dependencies
- In the Ardiouno IDE- select preferences->settings->additional board manager URLs
- Add the following
https://github.com/earlephilhower/arduino-pico/releases/download/global/package_rp2040_index.json
Note: For Tensorflow Lite projects one should use the mbed version:
- In the Boards Manager, search for RP2040. Scroll down to the Raspberry Pi Pico/RP2040 by Earle F Philhower, III entry. Click Install to install it.
- Under boards select "Raspberry Pi Pico"
Note: For Tensorflow Lite projects select the mbed version:
Download your first sketch:
/*
Blink
Turns an LED on for one second, then off for one second, repeatedly.
Most Arduinos have an on-board LED you can control. On the UNO, MEGA and ZERO
it is attached to digital pin 13, on MKR1000 on pin 6. LED_BUILTIN is set to
the correct LED pin independent of which board is used.
If you want to know what pin the on-board LED is connected to on your Arduino
model, check the Technical Specs of your board at:
https://www.arduino.cc/en/Main/Products
modified 8 May 2014
by Scott Fitzgerald
modified 2 Sep 2016
by Arturo Guadalupi
modified 8 Sep 2016
by Colby Newman
This example code is in the public domain.
https://www.arduino.cc/en/Tutorial/BuiltInExamples/Blink
*/
// the setup function runs once when you press reset or power the board
void setup() {
// initialize digital pin LED_BUILTIN as an output.
pinMode(LED_BUILTIN, OUTPUT);
}
// the loop function runs over and over again forever
void loop() {
digitalWrite(LED_BUILTIN, HIGH); // turn the LED on (HIGH is the voltage level)
delay(1000); // wait for a second
digitalWrite(LED_BUILTIN, LOW); // turn the LED off by making the voltage LOW
delay(1000); // wait for a second
}
The serial port option will appear after you download your first sketch to the board:
It will also be available in the Arduino IDE
Putting the Board in Boot Loader Mode
To get the board in bootloader mode hold down the BOOTSEL button while plugging the board into USB