raspberry pi 2 risc-v cores and micropython

The photo above is a plugboard that contains a Raspberry Pi Pico 2 connected to an OLED display, an 8×16 LED Matrix Feather, and a four line by twenty column LCD backlit character display. The OLED display and the 8×16 LED Matrix Feather were purchased from Adafruit (links below), while the LCD character display came from a collection of parts given to me when their owner passed away back in 2023. Barely visible is a single white LED in the upper left corner. It has a long orange wire connecting it to pin 29 (GPIO22) on the Pico 2.

The highly simplified schematic only shows direct connections. Those direct connections are the LCD display and the single LED. There’s a STEMMA QT connector off to the very left which is used, with proper cabling, to electrically connect the OLED and 8×16 LED matrix feather to the Pico 2. I chose to go this route because it keeps the schematic simple and easy to put into a blog post.

Right now I have the RISC-V version of MicroPython 1.24.1 flashed onto the Pico 2. My code behaves exactly on the RISC-V cores as it does on the ARM Cortex M33 cores, which I find amazing. I’m working with the RISC-V cores because I don’t have a use case for using the M33 cores, especially their security features. I’m not quite the fan of ARM I used to be. If there’s any opportunity where I can use and support RISC-V-based devices then I will, and this is one of those opportunities.

Links

finally: raspberry pi 2 w with micropython

Raspberry Pi Pico 2 W

I have been experimenting with a pair of Raspberry Pi 2 boards and another pair of Raspberry Pi 2 W boards. I’ll write about the non-WiFi boards later; I wanted to document what I had to do in order to get a pre-release version of MicroPython to program on one of my Pico 2 W boards.

This is the link to download the unofficial MicroPython UF2 file directly from Raspberry Pi itself: https://downloads.raspberrypi.com/micropython/mp_firmware_unofficial_latest.uf2

I don’t know how long this link will be valid. I got the unofficial firmware up and running with my test code. Here’s a typical output where the WiFi subsystem is being tested.

  MACHINE: Raspberry Pi Pico 2 W with RP2350  RELEASE: 1.25.0-preview FS TOTAL: 3,145,728 BYTES FS  FREE: 3,092,480 BYTES FS  USED: 53,248 BYTES MEM FREE: 448,160 BYTES  UID: 5C7E378630646F97 SSID: RP2-6F97 CPU FREQ: 150,000,000 Hz  I2C: SoftI2C(scl=5, sda=4, freq=500000)  I2C: DEVICES FOUND: ['0x3d']  I2C: FOUND OLEDMicroPython 1.25.0 previewGCC 10.3.12024-11-21ssid: BASIC-NET-2.4rssi: -58ssid: Dashmeister  rssi: -89ssid: ESP32S3-7814 rssi: -29ssid: SmartLife-EEFB   rssi: -74MicroPython v1.25.0-preview.49.g0625f07ad.dirty on 2024-11-21; Raspberry Pi Pico 2 W with RP2350Type "help()" for more information.

My test code shows that the WiFi subsystem is working as far as scanning for other access points in and near where I live. I’ll be working later to do something a bit more sophisticated. Be advised that this is for the ARM cores only, there is nothing out yet for the RISC-V cores like there is for the Pico 2 without WiFi.