ST7265x
4 FLASH PROGRAM MEMORY
4.1 Introduction
The ST7 dual voltage High Density Flash
(HDFlash) is a non-volatile memory that can be
electrically erased as a single block or by individu-
al sectors and programmed on a Byte-by-Byte ba-
sis using an external VPP supply.
The HDFlash devices can be programmed and
erased off-board (plugged in a programming tool)
or on-board using ICP (In-Circuit Programming) or
IAP (In-Application Programming).
The array matrix organisation allows each sector
to be erased and reprogrammed without affecting
other sectors.
4.2 Main Features
s Three Flash programming modes:
– Insertion in a programming tool. In this mode,
all sectors including option bytes can be pro-
grammed or erased.
– ICP (In-Circuit Programming). In this mode, all
sectors including option bytes can be pro-
grammed or erased without removing the de-
vice from the application board.
– IAP (In-Application Programming) In this
mode, all sectors except Sector 0, can be pro-
grammed or erased without removing the de-
vice from the application board and while the
application is running.
s ICT (In-Circuit Testing) for downloading and
executing user application test patterns in RAM
s Read-out protection against piracy
s Register Access Security System (RASS) to
prevent accidental programming or erasing
Figure 12. Memory Map and Sector Address
4.3 Structure
The Flash memory is organised in sectors and can
be used for both code and data storage.
Depending on the overall Flash memory size in the
microcontroller device, there are up to three user
sectors (see Table 5). Each of these sectors can
be erased independently to avoid unnecessary
erasing of the whole Flash memory when only a
partial erasing is required.
The first two sectors have a fixed size of 4 Kbytes
(see Figure 12). They are mapped in the upper
part of the ST7 addressing space so the reset and
interrupt vectors are located in Sector 0 (F000h-
FFFFh).
Table 5. Sectors available in Flash devices
Flash Memory Size
(bytes)
4K
8K
> 8K
Available Sectors
Sector 0
Sectors 0,1
Sectors 0,1, 2
4.4 Program Memory Read-out Protection
The read-out protection is enabled through an op-
tion bit.
When this option is selected, the programs and
data stored in the program memory (Flash or
ROM) are protected against read-out piracy (in-
cluding a re-write protection). In Flash devices,
when this protection is removed by reprogram-
ming the Option Byte, the entire program memory
is first automatically erased and the device can be
reprogrammed.
Refer to the Option Byte description for more de-
tails.
4K
1000h
3FFFh
7FFFh
9FFFh
BFFFh
D7FFh
DFFFh
EFFFh
FFFFh
8K
10K
16K
24K
32K
48K
60K
DV FLASH
MEMORY SIZE
2 Kbytes
8 Kbytes 16 Kbytes 24 Kbytes 40 Kbytes 52 Kbytes
4 Kbytes
4 Kbytes
SECTOR 2
SECTOR 1
SECTOR 0
22/166
1