Low-Power Consumption: 60 mW
Fast Instruction Pointer: 0.75 µ s
■
■
Two Standby Modes: STOP and HALT
■
Digital Inputs CMOS Levels, Schmitt-Triggered
■
Software Programmable Low EMI Mode
ICROCONTROLLER
S
PECIFICATION
1
■
Software Enabled Watch-Dog Timer (WDT)
■
Push-Pull/Open-Drain Programmable on
Port 0, Port 1, and Port 2
■
24/32 Input/Output Lines
■
Auto Latches
■
Auto Power-On Reset (POR)
GENERAL DESCRIPTION
The Z86E30/E31/E40 8-Bit One-Time Programmable
(OTP) Microcontrollers are members of Zilog's single-chip
®
Z8
MCU family featuring enhanced wake-up circuitry,
programmable Watch-Dog Timers, Low Noise EMI options, and easy hardware/software system expansion capability.
Four basic address spaces support a wide range of memory configurations. The designer has access to three additional control registers that allow easy access to register
mapped peripheral and I/O circuits.
■
Two Programmable 8-Bit Counter/Timers Each
with a 6-Bit Programmable Prescaler
■
Six Vectored, Priority Interrupts from Six
Different Sources
■
Two Comparators
■
On-Chip Oscillator that Accepts a Crystal, Ceramic
Resonator, LC, RC, or External Clock Drive
For applications demanding powerful I/O capabilities, the
Z86E30/E31 have 24 pins, and the Z86E40 has 32 pins of
dedicated input and output. These lines are grouped into
four ports, eight lines per port, and are configurable under
software control to provide timing, status signals, and parallel I/O with or without handshake, and address/data bus
for interfacing external memory.
Notes: All signals with a preceding front slash, “/”, are
active Low. For example, B/W
(BYTE is active Low, only).
(WORD is active Low); B/W
DS97Z8X0502
P R E L I M I N A R Y
1
2
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
Power connections follow conventional descriptions below:
Ambient Temperature under Bias–40+105C
Storage Temperature–65+150C
Voltage on any Pin with Respect to V
Voltage on V
Voltage on XTAL1 and RESET
Pin with Respect to V
DD
Pins with Respect to VSS [Note 2]–0.6VDD+1V
Total Power Dissipation1.21W
Maximum Allowable Current out of V
Maximum Allowable Current into V
Maximum Allowable Current into an Input Pin [Note 3]–600+600µA
Maximum Allowable Current into an Open-Drain Pin [Note 4]–600+600µA
Maximum Allowable Output Current Sinked by Any I/O Pin25mA
Maximum Allowable Output Current Sourced by Any I/O Pin25mA
Maximum Allowable Output Current Sinked by RESET
Notes:
1. This applies to all pins except XTAL pins and where otherwise noted.
2. There is no input protection diode from pin to V
3. This excludes XTAL pins.
4. Device pin is not at an output Low state.
[Note 1]–0.6+7V
SS
SS
SS
DD
–0.3+7V
220mA
180mA
Pin3 mA
.
DD
Stresses greater than those listed under Absolute Maximum Ratings may cause permanent damage to the device. This is a stress rating only; functional operation of the
device at any condition above those indicated in the operational sections of these specifications is not implied. Exposure to absolute maximum rating conditions for an extended period may affect device reliability.
STANDARD TEST CONDITIONS
The characteristics listed below apply for standard test
conditions as noted. All voltages are referenced to
Ground. Positive current flows into the referenced pin
(Test Load).
Total power dissipation should not exceed 1.2 W for the
package. Power dissipation is calculated as follows:
Total Power Dissipation = VDD x [ IDD – (sum of IOH) ]
+ sum of [ (VDD – VOH) x IOH ]
+ sum of (V0L x I0L)
From Output
Under Test
150 pF
Figure 13. Test Load Diagram
12P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
ZilogZ8 4K OTP Microcontroller
CAPACITANCE
TA = 25°C, VCC = GND = 0V, f = 1.0 MHz; unmeasured pins returned to GND.
1. Device does function down to the Auto Reset voltage.
2. GND=0V
3. The V
4. All outputs unloaded, I/O pins floating, inputs at rail.
5. CL1= CL2 = 22 pF
6. Same as note [4] except inputs at V
7. Max. temperature is 70°C.
8. STD Mode (not Low EMI Mode)
9. Auto Latch (mask option) selected
10. For analog comparator inputs when analog comparators are
11. Clock must be forced Low, when XTAL1 is clock driven and XTAL2
12. Typicals are at V
13. Z86E40 only
14. WDT running
Auto Latch
Low Current
Auto Latch
High Current
Power On Reset3.5V
3.5V
5.5V
3.5V
5.5V
5.5V
0.7
1.4
-0.6
-1
3.0
2.0
Auto Reset Voltage2.33.12.9V1,7
voltage specification of 5.5V guarantees 5.0V ± 0.5V and
CC
the V
enabled.
is floating.
voltage specification of 3.5V guarantees only 3.5V.
CC
CC.
= 5.0V and VCC = 3.5V
CC
20
25
8
8
7.0
7.0
10
10
800
800
8
15
-5
-8
24
13
Typical
@ 25°CUnitsConditionsNotes
7
20
3.7
3.7
2.9
2.9
2
3
600
600
mAmA@ 16 MHz
@ 16 MHz
mAmAVIN = 0V, VCC
@ 16 MHz
mAmAClock Divide by
16 @ 16 MHz
µA
VIN = 0V, VCC
µA
V
= 0V, V
µA
µA
IN
VIN = 0V, V
VIN = 0V, V
CC
CC
CC
4,5
4,5
4,5
4,5
4,5
4,5
6,11
6,11
6,11,1
4
6,11,1
4
2.4
4.7
-1.8
-3.8
7
4
µAµA0V <VIN<V
0V <VIN<V
µAµA0V<VIN<V
0V<VIN<V
ms
ms
CC
CC
CC
CC
9
9
9
9
14P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
ZilogZ8 4K OTP Microcontroller
TA=–40 °C to +105 °C
SymParameter
V
CH
Clock Input High
Voltage
V
CL
Clock Input Low
Voltage
V
IH
V
IL
V
OH
Input High Voltage4.5V
Input Low Voltage4.5V
Output High
Voltage Low EMI
Mode
V
V
OH1
OL
Output High Voltage4.5V
Output Low Voltage
Low EMI Mode
V
V
V
OL1
OL2
RH
Output Low Voltage4.5V
Output Low Voltage4.5V
Reset Input High
Voltage
V
OLR
Reset Output Low
Voltage
V
OFFSET
Comparator Input
Offset V oltage
V
ICR
Input Common
Mode V oltage
Range
I
IL
I
OL
I
IR
I
CC
I
CC1
Input Leakage4.5V
Output Leakage4.5V
Reset Input Current4.5V
Supply Current4.5V
Standby Current
Halt Mode
V
CC
Note [3]MinMax
4.5V
5.5V
4.5V
5.5V
5.5V
5.5V
4.5V
5.5V
0.7 V
CC
0.7 V
CC
GND-0.3
GND-0.3
0.7 V
CC
0.7 V
CC
GND-0.3
GND-0.3
VCC -0.4
V
-0.4
CC
VCC+0.3
V
+0.3
CC
0.2 V
0.2 V
VCC+0.3
V
+0.3
CC
0.2 V
0.2 V
VCC -0.4
4.5V
4.5V
5.5V
V
-0.4
CC
0.4
0.4
0.4
5.5V
0.4
1.2
5.5V
3.5V
5.5V
3.5V
5.5V
4.5V
5.5V
4.5V
5.5V
5.5V
5.5V
5.5V
.8 V
.8 V
-18
-18
CC
CC
0
0
-1
-1
-1
-1
1.2
V
CC
V
CC
0.6
0.6
25
25
VCC-1.5V
V
-1.5V
CC
2
2
2
2
-180
-180
25
5.5V
4.5V
5.5V
25
8
8
CC
CC
CC
CC
Typical
@ 25°CUnitsConditionsNotes
2.5
2.5
1.5
1.5
2.5
2.5
1.5
1.5
4.8
4.8
4.8
4.8
0.2
0.2
0.1
0.1
0.5
0.5
1.7
2.1
0.3
0.2
10
10
<1
<1
<1
<1
-112
-112
20
20
3.7
VVDriven by External
Clock Generator
VVDriven by External
Clock Generator
V
V
V
V
VVI
VVI
= – 0.5 mA
OH
I
= – 0.5 mA
OH
= -2.0 mA
OH
I
= -2.0 mA
OH
VVIOL = 1.0 mA
I
= 1.0 mA
OL
VVIOL = + 4.0 mA
I
= +4.0 mA
OL
VVIOL = + 12 mA
I
= + 12 mA
OL
V
V
VVIOL = 1.0 mA
I
= 1.0 mA
OL
mV
mV
V
V
µAµAVIN = 0V, V
VIN = 0V, V
µAµAVIN = 0V, V
VIN = 0V, V
CC
CC
CC
CC
µA
µA
mAmA@ 16 MHz
@ 16 MHz
mAmAVIN = 0V, VCC
13
13
13
13
10
10
4,5
4,5
4,5
@ 16 MHz
3.7
V
= 0V, VCC
IN
4,5
8
8
8
8
8
8
8
8
@ 16 MHz
I
CC2
I
ALL
Standby Current
(Stop Mode)
Auto Latch Low
Current
4.5V
5.5V
4.5V
5.5V
1.4
1.4
10
10
20
20
2
3
4.7
4.7
µAµAVIN = 0V, VCC
V
= 0V, V
IN
µAµA0V < VIN < V
0V < VIN < V
CC
CC
CC
6,11,14
6,11,14
9
9
DS97Z8X0502P R E L I M I N A R Y15
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
DC ELECTRICAL CHARACTERISTICS (Continued)
TA=–40 °C to +105 °C
V
CC
SymParameter
I
ALH
Auto Latch High
Current
T
POR
V
LV
1. Device does function down to the Auto Reset voltage.
2. GND=0V
3. The V
4. All outputs unloaded, I/O pins floating, inputs at rail.
5. CL1= CL2 = 22 pF
6. Same as note [4] except inputs at VCC.
7. Maximum temperature is 70°C
8. STD Mode (not Low EMI Mode)
9. Auto Latch (mask option) selected
10. For analog comparator inputs when analog comparators are
11. Clock must be forced Low, when XTAL1 is clock driven and XTAL2
12. Typicals are at V
13. Z86E40 only
14. WDT is not running.
Power On Reset4.5V
Auto Reset Voltage2.03.32.9V1
voltage specification of 5.5V guarantees 5.0V ± 0.5V.
CC
enabled.
is floating.
= 5.0V
CC
Note [3]MinMax
4.5V
5.5V
5.5V
-1.0
-1.0
2.0
2.0
-10
-10
14
14
Typical
@ 25°CUnitsConditionsNotes
-3.8
-3.8
4
4
µAµA0V < VIN < V
0V < VIN < V
mS
mS
CC
CC
9
9
16P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
ZilogZ8 4K OTP Microcontroller
R/W , DM
Port 0
Port 1
AS
DS
(Read)
Port1
12
183
A7 - A0D7 - D0 IN
21
4
5
17
13
19
16
811
6
20
9
10
D7 - D0 OUTA7 - A0
DS
(Write)
14
7
Figure 14. External I/O or Memory Read/Write Timing
Z86E40 Only
15
DS97Z8X0502P R E L I M I N A R Y17
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
DC ELECTRICAL CHARACTERISTICS (Continued)
TA = 0°C to 70°C
16 MHz
Note [3]
NoSymbolParameter
1TdA(AS)Address Valid to AS Rise
Delay
2TdAS(A)AS Rise to Address Float
Delay
3TdAS(DR)AS Rise to Read Data Req’d
V alid
4TwASAS Low Width3.5V
5TdAS(DS)Address Float to DS Fall3.5V
6TwDSRDS (Read) Low Width3.5V
7TwDSWDS (Write) Low Width3.5V
8TdDSR(DR)DS Fall to Read Data Req’d
Valid
9ThDR(DS)Read Data to DS Rise Hold
Time
10TdDS(A)DS Rise to Address Active
Delay
11TdDS(AS)DS Rise to AS Fall Delay3.5V
12TdR/W(AS)R/W Valid to AS Rise Delay3.5V
13TdDS(R/W)DS Rise to R/W Not Valid3.5V
14TdDW(DSW) Write Data Valid to DS Fall
(Write) Delay
15TdDS(DW)DS Rise to Write Data Not
Valid Delay
16TdA(DR)Address Valid to Read Data
Req’d Valid
17TdAS(DS)AS Rise to DS Fall Delay3.5V
18TdDM(AS)DM Valid to AS Fall Delay3.5V
20ThDS(AS)DS Valid to Address Valid
Hold Time
Notes:
1. When using extended memory timing, add 2 TpC.
2. Timing numbers given are for minimum TpC.
3. The V
the V
Standard Test Load
All timing references use 0.7 V
For Standard Mode (not Low-EMI Mode for outputs) with SMR D1 = 0, D0 = 0.
voltage specification of 5.5V guarantees 5.0V ±0.5V and
CC
voltage specification of 3.5V guarantees only 3.5V
CC
for a logic 1 and 0.2 VCC for a logic 0.
CC
V
CC
3.5V
5.5V
3.5V
5.5V
3.5V
5.5V
5.5V
5.5V
5.5V
5.5V
3.5V
5.5V
3.5V
5.5V
3.5V
5.5V
5.5V
5.5V
5.5V
3.5V
5.5V
3.5V
5.5V
3.5V
5.5V
5.5V
5.5V
3.5V
5.5V
MinMaxUnitsNotes
25
25
35
35
40
40
0
0
135
135
80
80
0
0
50
50
35
35
25
25
35
35
55
55
35
35
45
45
30
30
35
35
180
180
75
75
25
25
230
230
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
2
2
1,2
2
1,2
1,2
1,2
2
2
2
2
2
2
2
1,2
2
2
18P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
ZilogZ8 4K OTP Microcontroller
TA = -40°C to 105°C
16 MHz
Note [3]
NoSymbolParameter
1TdA(AS)Address Valid to AS Rise
Delay
2TdAS(A)ASAS Rise to Address Float
Delay
3TdAS(DR)AS Rise to Read Data Req’d
V alid
4TwASAS Low Width4.5V
5TdAS(DS)Address Float to DS Fall4.5V
6TwDSRDS (Read) Low Width4.5V
7TwDSWDS (Write) Low Width4.5V
8TdDSR(DR)DS Fall to Read Data Req’d
Valid
9ThDR(DS)Read Data to DS Rise Hold
Time
10TdDS(A)DS Rise to Address Active
Delay
11TdDS(AS)DS Rise to AS Fall Delay4.5V
12TdR/W(AS)R/W Valid to AS Rise Delay4.5V
13TdDS(R/W)DS Rise to R/W Not Valid4.5V
14TdDW(DSW) Write Data Valid to DS Fall
(Write) Delay
15TdDS(DW)DS Rise to Write Data Not
Valid Delay
16TdA(DR)Address Valid to Read Data
Req’d Valid
17TdAS(DS)AS Rise to DS Fall Delay4.5V
18TdDM(AS)/DM Valid to AS Fall Delay4.5V
20ThDS(AS)DS Valid to Address Valid
Hold Time
Notes:
1. When using extended memory timing, add 2 TpC.
2. Timing numbers given are for minimum TpC.
3. The V
the V
Standard Test Load
All timing references use 0.7 V
For Standard Mode (not Low-EMI Mode for outputs) with SMR, D1 = 0, D0 = 0.
voltage specification of 5.5V guarantees 5.0V ±0.5V and
CC
voltage specification of 3.5V guarantees only 3.5V
CC
for a logic 1 and 0.2 VCC for a logic 0.
CC
V
CC
4.5V
5.5V
4.5V
5.5V
4.5V
5.5V
5.5V
5.5V
5.5V
5.5V
4.5V
5.5V
4.5V
5.5V
4.5V
5.5V
5.5V
5.5V
5.5V
4.5V
5.5V
4.5V
5.5V
4.5V
5.5V
5.5V
5.5V
4.5V
5.5V
MinMaxUnitsNotes
25
25
35
35
40
40
0
0
135
135
80
80
0
0
50
50
35
35
25
25
35
35
55
55
35
35
45
45
30
30
35
35
180
180
75
75
25
25
230
230
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
2
2
1,2
2
1,2
1,2
1,2
2
2
2
2
2
2
2
1,2
2
2
DS97Z8X0502P R E L I M I N A R Y19
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
DC ELECTRICAL CHARACTERISTICS (Continued)
Clock
TIN
IRQN
Clock
Setup
Stop
Mode
Recovery
Source
77
8
1
223
4
5
6
9
10
3
11
Figure 15. Additional Timing Diagram
20P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
ZilogZ8 4K OTP Microcontroller
Additional Timing Table (Divide-By-One Mode)
TA = 0 °C to +70 °C TA = -40 °C to +105 °C
4 MHz4 MHz
V
CC
NoSymbolParameter
1TpCInput Clock Period3.5V
2T rC ,TfCClock Input Rise &
Fall Times
3TwCInput Clock Width3.5V
4TwTinLTimer Input Low
Width
5TwTinHTimer Input High
Width
6TpTinTimer Input Period3.5V
7TrTin, TfTin Timer Input Rise
& Fall Timer
8ATwILInt. Request Low
Time
8BTwILInt. Request Low
Time
9TwIHInt. Request Input
High Time
10TwsmSTOP Mode
Recovery Width
Spec
11TostOscillator Startup
Time
Notes:
1. Timing Reference uses 0.7 V
2. Interrupt request via Port 3 (P31–P33).
3. Interrupt request via Port 3 (P30).
4. SMR-D5 = 1, POR STOP Mode Delay is on.
5. Reg. WDTMR.
6. The V
the V
7. SMR D1 = 0.
8. Maximum frequency for internal system clock is 4 MHz when
using XTAL divide-by-one mode.
9. For RC and LC oscillator, and for oscillator driven by clock driver.
voltage specification of 5.5V guarantees 5.0V ± 0.5V and
CC
voltage specification of 3.5V guarantees 3.5V only.
CC
for a logic 1 and 0.2 VCC for a logic 0.
CC
Note [6]MinMaxMinMaxUnitsNotes
5.5V
3.5V
5.5V
5.5V
3.5V
5.5V
3.5V
5.5V
5.5V
3.5V
5.5V
3.5V
5.5V
3.5V
5.5V
3.5V
5.5V
3.5V
5.5V
3.5V
5.5V
250
250
100
100
100
70
5TpC
5TpC
8TpC
8TpC
100
70
5TpC
5TpC
5TpC
5TpC
12
12
DC
DC
25
25
100
100
5TpC
5TpC
250
250
100
100
100
70
5TpC
5TpC
8TpC
8TpC
100
70
5TpC
5TpC
5TpC
5TpC
12
12
DC
DC
25
25
ns
ns
ns
ns
ns
ns
ns
ns
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
100
100
ns
ns
ns
ns
1,7,8
1,7,8
1,2,7,8
1,2,7,8
1,3,7,8
1,3,7,8
1,2,7,8
1,2,7,8
ns
ns
4,8
4,8
5TpC4,8,9
DS97Z8X0502P R E L I M I N A R Y21
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
DC ELECTRICAL CHARACTERISTICS (Continued)
Handshake Timing Diagrams
Data In
DAV
(Input)
RDY
(Output)
Data Out
Data In Valid
1
7
Next Data In Valid
2
3
Delayed DAV
456
Delayed RDY
Figure 16. Input Handshake Timing
Data Out Valid
Next Data Out Valid
DAV
(Output)
RDY
(Input)
89
10
Figure 17. Output Handshake Timing
Delayed DAV
11
Delayed RDY
22P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
ZilogZ8 4K OTP Microcontroller
Additional Timing Table
TA = -40 °C to +105 °C
16 MHz
V
CC
NoSymbolParameter
1TpCInput Clock Period3.5V
2TrC,TfCClock Input Rise &
Fall Times
3TwCInput Clock Width3.5V
4TwTinLTimer Input Low
Width
5TwTinHTimer Input High
Width
6TpTinTimer Input Period3.5V
7TrTin, TfTin Timer Input Rise
& Fall Timer
8ATwILInt. Request Low
Time
8BTwILInt. Request Low
Time
9TwIHInt. Request Input
High Time
10TwsmSTOP Mode
Recovery Width
Spec
11TostOscillator Startup
Time
12T wdtWatch-Dog Timer
Delay Time
Before Timeout
Notes:
1. Timing Reference uses 0.7 V
2. Interrupt request via Port 3 (P31–P33)
3. Interrupt request via Port 3 (P30)
4. SMR-D5 = 1, POR STOP Mode Delay is on
5. Reg. WDTMR
6. The V
7. SMR D1 = 0
8. Maximum frequency for internal system clock is 4 MHz when using
XTAL divide-by-one mode.
9. For RC and LC oscillator, and for oscillator driven by clock driver.
10. Standard Mode (not Low EMI output ports)
11. Using internal RC
voltage spec. of 5.5V guarantees 5.0V ± 0.5V.
CC
for a logic 1 and 0.2 VCC for a logic 0.
CC
Note [6]MinMaxUnitsConditionsNotes
5.5V
3.5V
5.5V
5.5V
3.5V
5.5V
3.5V
5.5V
5.5V
3.5V
5.5V
3.5V
5.5V
3.5V
5.5V
3.5V
62.5
62.5
31
31
70
70
5TpC
5TpC
8TpC
8TpC
70
70
5TpC
5TpC
5TpC1,2,7,8
DC
DC
15
15
100
100
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
ns
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,7,8
1,2,7,8
1,2,7,8
1,3,7,8
1,3,7,8
5.5V
3.5V
5.5V
3.5V
5.5V
3.5V
5.5V
3.5V
5.5V
3.5V
5.5V
3.5V
5.5V
12
12
10
5
20
10
40
20
160
80
5TpC
5TpC
ns
ns
ms
ms
ms
ms
ms
ms
ms
ms
D0 = 0
D1 = 0
D0 = 1
D1 = 0
D0 = 0
D1 = 1
D0 = 1
D1 = 1
4,8
4,8
4,8
4,8
5,11
5,11
5,11
5,11
5,11
5,11
5,11
5,11
DS97Z8X0502P R E L I M I N A R Y23
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
PIN FUNCTIONS
R/W
EPROM Programming Mode
D7–D0 Data Bus. The data can be read from or written to
external memory through the data bus.
A11–A0 Address Bus. During programming, the EPROM
address is written to the address bus.
VCC Power Supply. This pin must supply 5V during the
EPROM read mode and 6V during other modes.
CE Chip Enable (active Low). This pin is active during
EPROM Read Mode, Program Mode, and Program Verify
Mode.
OE Output Enable (active Low). This pin drives the direction of the Data Bus. When this pin is Low, the Data Bus is
output, when High, the Data Bus is input.
EPM EPROM Program Mode. This pin controls the different EPROM Program Mode by applying different voltages.
Program Voltage. This pin supplies the program volt-
V
PP
age.
PGM Program Mode (active Low). When this pin is Low,
the data is programmed to the EPROM through the Data
Bus.
Application Precaution
The production test-mode environment may be enabled
accidentally during normal operation if excessive noise
surges above VCC occur on pins XTAL1 and RESET.
In addition, processor operation of Z8 OTP devices may be
affected by excessive noise surges on the VPP, CE, EPM,
OE pins while the microcontroller is in Standard Mode.
Recommendations for dampening voltage surges in both
test and OTP mode include the following:
Read/Write (output, write Low). The R/W signal is
Low when the CCP is writing to the external program or
data memory (Z86E40 only).
RESET Reset (input, active Low). Reset will initialize the
MCU. Reset is accomplished either through Power-On,
Watch-Dog Timer reset, STOP-Mode Recovery, or external reset. During Power-On Reset and Watch-Dog Timer
Reset, the internally generated reset drives the reset pin
low for the POR time. Any devices driving the reset line
must be open-drain in order to avoid damage from a possible conflict during reset conditions. Pull-up is provided internally. After the POR time, RESET
input.
To avoid asynchronous and noisy reset problems, the
Z86E40 is equipped with a reset filter of four external
clocks (4TpC). If the external reset signal is less than 4TpC
in duration, no reset occurs. On the fifth clock after the reset is detected, an internal RST signal is latched and held
for an internal register count of 18 external clocks, or for
the duration of the external reset, whichever is longer. During the reset cycle, DS is held active Low while AS cycles
at a rate of TpC/2. Program execution begins at location
000CH, 5–10 TpC cycles after RESET is released. For
Power-On Reset, the reset output time is 5 ms. The
Z86E40 does not reset WDTMR, SMR, P2M, and P3M
registers on a STOP-Mode Recovery operation.
ROMless (input, active Low). This pin, when connected to
GND, disables the internal ROM and forces the device to
function as a Z86C90/C89 ROMless Z8. (Note that, when
left unconnected or pulled High to VCC, the device functions normally as a Z8 ROM version).
Note: When using in ROM Mode in High EMI (noisy) environment, the ROMless pins should be connected directly
to VCC.
is a Schmitt-triggered
■Using a clamping diode to V
■Adding a capacitor to the affected pin
CC
Standard Mode
XTAL Crystal 1 (time-based input). This pin connects a
parallel-resonant crystal, ceramic resonator, LC, RC network, or external single-phase clock to the on-chip oscillator input.
XTAL2 Crystal 2 (time-based output). This pin connects a
parallel-resonant crystal, ceramic resonator, LC, or RC
network to the on-chip oscillator output.
24P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
ZilogZ8 4K OTP Microcontroller
Port 0 (P07–P00). Port 0 is an 8-bit, bidirectional, CMOS-
compatible I/O port. These eight I/O lines can be configured under software control as a nibble I/O port, or as an
address port for interfacing external memory. The input
buffers are Schmitt-triggered and nibble programmed. Either nibble output that can be globally programmed as
push-pull or open-drain. Low EMI output buffers can be
globally programmed by the software. Port 0 can be placed
under handshake control. In Handshake Mode, Port 3
lines P32 and P35 are used as handshake control lines.
The handshake direction is determined by the configuration (input or output) assigned to Port 0's upper nibble. The
lower nibble must have the same direction as the upper
nibble.
For external memory references, Port 0 provides address
bits A11–A8 (lower nibble) or A15–A8 (lower and upper
4
nibble) depending on the required address space. If the
address range requires 12 bits or less, the upper nibble of
Port 0 can be programmed independently as I/O while the
lower nibble is used for addressing. If one or both nibbles
are needed for I/O operation, they must be configured by
writing to the Port 0 mode register. In ROMless mode, after
a hardware reset, Port 0 is configured as address lines
A15–A8, and extended timing is set to accommodate slow
memory access. The initialization routine can include reconfiguration to eliminate this extended timing mode. In
ROM mode, Port 0 is defined as input after reset.
Port 0 can be set in the High-Impedance Mode if selected
as an address output state, along with Port 1 and the control signals AS
Port 0 (I/O)
, DS, and R/W (Figure 18).
Open-Drain
OEN
Out
In
4
Handshake Controls
/DAV0 and RDY0
(P32 and P35)
PAD
1.5 2.3V Hysteresis
Auto Latch
R 500 kΩ
Figure 18. Port 0 Configuration
DS97Z8X0502P R E L I M I N A R Y25
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
PIN FUNCTIONS (Continued)
Port 1 (P17–P10). Port 1 is an 8-bit, bidirectional, CMOS-
compatible port with multiplexed Address (A7–A0) and
Data (D7–D0) ports. These eight I/O lines can be programmed as inputs or outputs or can be configured under
software control as an Address/Data port for interfacing
external memory. The input buffers are Schmitt-triggered
and the output buffers can be globally programmed as either push-pull or open-drain. Low EMI output buffers can
be globally programmed by the software. Port 1 can be
placed under handshake control. In this configuration, Port
3, lines P33 and P34 are used as the handshake controls
MCU
RDY1 and /DAV1 (Ready and Data Available). To interface external memory, Port 1 must be programmed for the
multiplexed Address/Data mode. If more than 256 external
locations are required, Port 0 outputs the additional lines
(Figure 19).
Port 1 can be placed in the high-impedance state along
with Port 0, AS, DS, and R/W, allowing the Z86E40 to
share common resources in multiprocessor and DMA applications.
Port 2 (I/O)
Handshake Controls
DAV1 and RDY1
(P33 and P34)
Open-Drain
OEN
Out
In
PAD
1.5 2.3V Hysteresis
Auto Latch
R 500 kΩ
Figure 19. Port 1 Configuration (Z86E40 Only)
26P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
ZilogZ8 4K OTP Microcontroller
Port 2 (P27–P20). Port 2 is an 8-bit, bidirectional, CMOS-
compatible I/O port. These eight I/O lines can be configured under software control as an input or output, independently. All input buffers are Schmitt-triggered. Bits programmed as outputs can be globally programmed as
either push-pull or open-drain. Low EMI output buffers can
Z86E40
MCU
be globally programmed by the software. When used as an
I/O port, Port 2 can be placed under handshake control.
In Handshake Mode, Port 3 lines P31 and P36 are used as
handshake control lines. The handshake direction is determined by the configuration (input or output) assigned to bit
7 of Port 2 (Figure 20).
Port 2 (I/O)
Handshake Controls
DAV2 and RDY2
(P31 and P36)
Open-Drain
OEN
Out
In
PAD
TTL Level Shifter
Auto Latch
R ≈ 500 KΩ
Figure 20. Port 2 Configuration
DS97Z8X0502P R E L I M I N A R Y27
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
PIN FUNCTIONS (Continued)
Port 3 (P37–P30). Port 3 is an 8-bit, CMOS-compatible
port with four fixed inputs (P33–P30) and four fixed outputs
(P37–P34). These eight lines can be configured by software for interrupt and handshake control functions. Port 3,
Pin 0 is Schmitt- triggered. P31, P32, and P33 are standard CMOS inputs with single trip point (no Auto Latches)
and P34, P35, P36, and P37 are push-pull output lines.
Low EMI output buffers can be globally programmed by
the software. Two on-board comparators can process analog signals on P31 and P32 with reference to the voltage
on P33. The analog function is enabled by setting the D1
of Port 3 Mode Register (P3M). The comparator output can
be outputted from P34 and P37, respectively, by setting
PCON register Bit D0 to 1 state. For the interrupt function,
P30 and P33 are falling edge triggered interrupt inputs.
P31 and P32 can be programmed as falling, rising or both
edges triggered interrupt inputs (Figure 21). Access to
Counter/Timer 1 is made through P31 (T
(T
). Handshake lines for Port 0, Port 1, and Port 2 are
OUT
) and P36
IN
also available on Port 3 (Table 9).
Note: When enabling/ or disabling analog mode, the following is recommended:
1.Allow two NOP delays before reading this comparator
output.
2.Disable global interrupts, switch to analog mode, clear
interrupts, and then re-enable interrupts.
3.IRQ register bits 3 to 0 must be cleared after enabling
analog mode.
Note: P33–P30 differs from the Z86C30/C31/C40 in that
there is no clamping diode to V
due to the EPROM high-
CC
voltage circuits. Exceeding the VIH maximum specification
during standard operating mode may cause the device to
enter EPROM mode.
Comparator Inputs. Port 3, P31, and P32, each have a
comparator front end. The comparator reference voltage
P33 is common to both comparators. In analog mode, P31
and P32 are the positive input of the comparators and P33
is the reference voltage of the comparators.
Auto Latch. The Auto Latch puts valid CMOS levels on all
CMOS inputs (except P33–P31) that are not externally
driven. Whether this level is 0 or 1, cannot be determined.
A valid CMOS level, rather than a floating node, reduces
excessive supply current flow in the input buffer. Auto
Latches are available on Port 0, Port 2, and P30. There
are no Auto Latches on P31, P32, and P33.
Low EMI Emission. The Z86E40 can be programmed to
operate in a low EMI Emission Mode in the PCON register.
The oscillator and all I/O ports can be programmed as low
EMI emission mode independently. Use of this feature results in:
■The pre-drivers slew rate reduced to 10 ns typical.
■Low EMI output drivers have resistance of 200 Ohms
(typical).
■Low EMI Oscillator.
■Internal SCLK/TCLK= XTAL operation limited to a
maximum of 4 MHz – 250 ns cycle time, when Low EMI
Oscillator is selected and system clock (SCLK = XTAL,
SMR Reg. Bit D1 =1).
■Note for emulation only:
Do not set the emulator to emulate Port 1 in low EMI
mode. Port 1 must always be configured in Standard
Mode.
30P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
ZilogZ8 4K OTP Microcontroller
FUNCTIONAL DESCRIPTION
The MCU incorporates the following special functions to
enhance the standard Z8 architecture to provide the user
with increased design flexibility.
RESET. The device is reset in one of three ways:
1.Power-On Reset
2.Watch-Dog Timer
3.STOP-Mode Recovery Source
Note: Having the Auto Power-On Reset circuitry built-in,
the MCU does not need to be connected to an external
power-on reset circuit. The reset time is 5 ms (typical). The
MCU does not reinitialize WDTMR, SMR, P2M, and P3M
registers to their reset values on a STOP-Mode Recovery
operation.
65535
4096
4095
On-Chip One Time PROM
EPROMROMless
External
ROM and RAM
Note: The device VCC must rise up to the operating V
CC
specification before the TPOR expires.
Program Memory. The MCU can address up to 4 KB of
Internal Program Memory (Figure 22). The first 12 bytes of
program memory are reserved for the interrupt vectors.
These locations contain six 16-bit vectors that correspond
to the six available interrupts. For EPROM mode, byte 12
(000CH) to address 4095 (0FFFH) consists of programmable EPROM. After reset, the program counter points at
the address 000CH, which is the starting address of the
user program.
In ROMless mode, the Z86E40 can address up to 64 KB
of External Program Memory. The ROM/ROMless option
is only available on the 44-pin devices.
External
ROM and RAM
Location of
First Byte of
Instruction
Executed
After RESET
Interrupt
Vector
(Lower Byte)
Interrupt
Vector
(Upper Byte)
12
11
10
IRQ5
IRQ5
9
8
7
6
5
4
3
2
1
0
IRQ4
IRQ4
IRQ3
IRQ3
IRQ2
IRQ2
IRQ1
IRQ1
IRQ0
IRQ0
Figure 22. Program Memory Map
(ROMless Z86E40 Only)
EPROM Protect. When in ROM Protect Mode, and exe-
cuting out of External Program Memory, instructions LDC,
LDCI, LDE, and LDEI cannot read Internal Program Memory.
When in ROM Protect Mode and executing out of Internal
Program Memory, instructions LDC, LDCI, LDE, and LDEI
can read Internal Program Memory.
DS97Z8X0502P R E L I M I N A R Y31
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
FUNCTIONAL DESCRIPTION (Continued)
Data Memory (DM). In EPROM Mode, the Z86E40 can
address up to 60 KB of external data memory beginning at
location 4096. In ROMless mode, the Z86E40 can address
up to 64 KB of data memory. External data memory may
be included with, or separated from, the external program
memory space. DM, an optional I/O function that can be
EPROMROMless
65535
External
Data
Memory
programmed to appear on pin P34, is used to distinguish
between data and program memory space (Figure 23).
The state of the DM signal is controlled by the type of instruction being executed. An LDC opcode references
PROGRAM (DM inactive) memory, and an LDE instruction
references data (DM active Low) memory.
External
Data
Memory
4096
4095
Not Addressable
0
Figure 23. Data Memory Map
32P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
ZilogZ8 4K OTP Microcontroller
Register File. The register file consists of three I/O port
registers, 236/125 general-purpose registers, 15 control
and status registers, and three system configuration registers in the expanded register group. The instructions can
access registers directly or indirectly through an 8-bit address field. This allows a short 4-bit register address using
the Register Pointer (Figure 24). In the 4-bit mode, the register file is divided into 16 working register groups, each
R253 RP
D7 D6 D5 D4 D3 D2 D1 D0
Default setting after RESET = 00000000
Figure 24. Register Pointer Register
Expanded Register File (ERF). The register file has been
expanded to allow for additional system control registers,
mapping of additional peripheral devices and input/output
ports into the register address area. The Z8 register address space R0 through R15 is implemented as 16 groups
of 16 registers per group (Figure 26). These register
groups are known as the Expanded Register File (ERF).
occupying 16 continuous locations. The Register Pointer
addresses the starting location of the active working-register group.
Note: Register Bank E0–EF can only be accessed through
working register and indirect addressing modes. (This
bank is available in Z86E30/E40 only.)
Expanded Register Group
Working Register Group
The low nibble (D3–D0) of the Register Pointer (RP) select
the active ERF group, and the high nibble (D7–D4) of register RP select the working register group. Three system
configuration registers reside in the Expanded Register
File at bank FH: PCON, SMR, and WDTMR. The rest of
the Expanded Register is not physically implemented and
is reserved for future expansion.
DS97Z8X0502P R E L I M I N A R Y33
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
FUNCTIONAL DESCRIPTION (Continued)
r7 r6 r5 r4R253
r3 r2 r1 r0
The upper nibble of the register file address
provided by the register pointer specifies
the active working-register group.
FF
Register Group F
F0
EF
80
7F
70
6F
60
5F
50
4F
40
3F
30
2F
20
1F
10
0F
Specified Working
Register Group
Register Group 1
Register Group 0
(Register Pointer)
Note: Registers 80H
through EFH are
available in the Z86C30
only.
The lower nibble
of the register
file address
provided by the
instruction points
to the specified
register.
R15 to R0
R15 to R4*
00
* Expanded Register Group (0) is selected
in this figure by handling bits D3 to D0 as
"0" in Register R253 (RP).
General-Purpose Registers (GPR). These registers are
undefined after the device is powered up. The registers
keep their last value after any reset, as long as the reset
occurs in the VCC voltage-specified operating range. The
register R254 is general-purpose on Z86E30/E31. R254
and R255 are set to 00H after any reset or STOP-Mode
Recovery.
RAM Protect. The upper portion of the RAM's address
spaces 80H to EFH (excluding the control registers) can
be protected from reading and writing. This option can be
selected during the EPROM Programming Mode. After this
option is selected, the user can activate this feature from
the internal EPROM. D6 of the IMR control register (R251)
is used to turn off/on the RAM protect by loading a 0 or 1,
respectively. A “1” in D6 indicates RAM Protect enabled.
RAM Protect is not available on the Z86E31.
Stack. The Z86E40 external data memory or the internal
register file can be used for the stack. The 16-bit Stack
Pointer (R254–R255) is used for the external stack, which
can reside anywhere in the data memory for ROMless
mode, but only from 4096 to 65535 in ROM mode. An 8-bit
Stack Pointer (R255) is used for the internal stack on the
Z86E30/E31/E40 that resides within the 236 general-purpose registers (R4–R239). SPH (R254) can be used as a
general-purpose register when using internal stack only.
R254 and R255 are set to 00H after any reset or StopMode Recovery.
Counter/Timers. There are two 8-bit programmable
counter/timers (T0 and T1), each driven by its own 6-bit
programmable prescaler. The T1 prescaler is driven by internal or external clock sources; however, the T0 prescaler
is driven by the internal clock only (Figure 27).
The 6-bit prescalers can divide the input frequency of the
clock source by any integer number from 1 to 64. Each
prescaler drives its counter, which decrements the value
(1 to 256), that has been loaded into the counter. When the
counter reaches the end of count, a timer interrupt request,
IRQ4 (T0) or IRQ5 (T1), is generated.
The counters can be programmed to start, stop, restart to
continue, or restart from the initial value. The counters can
also be programmed to stop upon reaching zero (single
pass mode) or to automatically reload the initial value and
continue counting (modulo-n continuous mode).
The counters, but not the prescalers, can be read at any
time without disturbing their value or count mode. The
clock source for T1 is user-definable and can be either the
internal microprocessor clock divided by four, or an external signal input through Port 3. The Timer Mode register
configures the external timer input (P31) as an external
clock, a trigger input that can be retriggerable or non-retriggerable, or as a gate input for the internal clock. Port 3 line
P36 serves as a timer output (T
or the internal clock can be output. The counter/timers can
be cascaded by connecting the T0 output to the input of
T1.
) through which T0, T1,
OUT
36P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
ZilogZ8 4K OTP Microcontroller
OSC
D1 (SMR)
D0 (SMR)
÷ 2
÷ 16
Clock
Logic
Internal
Clock
External Clock
÷4
Internal Data Bus
WriteWriteRead
÷4
PRE0
Initial Value
Register
6-Bit
Down
Counter
6-Bit
Down
Counter
T0
Initial Value
Register
8-bit
Down
Counter
8-Bit
Down
Counter
Current Value
Register
÷2
T0
IRQ4
TOUT
P36
IRQ5
TIN P31
Internal Clock
Gated Clock
Triggered Clock
PRE1
Initial Value
Register
WriteWriteRead
T1
Initial Value
Register
Internal Data Bus
Figure 27. Counter/Timer Block Diagram
T1
Current Value
Register
DS97Z8X0502P R E L I M I N A R Y37
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
FUNCTIONAL DESCRIPTION (Continued)
Interrupts. The MCU has six different interrupts from six
different sources. The interrupts are maskable and prioritized (Figure 28). The six sources are divided as follows:
four sources are claimed by Port 3 lines P33–P30) and two
in counter/timers. The Interrupt Mask Register globally or
individually enables or disables the six interrupt requests
(Table 10).
When more than one interrupt is pending, priorities are resolved by a programmable priority encoder that is controlled by the Interrupt Priority Register (IPR). An interrupt
machine cycle is activated when an interrupt request is
granted. Thus, disabling all subsequent interrupts, saves
the Program Counter and Status Flags, and then branches
to the program memory vector location reserved for that interrupt. All interrupts are vectored through locations in the
program memory. This memory location and the next byte
contain the 16-bit starting address of the interrupt service
routine for that particular interrupt request.
To accommodate polled interrupt systems, interrupt inputs
are masked and the interrupt request register is polled to
determine which of the interrupt requests need service.
An interrupt resulting from AN1 is mapped into IRQ2, and
an interrupt from AN2 is mapped into IRQ0. Interrupts
IRQ2 and IRQ0 may be rising, falling or both edge triggered, and are programmable by the user. The software
may poll to identify the state of the pin.
Programming bits for the Interrupt Edge Select are located
in bits D7 and D6 of the IRQ Register (R250). The
configuration is shown in Table 11.
Table 11. IRQ Register Configuration
IRQInterrupt Edge
D7D6P31P32
00FF
01FR
10RF
11R/FR/F
Notes:
F = Falling Edge
R = Rising Edge
Clock. The on-chip oscillator has a high-gain, parallel-resonant amplifier for connection to a crystal, RC, ceramic
resonator, or any suitable external clock source (XTAL1 =
Input, XTAL2 = Output). The crystal should be AT cut, 10
KHz to 16 MHz max, with a series resistance (RS) less
than or equal to 100 Ohms.
The crystal should be connected across XTAL1 and
XTAL2 using the vendor's recommended capacitor values
from each pin directly to device pin Ground. The RC oscillator option can be selected in the programming mode.
The RC oscillator configuration must be an external resistor connected from XTAL1 to XTAL2, with a frequency-setting capacitor from XTAL1 to Ground (Figure 29).
XTAL1
C1
XTAL2
C2
Ceramic Resonator or
Crystal
C1, C2 = 47 pF TYP *
F = 8 MHz
* Typical value including pin parasitics
C1
C2
LC
C1, C2 = 22 pF
L = 130 µH *
F = 3 MHz *
Figure 29. Oscillator Configuration
XTAL1
C1
LR
XTAL2
RC
@ 5V Vcc (TYP)
C1 = 100 pF
R = 2K
F = 6 MHz
XTAL1
XTAL2
External Clock
XTAL1
XTAL2
DS97Z8X0502P R E L I M I N A R Y39
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
FUNCTIONAL DESCRIPTION (Continued)
Power-On Reset (POR). A timer circuit clocked by a ded-
icated on-board RC oscillator is used for the Power-On Reset (POR) timer function. The POR timer allows VCC and
the oscillator circuit to stabilize before instruction execution begins.
The POR timer circuit is a one-shot timer triggered by one
of three conditions:
1.Power fail to Power OK status
2.Stop-Mode Recovery (if D5 of SMR=0)
3.WDT time-out
The POR time is a nominal 5 ms. Bit 5 of the STOP mode
Register (SMR) determines whether the POR timer is bypassed after STOP-Mode Recovery (typical for an external
clock and RC/LC oscillators with fast start up times).
HALT. Turns off the internal CPU clock, but not the XTAL
oscillation. The counter/timers and external interrupt IRQ0,
IRQ1, and IRQ2 remain active. The device is recovered by
interrupts, either externally or internally generated. An interrupt request must be executed (enabled) to exit HALT
Mode. After the interrupt service routine, the program continues from the instruction after the HALT.
In order to enter STOP or HALT Mode, it is necessary to
first flush the instruction pipeline to avoid suspending execution in mid-instruction. To do this, the user must execute
a NOP (Opcode=FFH) immediately before the appropriate
sleep instruction, that is:
FF NOP; clear the pipeline
6F STOP; enter STOP Mode
or
FF NOP; clear the pipeline
7F HALT; enter HALT Mode
STOP. This instruction turns off the internal clock and external crystal oscillation and reduces the standby current
to 10 microamperes or less. STOP Mode is terminated by
one of the following resets: either by WDT time-out, POR,
a Stop-Mode Recovery Source, which is defined by the
SMR register or external reset. This causes the processor
to restart the application program at address 000CH.
Port Configuration Register (PCON). The PCON register configures the ports individually; comparator output on
Port 3, open-drain on Port 0 and Port 1, low EMI on Ports
0, 1, 2 and 3, and low EMI oscillator. The PCON register is
located in the expanded register file at Bank F, location 00
(Figure 30).
PCON (FH) 00H
D7 D6 D5 D4 D3 D2 D1 D0
* Default Setting After Reset
Figure 30. Port Configuration Register (PCON)
(Write Only)
Comparator Output Port 3
0 P34, P37 Standard Output*
1 P34, P37 Comparator Output
0 Port 1 Open Drain
1 Port 1 Push-pull Active*
0 Port 0 Open Drain
1 Port 0 Push-pull Active*
0 Port 0 Low EMI
1 Port 0 Standard*
0 Port 1 Low EMI
1 Port 1 Standard*
0 Port 2 Low EMI
1 Port 2 Standard*
0 Port 3 Low EMI
1 Port 3 Standard*
Low EMI Oscillator
0 Low EMI
1 Standard*
40P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
ZilogZ8 4K OTP Microcontroller
Comparator Output Port 3 (D0). Bit 0 controls the com-
parator output in Port 3. A “1” in this location brings the
comparator outputs to P34 and P37, and a “0” releases the
Port to its standard I/O configuration. The default value
is 0.
Port 1 Open-Drain (D1). Port 1 can be configured as an
open-drain by resetting this bit (D1=0) or configured as
push-pull active by setting this bit (D1=1). The default value is 1.
Port 0 Open-Drain (D2). Port 0 can be configured as an
open-drain by resetting this bit (D2=0) or configured as
push-pull active by setting this bit (D2=1). The default value is 1.
Low EMI Port 0 (D3). Port 0 can be configured as a Low
EMI Port by resetting this bit (D3=0) or configured as a
Standard Port by setting this bit (D3=1). The default value
is 1.
Low EMI Port 1 (D4). Port 1 can be configured as a Low
EMI Port by resetting this bit (D4=0) or configured as a
Standard Port by setting this bit (D4=1). The default value
is 1. Note: The emulator does not support Port 1 low EMI
mode and must be set D4 = 1.
Low EMI Port 3 (D6). Port 3 can be configured as a Low
EMI Port by resetting this bit (D6=0) or configured as a
Standard Port by setting this bit (D6=1). The default value
is 1.
Low EMI OSC (D7). This bit of the PCON Register controls the low EMI noise oscillator. A “1” in this location configures the oscillator with standard drive. While a “0” configures the oscillator with low noise drive, however, it does
not affect the relationship of SCLK and XTAL. The low EMI
mode will reduce the drive of the oscillator (OSC). The default value is 1. Note: 4 MHz is the maximum external
clock frequency when running in the low EMI oscillator
mode.
Stop-Mode Recovery Register (SMR). This register
selects the clock divide value and determines the mode of
Stop-Mode Recovery (Figure 31). All bits are Write Only
except bit 7 which is a Read Only. Bit 7 is a flag bit that is
hardware set on the condition of STOP Recovery and
reset by a power-on cycle. Bit 6 controls whether a low or
high level is required from the recovery source. Bit 5
controls the reset delay after recovery. Bits 2, 3, and 4 of
the SMR register specify the Stop-Mode Recovery Source.
The SMR is located in Bank F of the Expanded Register
Group at address 0BH.
Low EMI Port 2 (D5). Port 2 can be configured as a Low
EMI Port by resetting this bit (D5=0) or configured as a
Standard Port by setting this bit (D5=1). The default value
is 1.
Stop Mode Recovery Source
000 POR and/or External Reset
001 P30
010 P31
011 P32
100 P33
101 P27
110 P2 NOR 0:3
111 P2 NOR 0:7
Stop Delay
0 OFF
1 ON
Stop Recovery Level
0 Low
1 High
Stop Flag
0 POR
1 Stop Recovery
* Default setting after RESET.
** Default setting after RESET and STOP-Mode Recovery.
**
*
*
*
*
Figure 31. STOP-Mode Recovery Register
(Write-Only Except Bit D7, Which is Read-Only)
42P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
ZilogZ8 4K OTP Microcontroller
SCLK/TCLK Divide-by-16 Select (D0). This bit of the
SMR controls a divide-by-16 prescaler of SCLK/TCLK.
The purpose of this control is to selectively reduce device
power consumption during normal processor execution
(SCLK control) and/or HALT mode (where TCLK sources
counter/timers and interrupt logic).
External Clock Divide-by-Two (D1). This bit can eliminate the oscillator divide-by-two circuitry. When this bit is
0, the System Clock (SCLK) and Timer Clock (TCLK) are
equal to the external clock frequency divided by two. The
SCLK/TCLK is equal to the external clock frequency when
this bit is set (D1=1). Using this bit together with D7 of
SMR2 D1 D0
0 0
VDD
PCON further helps lower EMI (i.e., D7 (PCON) = 0, D1
(SMR) = 1). The default setting is zero.
STOP-Mode Recovery Source (D2, D3, and D4). These
three bits of the SMR register specify the wake up source
of the STOP-Mode Recovery (Figure 32). Table 12 shows
the SMR source selected with the setting of D2 to D4.
P33–P31 cannot be used to wake up from STOP mode
when programmed as analog inputs. When the STOPMode Recovery sources are selected in this register then
SMR2 register bits D0, D1 must be set to zero.
Note: If the Port2 pin is configured as an output, this output
level will be read by the SMR circuitry.
P20
P23
SMR2SMR2D1 D0
0 1
P20
P27
D1 D0
1 0
SMR D4 D3 D2
0 0 0
VDD
Stop-Mode Recovery Edge
Select (SMR)
P33 From Pads
Digital/Analog Mode
Select (P3M)
SMRSMRSMRD4 D3 D2
P30
P31
P32
0 0 1
0 1 0
0 1 1
P33P27
D4 D3 D2
1 0 0
D4 D3 D2
1 0 1
P20
P23
SMRSMRD4 D3 D2
1 1 0
Figure 32. Stop-Mode Recovery Source
D4 D3 D2
1 1 1
P20
P27
To POR
RESET
To P33 Data
Latch and IRQ1
MUX
DS97Z8X0502P R E L I M I N A R Y43
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
FUNCTIONAL DESCRIPTION (Continued)
Table 12. Stop-Mode Recovery Source
D4D3D2SMR Source selection
000POR recovery only
001P30 transition
010P31 transition (Not in analog
mode)
011P32 transition (Not in analog
mode)
100P33 transition (Not in analog
mode)
101P27 transition
110Logical NOR of P ort 2 bits 0–3
111Logical NOR of P ort 2 bits 0–7
Stop-Mode Recovery Delay Select (D5). The 5 ms RESET delay after Stop-Mode Recovery is disabled by programming this bit to a zero. A “1” in this bit will cause a 5
ms RESET delay after Stop-Mode Recovery. The default
condition of this bit is 1. If the fast wake up mode is selected, the Stop-Mode Recovery source needs to be kept active for at least 5TpC.
Stop-Mode Recovery Level Select (D6). A “1” in this bit
defines that a high level on any one of the recovery sources wakes the MCU from STOP Mode. A 0 defines low level
recovery. The default value is 0.
Cold or Warm Start (D7). This bit is set by the device
upon entering STOP Mode. A “0” in this bit indicates that
the device has been reset by POR (cold). A “1” in this bit
indicates the device was awakened by a SMR source
(warm).
Stop-Mode Recovery Register 2 (SMR2). This register
contains additional Stop-Mode Recovery sources. When
the Stop-Mode Recovery sources are selected in this register then SMR Register. Bits D2, D3, and D4 must be 0.
SMR:10Operation
D1D0Description of Action
00POR and/or external reset recovery
01Logical AND of P20 through P23
10Logical AND of P20 through P27
Watch-Dog Timer Mode Register (WDTMR). The WDT
is a retriggerable one-shot timer that resets the Z8 if it
reaches its terminal count. The WDT is disabled after Power-On Reset and initially enabled by executing the WDT instruction and refreshed on subsequent executions of the
WDT instruction. The WDT is driven either by an on-board
RC oscillator or an external oscillator from XTAL1 pin. The
POR clock source is selected with bit 4 of the WDT register.
Note: Execution of the WDT instruction affects the Z (Zero), S (Sign), and V (Overflow) flags.
WDT Time-Out Period (D0 and D1). Bits 0 and 1 control
a tap circuit that determines the time-out periods that can
be obtained (Table 13). The default value of D0 and D1
are 1 and 0, respectively.
WDT During HALT Mode (D2). This bit determines
whether or not the WDT is active during HALT Mode. A “1”
indicates that the WDT is active during HALT. A “0” disables the WDT in HALT Mode. The default value is “1”.
WDT During STOP Mode (D3). This bit determines
whether or not the WDT is active during STOP mode. A “1”
indicates active during STOP. A “0” disables the WDT during STOP Mode. This is applicable only when the WDT
clock source is the internal RC oscillator.
Clock Source For WDT (D4). This bit determines which
oscillator source is used to clock the internal POR and
WDT counter chain. If the bit is a 1, the internal RC oscillator is bypassed and the POR and WDT clock source is
driven from the external pin, XTAL1, and the WDT is
stopped in STOP Mode. The default configuration of this
bit is 0, which selects the RC oscillator.
Permanent WDT. When this feature is enabled, the WDT
is enabled after reset and will operate in Run and Halt
Mode. The control bits in the WDTMR do not affect the
WDT operation. If the clock source of the WDT is the internal RC oscillator, then the WDT will run in STOP mode. If
the clock source of the WDT is the XTAL1 pin, then the
WDT will not run in STOP mode.
Note: WDT time-out in STOP Mode will not reset
SMR,SMR2,PCON, WDTMR, P2M, P3M, Ports 2 & 3 Data
Registers.
WDTMR Register Accessibility. The WDTMR register is
accessible only during the first 60 internal system clock
RC OSC
Time-out of
the System
Clock
44P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
g
ZilogZ8 4K OTP Microcontroller
cycles from the execution of the first instruction after
Power-On Reset, Watch-Dog reset or a STOP-Mode
Recovery (Figures 33 and 34). After this point, the register
cannot be modified by any means, intentional or
WDTMR (F) 0F
D7 D6 D5 D4 D3 D2 D1 D0
* Default settin
after RESET
otherwise. The WDTMR cannot be read and is located in
Bank F of the Expanded Register Group at address
location 0FH.
WDT TAP INT RC OSC System Clock
00 5 ms 128 SCLK
01 10 ms 256 SCLK
*
10 20 ms 512 SCLK
11 80 ms 2048 SCLK
WDT During HALT
0 OFF
*
1 ON
WDT During STOP
0 OFF
1 ON
*
XTAL1/INT RC Select for WDT
0 On-Board RC
1 XTAL
Reserved (Must be 0)
*
Figure 33. Watch-Dog Timer Mode Register
Write Only
DS97Z8X0502P R E L I M I N A R Y45
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
FUNCTIONAL DESCRIPTION (Continued)
Reset
WDT Select
(WDTMR)
CLK Source
Select
(WDTMR)
XTAL
VDD
VLV
WDT
4 Clock
Filter
Internal
RC OSC.
2V Operating
Voltage Det.
+
-
Clear
CLK
M
U
X
5ms POR5ms
CK
18 Clock RESET
Generator
WDT TAP SELECT
15ms
WDT/POR Counter Chain
CLR
RESET
Internal
RESET
25ms 100ms
From Stop
Mode
Recovery
Source
Stop Delay
Select (SMR)
Figure 34. Resets and WDT
46P R E L I M I N A R YDS97Z8X0502
Z86E30/E31/E40
1
ZilogZ8 4K OTP Microcontroller
Auto Reset Voltage. An on-board Voltage Comparator
checks that VCC is at the required level to ensure correct
operation of the device. Reset is globally driven if VCC is
below VLV (Figure 35).
VCC
(Volts)
3.7
3.5
3.3
3.1
2.9
2.7
2.5
Note: VCC must be in the allowed operating range prior to
the minimum Power-On Reset time-out (T
POR
).
2.3
-60-40-20020406080100120140
Temperature
Figure 35. Typical Z86E40 VLV V oltage vs. T emperature
(°C)
DS97Z8X0502P R E L I M I N A R Y47
Z86E30/E31/E40
Z8 4K OTP MicrocontrollerZilog
FUNCTIONAL DESCRIPTION (Continued)
EPROM MODE
Table 14 shows the programming voltages of each programming mode. Table 15, and figures that follow show
the programming timing of each programming mode. Figure 38 shows the circuit diagram of a Z86E40 programming adapter, which adapts from 2764A to Z86E40 and
Figure 39 shows the Z86E30/E31 Programming Adapter
Circuitry. Figure 40 shows the flowchart of an Intelligent
Programming Algorithm, which is compatible with 2764A
EPROM (Z86E40 is 4K EPROM, 2764A is 8K EPROM).
Since the EPROM size of Z86E30/E31/E40 differs from
2764A, the programming address range has to be set from
0000H to 0FFFH for the Z86E30/E40 and 0000H to 07FFH
for Z86E31. Otherwise, the upper portion of EPROM data
will overwrite the lower portion of EPROM data. Figure 39
shows the adaptation from the 2764A to Z86E30/E31.
Note: EPROM Protect feature allows the LDC, LDCI, LDE,
and LDEI instructions from internal program memory. A
ROM lookup table can be used with this feature.
During programming, the V
gramming voltage and current to the EPROM. This pin is
also used to latch which EPROM mode is to be used (R/W
EPROM or R/W Option bits). The mode is set by placing
the correct mode number on the least significant bits of the
address and raising the EPM pin above V. After a setup
time, the VPP pin can then be raised or lowered. The
latched EPROM mode will remain until the EPM pin is reduced below VH.
input pin supplies the pro-
PP
EPROM R/W mode allows the programming of the user
mode program ROM.
Option Bit R/W allows the programming of the Z8 option
bits. When the device is latched into Option Bit R/W mode,
the address must then be changed to 63 decimals
(000000111111 Binary). The Options are mapped into this
address as follows:
ZILOG, INC. MAKES NO WARRANTY, EXPRESS,
STATUTORY, IMPLIED OR BY DESCRIPTION,
REGARDING THE INFORMATION SET FORTH HEREIN
OR REGARDING THE FREEDOM OF THE DESCRIBED
DEVICES FROM INTELLECTUAL PROPERTY
INFRINGEMENT. ZILOG, INC. MAKES NO WARRANTY
OF MERCHANTABILITY OR FITNESS FOR ANY
PURPOSE.
Zilog, Inc. shall not be responsible for any errors that may
appear in this document. Zilog, Inc. makes no commitment
to update or keep current the information contained in this
document.
Zilog’s products are not authorized for use as critical
components in life support devices or systems unless a
specific written agreement pertaining to such intended use
is executed between the customer and Zilog prior to use.
Life support devices or systems are those which are
intended for surgical implantation into the body, or which
sustains life whose failure to perform, when properly used
in accordance with instructions for use provided in the
labeling, can be reasonably expected to result in
significant injury to the user.
Zilog, Inc. 210 East Hacienda Ave.
Campbell, CA 95008-6600
Telephone (408) 370-8000
FAX 408 370-8056
Internet: http://www.zilog.com
DS97Z8X0502P R E L I M I N A R Y65
Loading...
+ hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.