GD32F403xx User Manual
48
bit is set and the ERRIE bit is also set to 1 to enable the corresponding interrupt, then the
Flash operation error interrupt will be triggered by the FMC to draw the attention of the CPU.
The page protection function can be individually enabled by configuring the WP [31:0] bit field
to 0 in the option bytes. If a page erase operation is executed on the option bytes block, all
the Flash Memory page protection functions will be disabled. When WP in the option bytes is
modified, a system reset followed is necessary.
2.3.11.
Security protection
The FMC provides a security protection f unction to prevent illegal code/data access on the
Flash memory. This function is useful for protecting the software/firmware from illegal users.
No protection: when setting SPC byte and its complement value to 0x5AA5, no protection
perf ormed. The main f lash and option bytes block are accessible by all operations.
Under protection: when setting SPC byte and its complement value to any value except
0x5AA5, the security protection is performed. Note that a power reset should be followed
instead of a system reset if the SPC modification is performed while the debug module is still
connected to JTAG/SWD device. Under the security protection, the main f lash can only be
accessed by user code and the f irst 4KB f lash is under erase/program protection. In debug
mode, boot f rom SRAM or boot f rom boot loader mode, all operations to main f lash is
f orbidden. If a read operation to main f lash in debug, boot from SRAM or boot f rom boot loader
mode, a bus error will be generated. If a program/erase operation to main f lash in debug
mode, boot from SRAM or boot f rom boot loader mode, the WPERR bit in FMC_STATx
registers will be set. Option bytes block are accessible by all operations, which can be used
to disable the security protection. If program back to no protection level by setting SPC byte
and its complement value to 0x5AA5, a mass erase for main flash will be performed.
Содержание GD32F403 Series
Страница 1: ...GigaDevice Semiconductor Inc GD32F403xx Arm Cortex M4 32 bit MCU User Manual Revision 2 6 Jul 2022 ...
Страница 177: ...GD32F403xx UserManual 177 Peripheral Channel 0 Channel 1 Channel 2 Channel 3 Channel 4 SDIO SDIO ...
Страница 217: ...GD32F403xx UserManual 217 ensures that no conversion is in progress ...