Hello world for a GD32VF103CBT6
RISC-V dev board.
Recent nightly toolchain with the corresponding target:
rustup default nightly
rustup target add riscv32imac-unknown-none-elf
- RISC-V GNU toolchain
- dfu-utils Important use the latest git version, see this issue
Install GNU toolchain on arch linux:
pacman -S riscv32-elf-gdb riscv32-elf-binutils
Inside this repo:
cargo xbuild && \
riscv32-elf-objcopy -O binary target/riscv32imac-unknown-none-elf/debug/gd32vf103 firmware.bin
Connect the board, while holding down then BOOT0
button shortly press the RESET
button to enter dfu bootloader mode. Flash using dfu-util:
sudo dfu-util -a 0 -s 0x08000000:leave -D firmware.bin
- pcein/rust-sipeed-longan-nano Thank you!
- gd32v-rust/gd32vf103-example Thank you!
- Datasheet, CPU Manual