This repository implements an entirely manually-written bare metal project for the RaspberryPi(R) Pico2 RP2350 dual-core ARM(R) Cortex(R)-M33 / RISC-V Hazard3.
Features include:
- CPU, dual-core boot both ARM and RISC-V supported, clock and PLL initialization,
- timebase derived from SysTick,
- blinky LEDs example,
- implementation in C11 with absolute minimal use of assembly.
A clear and easy-to-understand build system based on GNUmake completes this fun and educational project.
This repository provides keen insight on starting up a bare metal RaspberryPi(R) Pico2 RP2350 using no sdk.
This low-level startup boots through core 0 and performs the low level initialization of the C/C++ environment and the clock configuration then starts up core 1 (via a specific protocol). Core 1 subsequently carries out the blinky application, while core 0 enters an endless, idle loop.
Low-level initialization brings the CPU up to full speed at
Build on *nix*
is easy using an installed ARM compiler gcc-arm-none-eabi
or/and RISC-V compiler riscv32-unknown-elf
Build an ARM binary using the following command:
cd Blinky_Pico2_dual_core_nosdk
Rebuild.sh ARM
Build a RISC-V binary using the following command:
cd Blinky_Pico2_dual_core_nosdk
Rebuild.sh RISC-V
The build results including ELF-file, HEX-mask, MAP-file
and assembly list file are created in the Output
directory.
CI runs on pushes and pull-requests with a simple
build and result verification on ubuntu-latest
using GutHub Actions.