GigaDevice GD32C2
The GigaDevice GD32C2 series are 32-bit general-purpose microcontrollers based on the ARM Cortex-M23 processor.
Flash Banks
Flash Bank | Base address | J-Link Support | Loader | |
---|---|---|---|---|
Name | Size | |||
Internal flash | 0x08000000 | ![]() |
Default | up to 64 KB |
OTP Area | 0x1FFF7000 | ![]() |
Default | 1 KB |
Option Bytes | 0x1FFF7800 | ![]() |
Default | 128 B |
Watchdog Handling
- The device has a watchdog FWDGT.
- The watchdog is fed during flash programming.
Device Specific Handling
Connect
- If Security protection is set to high connecting is not possible and the connect is aborted.
- If Security protection is set to low the user is prompted to allow unsecuring.
- If Write Protection is configured the user is prompted to allow clearing it.
Reset
- The device uses normal Cortex-M reset, no special handling necessary, like described here.
Limitations
Option Byte programming
POR after OB programming
Programming the option bytes will program the option bytes into the flash memory.
In order for the changes to be reloaded into their registers and take effect
the user needs to peform a power-on-reset.
Verify of Option Bytes
The option bytes in flash memory contain complements, that can't be edited but are
automaticaly generated by the flash controller.
When performing a Verify on the OBs, differences in those complements are ignored.
Securing / locking the device and DCRP
The article GigaDevice GD32 contains J-Link Command files and binaries,
that can be used to set the GD32C2's Security protection to "LOW".
On GD32C2 devices if that security protection level is configured and no "Dedicated Code Read Protection" (DCRP) is configured,
the EREN bit in the FMC_EADDR0 register needs to be set.
For that case the <...>_noDCRP.<...> versions of those files can be used.