breadboard-os icon indicating copy to clipboard operation
breadboard-os copied to clipboard

RP2350 Support

Open mcknly opened this issue 1 year ago • 4 comments

Raspberry Pi has released the RP2350 (Pico 2), which should have the same SDK compatibility making code written for RP2040 portable to RP2350. However, there are several initial challenges blocking direct implementation:

  • There are new PICO_BOARD and PICO_PLATFORM variables for pico2/rp2350 that need to be passed
  • Currently the hardware/rp2040 directory name is tied directly to PICO_BOARD definition
  • FreeRTOS does not natively support the RP2350 yet (see here)

mcknly avatar Sep 13 '24 14:09 mcknly

See this commit on Raspberry Pi's FreeRTOS fork for the "unofficial" port for RP2350

mcknly avatar Sep 13 '24 18:09 mcknly

To use Raspberry Pi's unofficial port - merge the RP2350-specific changes into an existing copy of FreeRTOS kernel source, open a terminal in the kernel source directory and run:

git remote add raspberrypi https://github.com/raspberrypi/FreeRTOS-Kernel.git
git checkout -b rp2350
git pull raspberrypi 4f7299d6ea746b27a9dd19e87af568e34bd65b15

This will merge Raspberry Pi's changes. To use the RP2350 port, portable/ThirdParty/GCC/RP2350_ARM_NTZ/FreeRTOS_Kernel_import.cmake is sourced, and the PICO_PLATFORM variable must be set to "rp2350" to get it to work.

mcknly avatar Sep 13 '24 18:09 mcknly

Additional config options are necessary in FreeRTOSConfig.h to support ARMv8m (RP2350 is now Cortex-m33 vs ARMv7m/Cortex-m0+ on RP2040) - see this post

mcknly avatar Sep 13 '24 19:09 mcknly

FreeRTOSConfig.h with RP2350-specific configurations from Raspberry Pi in pico-examples - note configMAX_SYSCALL_INTERRUPT_PRIORITY option is also necessary

mcknly avatar Sep 13 '24 19:09 mcknly

Merged into v0.3-pre (#26) to be part of 0.3 release

mcknly avatar Oct 25 '24 18:10 mcknly