ZILOG Z89C0010VSC, Z89C0015VSC Datasheet

Z89C00
16-BIT DIGITAL SIGNAL PROCESSOR
PRELIMINARY
DC 4083-00 1
ZILOG
FEATURES
P
RELIMINARY PRODUCT SPECIFICATION
16-Bit Single Cycle Instructions
Zero Overhead Hardware Looping
16-Bit Data
Ready Control for Slow Peripherals
Single Cycle Multiply/Accumulate (100 ns)
Six-Level Stack
512 Words of On-Chip RAM
Static Single-Cycle Operation
16-Bit I/O Port
4K Words of On-Chip Masked ROM
Three Vectored Interrupts
64K Words of External Program Address Space
Two Conditional Branch Inputs/Two User Outputs
24-Bit ALU, Accumulator and Shifter
IBM
®
PC Development Tools
GENERAL DESCRIPTION
The Z89C00 is a second generation, 16-bit, fractional, two’s complement CMOS Digital Signal Processor (DSP). Most instructions, including multiply and accumulate, are accomplished in a single clock cycle. The processor contains 1 Kbyte of on-chip data RAM (two blocks of 256 16-bit words), 4K words of program ROM and 64K words of program memory addressing capability. Also, the processor features a 24-bit ALU, a 16 x 16 multiplier, a 24-bit Accumulator and a shifter. Additionally, the processor contains a six-level stack, three vectored interrupts and two inputs for conditional program jumps. Each RAM block contains a set of three pointers which may be incremented or decremented automatically to affect hardware looping without software overhead. The data RAMs can be simultaneously addressed and loaded to the multiplier for a true single cycle multiply.
There is a 16-bit address and a 16-bit data bus for external program memory and data, and a 16-bit I/O bus for transferring data. Additionally, there are two general purpose user inputs and two user outputs. Operation with slow peripherals is accomplished with a ready input pin. The clock may be stopped to conserve power.
Z89C00
16-BIT DIGITAL SIGNAL PROCESSOR
Development tools for the IBM PC include a relocatable assembler, a linker loader, and an ANSI-C compiler. Also, the development tools include a simulator/debugger, a cross assembler for the TMS320 family assembly code and a hardware emulator.
To assist the user in understanding the Z89C00 DSP Q15 two's complement fractional multiplication, an application note has been included in this product specification as an appendix.
Notes:
All Signals with a preceding front slash, "/", are active Low, e.g., B//W (WORD is active Low); /B/W (BYTE is active Low, only).
Power connections follow conventional descriptions below:
Connection Circuit Device
Power V
CC
V
DD
Ground GND V
SS
Z89C00
16-BIT DIGITAL SIGNAL PROCESSOR
PRELIMINARY
2 DC 4083-00
ZILOG
GENERAL DESCRIPTION (Continued)
Register
Pointer
0-2
16-Bit Bus
Stack
ACC
24-Bit Bus
ALU
B
A
256 Word
RAM
1
16 x16
Multiplier
24-bit
Instruction
Register
PD
256 Word
RAM
0
Register
Pointer
4-6
PC
16-bit
I/O
Port
PA
MUX
4K Word ROM
D-Bus
Status
(5)
Switch
Shifter
24
P-Bus
EXT15-EXT0
Ready
Interrupt
/ROMEN
16
3
UI1-UI0 UO1-UO0
2
2
User Port
16
16
External Program ROM
16
16
PD15-PD0 PA15-PA0
INT2-INT0 /RESET
S-Bus
Switch
P
Y
X
ER//W, /EI
2
EA2-EA0
3
/RDYE
Figure 1. Functional Block Diagram
Z89C00
16-BIT DIGITAL SIGNAL PROCESSOR
PRELIMINARY
DC 4083-00 3
ZILOG
789
654321 10 11 12 13 14 15 16 17
18 19 20 21 22 23 24 25 26
68 67 66 65 64 63 62 61
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43
60 59 58 57 56 55 54 53 52 51 50 49 48 47 46 45 44
VSS
PD0 PD1 PD2 PD3
PD4
PD5 PD6 PD7 PD8 PD9
PD10 PD11 PD12 PD13 PD14
PD15
UO1 UO0 INT2 INT1
INT0 UI1
UI0
HALT
/ROMEN CLK /RES
/RDYE ER//W /EI EA2 EA1 EA0
Z89C00
PA0
PA1
PA2
PA3
PA4
PA5
PA6
PA7
PA8
PA9
PA10
PA11
VDD
PA12
PA13
PA14
PA15
EXT 15
EXT14
EXT13
EXT12
EXT 11
EXT 10
EXT9
EXT8
EXT7
EXT6
EXT5
EXT4
VSS
EXT3
EXT1
EXT0
EXT2
Figure 2. 68-Pin PLCC Pin Assignments
Z89C00
16-BIT DIGITAL SIGNAL PROCESSOR
PRELIMINARY
4 DC 4083-00
ZILOG
Table 1. 68-Pin PLCC Pin Identification
No. Symbol Function Direction
1-9 EXT15-EXT7 External data bus Input/Output 10 V
SS
Ground Input 11-26 PD15-PD0 Program data bus Input 27-38 PA11-PA0 Program address bus Output
39 V
DD
Power Supply Input 40-43 PA15-PA12 Program address bus Output 44-46 EA2-EA0 External address bus Output 47 /EI R/W for external bus Output
48 ER//W External bus direction Output 49 /RDYE Data ready Input 50 /RES Reset Input 51 CLK Clock Input
52 /ROMEN Enable ROM Input 53 HALT Stop execution Input 54-55 UI1-UI0 User inputs Input 56-58 INT2-INT1 Interrupts Input
59-60 UO1-UO0 User outputs Output 61-64 EXT3-EXT0 External data bus Input/Output 65 V
SS
Ground Input 66-68 EXT6-EXT4 External data bus Input/Output
PIN FUNCTIONS
CLK
Clock
(input). External clock. The clock may be
stopped to reduce power.
EXT15-EXT0
External Data Bus
(input/output). Data bus for user defined outside registers such as an ADC or DAC. The pins are normally in output mode except when the outside registers are specified as source registers in the instructions. All the control signals exist to allow a read or a write through this bus.
ER//W
External Bus Direction
(output, active Low). Data direction signal for EXT-Bus. Data is available from the CPU on EXT15-EXT0 when this signal is Low. EXT-Bus is in input mode (high-impedance) when this signal is High.
EA2-EA0
External Address
(output). User-defined register address output. One of eight user-defined external registers is selected by the processor with these address pins for read or write operations. Since the addresses are part of the processor memory map, the processor is simply executing internal reads and writes.
/EI
Enable Input
(output). Write timing signal for EXT-Bus. Data is read by the external peripheral on the rising edge of /EI. Data is read by the processor on the rising edge of CLK, not /EI.
HALT
Halt State
(input). Stop Execution Control. The CPU continuously executes NOPs and the program counter remains at the same value when this pin is held High. This signal must be synchronized with CLK.
INT2-INT0
Three Interrupts
(rising edge triggered). Interrupt request 2-0. Interrupts are generated on the rising edge of the input signal. Interrupt vectors for the interrupt service starting address are stored in the program memory locations 0FFFH for INT0, 0FFEH for INT1 and 0FFDH for INT2. Priority is: 2 = lowest, 0 = highest.
PA15-PA0
Program memory address bus
(output). For up to 64K x 16 external program memory. These lines are tri­stated during Reset Low.
Z89C00
16-BIT DIGITAL SIGNAL PROCESSOR
PRELIMINARY
DC 4083-00 5
ZILOG
/RDYE
Data Ready
(input). User-supplied Data Ready signal for data to and from external data bus. This pin stretches the /EI and ER//W lines and maintains data on the address bus and data bus. The ready signal is sampled from the rising edge of the clock with appropriate setup and hold times. The normal write cycle will continue from the next rising clock only if ready is active.
UI1-UI0
Two Input Pins
(input). General purpose input pins. These input pins are directly tested by the conditional branch instructions. These are asynchronous input signals that have no special clock synchronization requirements.
UO1-UO0
Two Output Pins
(output). General purpose output pins. These pins reflect the inverted value of status register bits S5 and S6. These bits may be used to output data by writing to the status register.
PD15-PD0
Program Memory Data Input
(input). Instruc-
tions or data are read from the address specified by PD15­PD0, through these pins and are executed or stored.
/RES
Reset
(input, active Low). Asynchronous reset signal. A Low level on this pin generates an internal reset signal. The /RES signal must be kept Low for at least one clock cycle. The CPU pushes the contents of the PC onto the stack and then fetches a new Program Counter (PC) value from program memory address 0FFCH after the Reset signal is released. RES Low tri-states the PA and PD bases.
/ROMEN
ROM Enable
(input). An active Low signal enables the internal ROM. Program execution begins at 0000H from the ROM. An active High input disables the ROM and external fetches occur from address 0000H.
Program Memory. Programs of up to 4K words can be masked into internal ROM. Four locations are dedicated to the vector address for the three interrupts (0FFDH-0FFFH) and the starting address following a Reset (0FFCH). Internal ROM is mapped from 0000H to 0FFFH, and the highest location for program is 0FFBH. If the /ROMEN pin is held High, the internal ROM is inactive and the processor executes external fetches from 0000H to FFFFH. In this case, locations FFFC-FFFF are used for vector addresses.
Internal Data RAM. The Z89C00 has an internal 512 x 16-bit word data RAM organized as two banks of 256 x 16-bit words each, referred to as RAM0 and RAM1. Each data RAM bank is addressed by three pointers, referred to as Pn:0 (n = 0-2) for RAM0 and Pn:1 (n = 0-2) for RAM1. The RAM addresses for RAM0 and RAM1 are arranged from 0-255 and 256-511, respectively. The address pointers, which may be written to or read from, are 8-bit registers
connected to the lower byte of the internal 16-bit D-Bus and are used to perform no overhead looping. Three addressing modes are available to access the Data RAM: register indirect, direct addressing, and short form direct. These modes are discussed in detail later. The contents of the RAM can be read or written in one machine cycle per word without disturbing any internal registers or status other than the RAM address pointer used for each RAM. The contents of each RAM can be loaded simultaneously into the X and Y inputs of the multiplier.
Registers. The Z89C00 has 12 internal registers and up to an additional eight external registers. The external registers are user definable for peripherals such as A/D or D/A or to DMA or other addressing peripherals. External registers are accessed in one machine cycle the same as internal registers.
ADDRESS SPACE
Z89C00
16-BIT DIGITAL SIGNAL PROCESSOR
PRELIMINARY
6 DC 4083-00
ZILOG
FUNCTIONAL DESCRIPTION
General. The Z89C00 is a high-performance Digital Signal
Processor with a modified Harvard-type architecture with separate program and data memory. The design has been optimized for processing power and minimizing silicon space.
Instruction Timing. Many instructions are executed in one machine cycle. Long immediate instructions and Jump or Call instructions are executed in two machine cycles. When the program memory is referenced in internal RAM indirect mode, it takes three machine cycles. In addition, one more machine cycle is required if the PC is selected as the destination of a data transfer instruction. This only happens in the case of a register indirect branch instruction.
An Acc + P => Acc; a(i) * b(j) P calculation and modification of the RAM pointers, is done in one machine cycle. Both operands, a(i) and b(j), can be located in two independent RAM (0 and 1) addresses.
Multiply/Accumulate. The multiplier can perform a 16-bit x 16-bit multiply or multiply accumulate in one machine cycle using the Accumulator and/or both the X and Y inputs. The multiplier produces a 32-bit result, however, only the 24 most significant bits are saved for the next instruction or accumulation. The multiplier provides a flow through operation whenever the X or Y register is updated, an automatic multiply operation is performed and the P register is updated. For operations on very small numbers where the least significant bits are important, the data should first be scaled by eight bits (or the multiplier and multiplicand by four bits each) to avoid truncation errors. Note that all inputs to the multiplier should be fractional two’s complement 16-bit binary numbers. This puts them in the range [–1 to 0.9999695], and the result is in 24-bits so that the range is [–1 to 0.9999999]. In addition, if 8000H is loaded into both X and Y registers, the resulting multiplication is considered an illegal operation as an overflow would result. Positive one cannot be represented in fractional notation, and the multiplier will actually yield the result 8000H x 8000H = 8000H (–1 x –1 = –1).
ALU. The 24-bit ALU has two input ports, one of which is connected to the output of the 24-bit Accumulator. The other input is connected to the 24-bit P-Bus, the upper 16 bits of which are connected to the 16-bit D-Bus. A shifter between the P-Bus and the ALU input port can shift the data by three bits right, one bit right, one bit left or no shift.
Hardware Stack. A six-level hardware stack is connected to the D-Bus to hold subroutine return addresses or data. The CALL instruction pushes PC+2 onto the stack. The RET instruction pops the contents of the stack to the PC.
User Inputs. The Z89C00 has two inputs, UI0 and UI1, which may be used by jump and call instructions. The jump or call tests one of these pins and if appropriate, jumps to a new location. Otherwise, the instruction behaves like a NOP. These inputs are also connected to the status register bits S10 and S11 which may be read by the appropriate instruction (Figure 3).
User Outputs. The status register bits S5 and S6 connect through an inverter to UO0 and UO1 pins and may be written to by the appropriate instruction.
Interrupts. The Z89C00 has three positive edge triggered interrupt inputs. An interrupt is acknowledged at the end of any instruction execution. It takes two machine cycles to enter an interrupt instruction sequence. The PC is pushed onto the stack. A RET instruction transfers the contents of the stack to the PC and decrements the stack pointer by one word. The priority of the interrupts is 0 = highest, 2 = lowest.
Registers. The Z89C00 has 12 physical internal registers and up to eight user-defined external registers. The EA2­EA0 determines the address of the external registers. The /EI, /RDYE, and ER//W signals are used to read or write from the external registers.
Z89C00
16-BIT DIGITAL SIGNAL PROCESSOR
PRELIMINARY
DC 4083-00 7
ZILOG
REGISTERS
There are 12 internal registers which are defined below:
Register Register Definition
P Output of Multiplier, 24-bit, Read Only X X Multiplier Input, 16-bit Y Y Multiplier Input, 16-bit
A Accumulator, 24-bit
SR Status Register, 16-bit
Pn:b Six Ram Address Pointers, 8-bit Each
PC Program Counter, 16-bit
The following are virtual registers as physical RAM does not exist on the chip.
Register Register Definition
EXTn External registers, 16-bit
BUS D-Bus Dn:b Eight Data Pointers
P holds the result of multiplications and is read only.
X and Y are two 16-bit input registers for the multiplier.
These registers can be utilized as temporary registers when the multiplier is not being used. The contents of the P register will change if X or Y is changed.
A is a 24-bit Accumulator. The output of the ALU is sent to this register. When 16-bit data is transferred into this register, it goes into the 16 MSB’s and the least significant eight bits are set to zero. Only the upper 16 bits are transferred to the destination register when the Accumulator is selected as a source register in transfer instructions.
Pn:b are the pointer registers for accessing data RAM. (n = 0,1,2 refer to the pointer number) (b = 0,1 refers to RAM bank 0 or 1). They can be directly read from or written to, and can point to locations in data RAM or indirectly to Program Memory.
EXT(n) are external registers (n = 0 to 7). There are eight 16-bit registers here for accessing External data, peripherals, or memory. Note that the actual register RAM does not exist on the chip, but would exist as part of the external device such as an ADC result latch.
BUS is a read-only register which, when accessed, returns the contents of the D-Bus.
Dn:b refer to possible locations in RAM that can be used as a pointer to locations in program memory. The programmer decides which location to choose from two bits in the status register and two bits in the operand. Thus, only the lower 16 possible locations in RAM can be specified. At any one time there are eight usable pointers, four per bank, and the four pointers are in consecutive locations in RAM. For example, if S3/S4 = 01 in the status register, then D0:0/D1:0/D2:0/D3:0 refer to locations 4/5/6/7 in RAM bank 0. Note that when the data pointers are being written to, a number is actually being loaded to Data RAM, so they can be used as a limited method for writing to RAM.
Z89C00
16-BIT DIGITAL SIGNAL PROCESSOR
PRELIMINARY
8 DC 4083-00
ZILOG
REGISTERS (Continued)
Figure 3. Status Register
SR is the status register (Figure 3) which contains the ALU
status and certain control bits as shown in the following table.
Status Register Bit Function
S15 (N) ALU Negative S14 (OV) ALU Overflow S13 (Z) ALU Zero S12 (L) Carry S11 (UI1) User Input 1 S10 (UI0) User Input 0
S9 (SH3) MPY Output Shifted Right by Three Bits S8 (OP) Overflow Protection S7 (IE) Interrupt Enable S6 (UO1) User Output 1 S5 (UO0) User Output 0 S4-3 “Short Form Direct” Bits S2-0 (RPL) RAM Pointer Loop Size
RPL Description
S2 S1 S0 Loop Size
0 0 0 256 001 2 010 4 011 8
100 16 101 32 110 64 1 1 1 128
The status register may always be read in its entirety. S15-S10 are set/reset by the hardware and can only be read by software. S9-S0 can be written by software.
S7 S6 S5 S4 S3 S2 S1 S0S15 S14 S13 S12 S11 S10 S9 S8
N OV Z C UI1 UI0 SH3 OP IE UO1 UO0 RPL
"Short Form Direct" bits User Output 0-1
Interrupt Enable
Overflow protection
MPY output shifted right by 3 bit with sign extension
User Input 0-1
Carry
Zero Overflow Negative
0 0 0 0 0 1 0 1 0 0 1 1 1 0 0 1 0 1 1 1 0 1 1 1
256 2 4 8 16 32 64 128
Ram Pointer Loop Size
Read
and
Write
Read Only
Z89C00
16-BIT DIGITAL SIGNAL PROCESSOR
PRELIMINARY
DC 4083-00 9
ZILOG
S15-S12 are set/reset by the ALU after an operation. S11-S10 are set/reset by the user inputs. S6-S0 are control bits described elsewhere. S7 enables interrupts. S8, if 0 (reset), allows the hardware to overflow. If S8 is set, the hardware clamps at maximum positive or negative values instead of overflowing. If S9 is set and a multiply instruction is used, the shifter shifts the result three bits right with sign extension.
PC is the Program Counter. When this register is assigned as a destination register, one NOP machine cycle is added automatically to adjust the pipeline timing.
Figure 4. RAM, ROM, and Pointer Architecture
1. Register Indirect
Pn:b n = 0-2, b = 0-1 The most commonly used method is a register indirect addressing method, where the RAM address is specified by one of the three RAM address pointers (n) for each bank (b). Each source/destination field in Figures 5 and 8 may be used by an indirect instruction to specify a register pointer and its modification after execution of the instruction.
RAM Pointers
P0:0
P1:0
P2:0
%37
RAM0
256 x 16-Bit
@P1:0
%0321
%00
RAM1
256 x 16-Bit
%0321
%00
Internal ROM
4K x 16-Bit
%1234
%0000
%1000
%0321@@P1:0
@D0:1
RAM Pointers
P0:1
P1:1
P2:1
D0:0 %0321 D1:0 D2:0 D3:0
D0:1 D1:1 D2:1 D3:1
Data Pointers
%37 %04
S4 / S3 = 01
The following Instructions load %1234 into the Accumulator:
LD A,@@P1:0 LD A,@D0:1
%FF %FF
D3 D2 D1 D0D8
bn1n0
RAM Pointer Register
Operation
RAM Bank
Figure 5. Indirect Register
RAM ADDRESSING
The address of the RAM is specified in one of three ways (Figure 4):
Loading...
+ 19 hidden pages