Skip to content

V3.0

Latest

Choose a tag to compare

@vanvught vanvught released this 12 Sep 15:50
· 1 commit to main since this release

TFTP Bootloader Release Notes

This release contains a broad update of the shared GD32 firmware libraries and TFTP bootloader targets.
The main focus has been on consolidating common GD32 functionality, simplifying platform-specific code, improving Ethernet PHY link handling, and making the firmware and flashing workflow more consistent across the supported GD32 families.
The bootloader projects for GD32F10x, GD32F20x, GD32F4xx and GD32H7xx have been updated to use the revised shared libraries.

Highlights

  • Added a Windows flash.cmd wrapper for the Python GD32 flashing utility. It automatically locates Python, creates a virtual environment when required, installs pyserial, and runs the flashing tool.
  • Improved bootloader safety by detecting an empty application image before attempting to start it.
  • Consolidated GD32 timer, delay and uptime functionality.
  • Moved GD32 internal flash/FMC operations into the common GD32 library.
  • Refactored Ethernet PHY link detection and link-state handling.
  • Modernized flash and storage interfaces using C++ namespaces and std::span.
  • Improved build-time selection of GD32 MCU capabilities, time sources, Ethernet options and PHY configuration.
  • Numerous consistency, debug, const-correctness and conditional-compilation cleanups.

Library Overview

lib-gd32
The GD32 hardware support library received the largest update.
Timer, SysTick, delay and uptime implementations have been consolidated into the gd32_timers interface, providing common microsecond, millisecond and uptime functionality.
Internal FMC flash support has been moved into this library behind the shared gd32::fmc API, with family-specific implementations where required.
GPIO helpers and GD32-specific debug support have been reorganized, MCU capability definitions and device mappings have been updated, and several low-level platform and timer edge cases have been corrected.

lib-flashcode
GD32 flash programming now uses the shared gd32::fmc implementation from lib-gd32 instead of maintaining separate FMC implementations inside the flashcode library.
Flash read, write and erase paths received additional range, alignment and state checks. The flash/storage interfaces were also updated to use std::span where appropriate.
lib-emac / network
Ethernet PHY link handling has been consolidated into the PHY layer.
Link initialization, polling and interrupt-driven link detection now share a common implementation. PHY address and status handling have been centralized, and MAC link configuration is performed only after a valid link and completed auto-negotiation are detected.
Ethernet timing and debug output were also updated to use the new GD32 timer API.

lib-spiflash
The SPI flash interface has been modernized from the older C-style API to the C++ spi::flash and spi::flash::cmd namespaces.
Constants now follow the common naming conventions, flash operation timeouts use millisecond timing, and probe/read/write/erase call sites have been updated accordingly.

lib-configstore / storage
Flash and configuration storage paths were updated to use the revised flash interfaces and std::span.
Long-running flash operations have improved timeout/watchdog handling, and several debug and boundary checks were cleaned up.

lib-hal
I2C interfaces received const-correctness and API cleanup. The AT24Cxx EEPROM support was simplified and dedicated AT24C02 and AT24C16 convenience classes were added.

lib-remoteconfig / JSON
Remote configuration JSON output now performs additional validation of output buffers.
Shared parsing and utility functions are used in more places, reducing duplicated string/number parsing code.

Common utilities
Shared utility code has been reorganized and simplified.
Common math, floating-point, string, bitfield and unit helpers are now used instead of local or duplicated implementations. The custom include/algorithm replacement was removed.
A shared common::kUndefined value replaces duplicated "Undefined" strings across several protocol libraries.
Debug helpers were also improved, including more consistent configuration flags, I2C detection control and generalized bit-dump formatting.

Build System
The GD32 build configuration has been cleaned up and made more consistent across MCU families.
MCU capability definitions, PHY selection, Ethernet link-check configuration and time-source selection are now handled more centrally. Device mappings were corrected and expanded, and several bootloader targets now use the common GD32 makefile and linker-script structure.

Supported Bootloader Targets
The changes have been propagated across the GD32F107RC, GD32F207RG, GD32207C-EVAL, GD32F407RE, GD32F450VI, GD32F470VG and GD32H759I-EVAL TFTP bootloader projects.