English
Language : 

Z8F0830HH020SG Datasheet, PDF (154/257 Pages) Zilog, Inc. – High-Performance 8-Bit Microcontrollers
Z8 Encore!® F0830 Series
Product Specification
136
Byte Read
To read a byte from the NVDS array, user code must first push the address onto the stack.
User code issues a CALL instruction to the address of the byte-read routine (0x2000). At
the return from the subroutine, the read byte resides in working register R0 and the read
status byte resides in working register R1. The bit fields of this status byte are defined in
Table 92. Additionally, the user code should pop the address byte off the stack.
The read routine uses 16 bytes of stack space in addition to the one byte of address pushed
by the user code. Sufficient memory must be available for this stack usage.
Due to the Flash memory architecture, NVDS reads exhibit a nonuniform execution time.
A read operation takes between 71 µs and 258 µs (assuming a 20 MHz system clock).
Slower system clock speeds result in proportionally higher execution times.
NVDS byte reads from invalid addresses (those exceeding the NVDS array size) return
0xff. Illegal read operations have a 6 µs execution time.
The status byte returned by the NVDS read routine is zero for a successful read. If the sta-
tus byte is nonzero, there is a corrupted value in the NVDS array at the location being
read. In this case, the value returned in R0 is the byte most recently written to the array
that does not have an error.
Table 92. Read Status Byte
Bit
Field
Default
Value
7
6
5
Reserved
0
0
0
4
3
2
DE Reserved FE
0
0
0
1
0
IGADDR Reserved
0
0
Bit
Description
[7:5]
Reserved
These bits are reserved and must be programmed to 000.
[4]
Data Error
DE
When reading an NVDS address, if an error is found in the latest data corresponding to this NVDS
address, this bit is set to 1. NVDS source code steps forward until it finds valid data at this address.
[3]
Reserved
This bit is reserved and must be programmed to 0.
[2]
Flash Error
FE
If a Flash error is detected, this bit is set to 1.
[1]
Illegal Address
IGADDR When NVDS byte reads from invalid addresses (those exceeding the NVDS array size) occur,
this bit is set to 1.
[0]
Reserved
This bit is reserved and must be programmed to 0.
PS025113-1212
NVDS Code Interface