Copyright © 2008 by Zilog
®
, Inc. All rights reserved.
w
ww.zilog.com
Introduction
This Technical Note describes the differences in procedure when loading Flash memory on Zilog’s
Z8F640x and Z8F64xx microcontroller units (MCU). The Z8F64xx MCUs, which evolved from the
Z8F640x MCUs, offer better Flash protection and flexibility features by comparison.
General Overview of Z8 Encore! XP
®
Flash Memory
The Z8F640x and Z8F64xx MCU families each feature 64 KB (65,536 bytes) of non-volatile Flash
memory with read, write, and erase capability. Flash memory can be programmed and erased
in-circuit by either user code or through the On-Chip Debugger. The Flash memory array is arranged
as 512 bytes per page. A 512 bytes page is the minimum Flash block size that can be erased.
Flash Information Area
The Z8F64xx MCUs feature a 512 bytes Information Area, which is accessed by setting bit 7 of the
Flash Page Select Register to 1. When access is enabled, the Information Area is mapped into
Program Memory and overlays the 512 bytes in the address range
FE00h–FFFFh. When access to the
Information Area is enabled, a code instruction returns data from the Information Area. CPU
instructions are always fetched from Program Memory regardless of the setting of the Information
Area access bit. Access to the Information Area is Read-Only.
Table 1 describes the functions of each range of Program Memory addresses in the Z8F64xx MCU’s
Information Area.
The Z8F640x MCUs do not feature an Information Area.
Table 1. Z8F64xx Information Area Map
Program Memory Address (Hex) Function
FE00h–FE3Fh Reserved.
FE40h–FE53h Part Number—20 character ASCII alphanumeric code;
left-justified and filled with zeroes.
FE54h–FFFFh Reserved.
Note:
Technical Note
Comparing Z8 Encore! XP
®
F640x and
Z8 Encore! XP
®
F64xx Flash Loaders
TN003003-0308
TN003003-0308 Page 2 of 15
Comparing Z8 Encore! XP
®
F640x and Z8 Encore! XP
®
F64xx Flash
Loaders
Table 2 compares the Flash memory spaces of the Z8F640x MCU and the Z8F64xx MCU.
Table 3 compares the Flash address ranges of the Z8F640x MCU and the Z8F64xx MCU by sector.
Z8 Encore! XP
®
Flash Control Register Descriptions
There are a number of registers available in the Z8 Encore! XP MCU that provide access to Flash
memory. They are briefly described in this section.
Flash Control Register
The Flash Control Register (FCTL) unlocks the Flash Controller for programming and erase
operations. It also selects the Flash Sector Protect register on the Z8F64xx MCU. The Write-Only
Flash Control Register shares its register file address space with the Read-Only Flash Status Register.
Table 2. Flash Memory Configurations for Z8F640x and Z8F64xx MCUs
Z8 Encore!
XP MCU
Total Size of
Flash Memory
Number
of Pages
Program Memory
Addresses
Number
of Sectors
Pages
per
Sector
Size of Each
Sector
Z8F640x 64 KB (65,536) 128 0000h–FFFFh 1 16 8 KB (8192)
Z8F64xx 64 KB (65,536) 128 0000h–FFFFh 8 16 8 KB (8192)
Table 3. Flash Sector Address Ranges
Sector Number Z8F640x MCUs Z8F64xx MCUs
0 NA 0000h–1FFFh
1 NA 2000h–3FFFh
2 NA 4000h–5FFFh
3 NA 6000h–7FFFh
4 NA 8000h–9FFFh
5 NA A000h–BFFFh
6 NA C000h–DFFFh
7 E000h–FFFFh
(High Sector)
E000h–FFFFh