
GD32F403xx User Manual
43
3.
Set MER bit in FMC_CTL0 register if erase Bank0 o nly. Set MER bit in FMC_CTL1
register if erase Bank1 only. Set MER bits in in FMC_CTL0 register and FMC_CTL1
register if erase entire flash;
4.
Send the mass erase command to the FMC by setting the START bit in FMC_CTL
register;
5.
Wait until all the operations have been finished by checking the value of the BUSY bit in
FMC_STATx registers;
6.
Read and verify the flash memory if required using a DBUS access.
When the operation is executed successfully, the ENDF in FMC_STATx registers is set, and
an interrupt will be triggered by FMC if the ENDIE bit in the FMC_CTLx registers is set. Since
all f lash data will be modified to a value of 0xFFFF_FFFF, the mass erase operation can be
implemented using a program that runs in SRAM or by using the debugging tool that accesses
the FMC registers directly.
For GD32F403xx with flash more than 512KB, the mass erase procedure applied to bank1 is
similar to the procedure applied to bank0.
Figure 2-2. Process of mass erase operation
indicates the mass erase operation flow.
Figure 2-2. Process of mass erase operation
Set the MER
bit(bits)
Is the LK bit is 0
Send the command
to FM C by set
START bit
Start
Yes
No
Unlock the
FMC_CTL
Is the BUSY bit is 0
Yes
No
Is the BUSY bit is 0
Yes
No
Finish
Содержание 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 ...