🛠 Monter le module BPI-CM4 sur son carrier et réussir le premier boot
Objectives
The Banana Pi BPI-CM4 is not a standalone nano-computer: it is a compute module (55 × 40 mm, two 100-pin connectors, 4 M2.5 holes) built on the Amlogic A311D (4× Cortex-A73 + 2× Cortex-A53, Mali-G52 MP4, NPU 5 TOPS, 4 GB LPDDR4, 16 GB eMMC). You will install it on a Raspberry Pi CM4-compatible carrier, power it, and successfully complete the first boot under Armbian — without falling into the eMMC boot trap.
Hardware
- Banana Pi BPI-CM4 module (4 GB LPDDR4 / 16 GB eMMC)
- CM4-compatible carrier: BPI-CM4IO recommended (RJ45 GbE RTL8211F, 1× HDMI up to 4Kp60, 2× USB-A 2.0, USB-C OTG, mini-PCIe port + micro-SIM, 26-pin header, microSD slot) — Raspberry Pi CM4 carriers also work (Pin2Pin), but dual functions (2 HDMI, 2 CSI) do not work
- Quality 5 V / 3 A power supply (published measurements: 1.8 W idle, 4.1 W full load)
- microSD card (the slot is on the carrier, not on the module) + Armbian image for the bananapicm4io board
- Two u.FL antennas for WiFi (not included in the box)
Complete code
# 1) Insérer le module bien perpendiculairement dans les deux connecteurs
# 100 broches du carrier (comme un RPi CM4 : pas de socket, repères silk).
# 2) Sur le PC, flasher Armbian (carte : bananapicm4io, famille meson-g12b)
xzcat Armbian_*_BananaPi-CM4IO_*.img.xz | sudo dd of=/dev/sdX bs=4M status=progress conv=fsync
# 3) PIÈGE : le ROM Amlogic démarre l'eMMC EN PREMIER. Si l'eMMC contient un
# image bootable (Android 9, vieille image vendor), la SD est ignorée.
# Depuis un système qui boote, effacer l'eMMC :
sudo dd if=/dev/zero of=/dev/mmcblk0 bs=8M status=progress
# (ou « Erase all » avec l'aml-flash-tool / USB Burning Tool côté vendor)
# 4) Premier boot : alimenter en USB-C OTG, HDMI + Ethernet branchés
sudo nmtui # configurer le réseau
uname -a && ip -br link show eth0
Expected verification
HDMI display (up to 4Kp60), Armbian login created on first boot, uname -a showing a 6.x meson/g12b kernel, eth0 linked at 1 Gbit/s (Realtek RTL8211F PHY embedded on the module), and the blue LED (GPIOAO_7) in heartbeat mode.
Common errors
- Believing that the module works on its own: without a carrier, it has no power supply, no HDMI, no microSD, and no Ethernet.
- SD boot blocked by a bootable eMMC; a half-flashed eMMC can block the boot at BL2 (recovery: complete erasure, see code).
- 5 V / 2 A power supply too weak: reboots under load.
- CM4 carrier with dual HDMI or dual camera: the A311D is limited to 1 HDMI, 1 CSI, 1 DSI ("PIN limited" according to the wiki).
- Forgetting to screw in the u.FL antennas (or leaving the PCB antenna) before testing the RTL8822CS WiFi.
Other tutorials for this board
- Apprivoiser les LED et la touche ADC du carrier CM4IO
- Mesurer le stockage du BPI-CM4 : eMMC, microSD et le palier NVMe
- Activer I2C, SPI et UART sur le BPI-CM4 : env.txt ou armbianEnv.txt
- Brancher un capteur BME280 sur l'I2C1 du carrier (GPIOX_17/18)
- Déplacer le rootfs sur un SSD NVMe via le port mini-PCIe
- Exploiter le NPU 5 TOPS de l'A311D pour l'inférence embarquée
Code examples for this board
clignotante.pyPythonbouton-gpio.pyPythoncapteur-i2c.shBashsurveillance-temperature.shBashcapteur-dht11.pyPythonservo-pwm-sysfs.shBash