
AT32F413
Series Reference Manual
2022.06.27
Page 77
Rev 2.00
5.7.2
Flash unlock register (FLASH_UNLOCK)
For Flash memory bank 1.
Bit
Abbr.
Reset value
Type
Description
Bit 31: 0
UKVAL
0xXXXX XXXX wo
Unlock key value
This is used to unlock Flash memory bank 1.
Note: All these bits are write-only, and return 0 when being read.
5.7.3
Flash user system data unlock register
(FLASH_USD_UNLOCK)
Bit
Abbr.
Reset value
Type
Description
Bit 31: 0
USD_UKVAL
0xXXXX XXXX wo
User system data Unlock key value
Note: All these bits are write-only, and return 0 when being read.
5.7.4
Flash status register
(FLASH_STS)
For Flash memory bank 1 only.
Bit
Abbr.
Reset value
Type
Description
Bit 31: 6
Reserved
0x0000000
resd
Kept at its default value
Bit 5
ODF
0x0
rw
Operation done flag
This bit is set by hardware when Flash memory
operations (program/erase) is completed. It is cleared
by writing “1”.
Bit 4
EPPERR
0x0
rw
Erase/program protection error
This bit is set by hardware when programming the
erase/program- protected Flash memory address. It is
cleared by writing “1”.
Bit 3
Reserved
0x0
resd
Kept at its default value.
Bit 2
PRGMERR
0x0
rw
Programming error
When the programming addess is not “0xFFFF”, this bit is
set by hardware. It is cleared by writing “1”.
Bit 1
Reserved
0x0
resd
Kept at its default value.
Bit 0
OBF
0x0
ro
Operation busy flag
When this bit is set, it indicates that Flash memory
operation is in process. It is cleared when operation is
completed.
5.7.5
Flash control register (FLASH_CTRL)
For Flash memory bank 1 only.
Bit
Register
Reset value
Type
Description
Bit 31: 13 Reserved
0x00000
resd
Kept at its default value
Bit 12
ODFIE
0x0
rw
Operation done flag interrupt enable
0: Interrupt is disabled;
1: Interrupt is enabled.
Bit 11,8,3 Reserved
0x0
resd
Kept its default value
Bit 10
ERRIE
0x0
rw
Error interrupt enable
This bit enables EPPERR or PROGERR interrupt.
0: Interrupt is disabled;
1: Interrupt is enabled.
Bit 9
USDULKS
0x0
rw
User system data unlock success
This bit is set by hardware when the user system data is
unlocked properly, indicating that erase/program operation
to the user system data is allowed. This bit is cleared by
writing “0”, which will re-lock the user system data area.
Bit 7
OPLK
0x1
rw
Operation lock
This bit is set by default, indicating that Flash memory is