🛠 Booter sur NVMe (M.2 PCIe 3.0 x4) et récupérer une carte brique via MaskROM
Objectives
Install the root system on an NVMe SSD in the M.2 M-Key slot (2280, PCIe 3.0 x4, official throughput up to 2,000 MB/s), keep the bootloader in the SPI NOR for booting without an SD card, and know how to restore the board to serviceable state via the MaskROM button (RK3588 Recovery mode) if booting is broken. RK3588 boot order: SPI NOR → eMMC → microSD → USB; MaskROM forces recovery via USB.
Hardware
- Orange Pi 5 Plus + M.2 2280 NVMe SSD + 5 V / 4 A power supply (the NVMe under load adds to the current budget)
- Installation microSD card, or vendor image + RKDevTool under Windows for the official path
- USB-C data cable (Type-C data port, not the power port); MaskROM/Recovery/On-Off buttons
Full code
# 1. Depuis le système sur microSD : détecter le SSD et vérifier le lien PCIe Gen3
sudo fdisk -l | grep nvme # attendre /dev/nvme0n1
sudo dmesg | grep -i "pci.*link.*GT/s" # attendre « 8.0 GT/s PCIe » sur le port M-Key
sudo apt install -y fio
sudo mkfs.ext4 /dev/nvme0n1p1 2>/dev/null || sudo fdisk /dev/nvme0n1
sudo mkdir -p /mnt/nvme && sudo mount /dev/nvme0n1p1 /mnt/nvme
fio --name=nvme --rw=write --bs=1M --size=512M --direct=1 --runtime=30 \
--filename=/mnt/nvme/testfile --group_reporting # ~1500-2000 Mo/s attendus
# 2. Copier le système sur le SSD (méthode Armbian)
sudo apt install -y armbian-config
sudo armbian-install # cible NVMe/SCSI, puis flash SPI-NOR du loader
# (variante vendor wiki §2.6 : dd / RKDevTool ; variante classique : rsync + /etc/fstab)
sudo reboot
# 3. Récupération MaskROM (boot cassé) : carte hors tension,
# maintenir MaskROM, brancher USB-C data vers le PC, relâcher, puis :
sudo apt install -y rkdeveloptool
lsusb | grep -i '2207' # le RK3588 apparaît en « Rockchip USB RAM »
sudo rkdeveloptool ld # liste le périphérique en MaskROM
sudo rkdeveloptool wl 0x0 image-sdcard.img # réécrit la SPI NOR/eMMC selon la cible
sudo rkdeveloptool rd # redémarrage
Expected verification
After armbian-install and rebooting without an SD card, lsblk shows the root on /dev/nvme0n1 and dmesg confirms the 8.0 GT/s link. fio reaches 1,500–2,000 MB/s on a good Gen3 SSD. In MaskROM mode, lsusb shows a Rockchip device (vendor 0x2207) and rkdeveloptool ld lists it.
Common errors
- Downloading the wrong OpenWrt image: the wiki distinguishes the "SPI flash" image from the "TF card, eMMC and NVME SSD boot" image — take the one for the correct media.
- SSD not detected: check the module mounting (2280 screw), perform a MaskROM/Power wake-up to renegotiate the PCIe link, test another SSD.
- Confusing the two Type-C ports: flashing with RKDevTool/rkdeveloptool goes through the data port, not the power port.
- >
Other tutorials for this board
- Allumer une LED via le GPIO 40 broches (libgpiod)
- Lire un bouton poussoir et afficher dans la console
- Premier script Python : fiche signalétique de la carte et LED
- Variation d'intensité d'une LED avec PWM (sysfs pwm)
- Lire un capteur I2C (BMP280) depuis le bus du connecteur
- Exploiter le double Ethernet 2,5 GbE et sécuriser le SSH
Code examples for this board
clignotante.pyPythonbouton-gpio.pyPythoncapteur-i2c.shBashsurveillance-temperature.shBashcapteur-dht11.pyPythonservo-pwm-sysfs.shBash