AT32F425
Series Reference Manual
2022.03.30
Page 65
Ver 2.01
5
Flash memory controller (FLASH)
5.1 FLASH introduction
Flash memory is divided into three parts: main Flash memory, information block and Flash memory
registers.
Main Flash memory is up to 64 KB
Information block consists of 4 KB boot loader and the user system data area. The boot loader
uses USART1 or USART2 for ISP programming.
Main Flash memory contains bank 1 (64 KB), including 64 pages, 1K per page.
Table 5-1 Flash memory architecture(64 K)
Bank
Name
Address range
Main memory
Bank1
(64 KB)
Page 0
0x0800 0000 – 0x0800 03FF
Page 1
0x0800 0400 – 0x0800 07FF
Page 2
0x0800 0800 – 0x0800 0BFF
…
…
Page 63
0x0800 FC00 – 0x0800 FFFF
Information block
4 KB boot loader
0x1FFF E400 – 0x1FFF F3FF
512 B user system data
0x1FFF F800 – 0x1FFF F9FF
Main Flash memory contains bank 1 (32 KB), including 32 pages, 1K per page.
Table 5-2 Flash memory architecture(32 K)
Bank
Name
Address range
Main memory
Bank1
(32 KB)
Page 0
0x0800 0000 – 0x0800 03FF
Page 1
0x0800 0400 – 0x0800 07FF
Page 2
0x0800 0800 – 0x0800 0BFF
…
…
Page 31
0x0800 FC00 – 0x0800 FFFF
Information block
4 KB boot loader
0x1FFF E400 – 0x1FFF F3FF
512 B user system
data
0x1FFF F800 – 0x1FFF F9FF
User system data area
The system data will be read from the information block of Flash memory whenever a system reset
occurs, and is saved in the user system data register (FLASH_USD)and erase programming protection
status register (FLASH_EPPS).
Each system data occupies two bytes, where the low bytes corresponds to the contents in the system
data area, and the high bytes represent the inverse code that is used to verify the correctness of the
selected bit. When the high byte is not equal to the inverse code of the low byte (except when both high
and low byte are all 0xFF), the system data loader will issue a system data error flag (USDERR) and the
corresponding system data and their inverse codes are forced 0xFF.
Note: The update of the contents in the user system data area becomes effective only after a
system reset.
Table 5-3
User system data area
Address
Bit
Description
0x1FFF_F800
[7: 0]
FAP[7:0]: Flash memory access protection (Access protection
enable/disable result is stored in the FLASH_USD[1] register and bit
[26]
0xA5: Flash access protection disabled
0XCC: High-level Flash access protection enabled
Others; Low-level Flash access protection enabled\
Note: SWD is disabled as soon as high-level Flash access protection
is enabled.