🛠 Débriquage FEL/xfel et boot SPI NOR sur le Lichee RV Dock

Sipeed Lichee RV Dock (Allwinner D1 / T-Head XuanTie C906) · avance · Schéma : IMG-sipeed-lichee-rv-dock-avance-3-licheerv-fel-xfel-spi-recovery.svg — chaîne de récupération du Lichee RV Dock : bouton FEL du Dock forçant le BROM Allwinner en mode FEL sur le port USB-C, outil xfel côté PC lisant la DRAM/exécutant un SPL en RAM, et pastille SPI NOR SOP8 soudée sur le Dock pour un boot autonome sans microSD

Objectives

When the microSD card is dead or the bootloader is corrupted, the D1 remains recoverable thanks to the Allwinner BROM: by holding the FEL button on the Dock and powering the module via USB-C, the chip waits for an FEL tool. The open-source utility xfel (xboot/xfel) speaks this protocol: read the chip ID, send an SPL+OpenSBI+U-Boot to DRAM, and start without touching the storage — the emergency door for rebriking the board, but also the production path: the Dock embeds an SPI NOR chip (SOP8 footprint) and the module has SD-NAND pads, for autonomous boot without a card. This tutorial covers both.

Hardware

Complete Code

# 1) Entrer en FEL : maintenir FEL, brancher l'USB-C, relâcher
lsusb | grep -i '1f3a:efe'          # Allwinner FEL (1f3a = sunxi)
sudo xfel version                    # version du BROM détectée
sudo xfel sid                        # ID unique de la puce

# 2) Démarrer un SPL en RAM sans toucher au stockage (ex. image Buildroot) :
sudo xfel write 0x200000 u-boot-sunxi-with-spl.bin   # adresse SPL D1
sudo xfel exec 0x200000                              # saute dedans
# -> U-Boot démarre sur la série, peut booter un kernel depuis l'USB/TFTP

# 3) Reprogrammer le SPI NOR (puce soudée sur l'empreinte SOP8 du Dock) :
sudo xfel spiflash id                # la NOR répond ?
sudo xfel spiflash erase 0 -l $((16*1024*1024))
sudo xfel spiflash write 0 u-boot-sunxi-with-spl.bin
#   puis retirer le mode FEL : le BROM boote le SPL SPI quand la microSD est absente

# 4) Dépannage bas niveau :
sudo xfel read 0x4100000 64 -o dram.bin   # lire la DRAM (test)
sudo xfel help spiflash

Expected Verification

By holding FEL during power-up, lsusb shows a 1f3a:efe8 device (BROM FEL) and sudo xfel version displays the BROM version — proof that the USB link is alive even on a "bricked" board. xfel write + xfel exec start U-Boot, visible on the serial console. After SPI programming and removing the microSD card, the board restarts alone on the NOR SPL: boot continues without a card, validating a setup without an accessible slot.

Common Errors

Other tutorials for this board

Code examples for this board

← Back to the board 🛠 All tutorials