🛠 Advanced setup of the Romu board
Objectives
This tutorial aims to master the hardware and software initialization of the Bitmerse Romu board. Unlike standard boards, the absence of external GPIO pins requires a specific approach. You will learn to leverage the native USB Type-A connector for code flashing and debugging, taking advantage of the hybrid RP2354A architecture (Cortex-M33 and RISC-V). The goal is to validate the compilation chain and secure boot on this ultra-compact 15.5 x 12 mm format.
Required Materials
- A Bitmerse Romu board.
- A computer with a standard USB-A port (or USB-C to A adapter).
- A development environment compatible with Raspberry Pi Pico (C/C++ SDK or MicroPython).
- A format conversion tool (e.g.,
uf2conv.py) if needed for bootloader mode. - A serial terminal (like PuTTY or the Arduino/Raspberry Pi Pico IDE).
Steps
Install the Raspberry Pi Pico SDK. The Romu uses the RP2354A; ensure your toolchain supports this specific chip. Configure environment variables to point to ARM and RISC-V compilation tools if targeting both cores.
- Environment Preparation
Since there is no visible external reset button, the standard method to enter bootloader mode (to flash new firmware) involves holding the boot button (if present or via debug pads depending on revision) while inserting into the USB port. Otherwise, the first connection to a clean PC may require a specific recovery procedure via the USB DFU interface if the default firmware is missing.
- Accessing BOOTSEL Mode
Create a minimalist project. Given the HID/USB nature, compile a simple example that blinks the RGB LED. Note that without GPIO, output is via the embedded LED or USB commands. ``bash cmake -DPICO_BOARD=romu .. make ``
- Compiling Test Firmware
Insert the board directly into a USB-A port. If in BOOTSEL mode, a mass storage device appears. Copy the generated .uf2 file to this drive. The board restarts automatically.
- Flashing via USB
Open a serial terminal on the associated COM/VCP port. Send a simple command to verify the microcontroller responds, confirming the USB interface is correctly enumerated as a serial or HID device based on your configuration.
- Serial Verification
Verification
The RGB LED should light up according to the pattern defined in your code. The serial port should display startup messages. If the board is recognized as a USB device but the LED does not react, check the internal LED pins in the schematic (not provided here, refer to Bitmerse documentation).
Going Further
Explore enabling Arm TrustZone to secure your authentication applications. Test the debug pads with an appropriate JTAG/SWD adapter for low-level control.
Other tutorials for this board
Code examples for this board
romu-rgb-led-pwm.inoC/C++ (Pico SDK)romu-hid-keyboard-macro.inoC/C++ (TinyUSB)romu-internal-flash-storage.inoC/C++ (Pico SDK)romu-midi-controller.inoC/C++ (TinyUSB)romu-secure-boot-check.inoC/C++ (Pico SDK)romu-hid-custom-keyboard.inoC++ (Arduino)