®

INTEL CORP. 3065 Bowers Avenue, Santa Clara, California 95051 • (408) 246-7501

8008 8-BIT PARALLEL CENTRAL UNIT

mcs-8™ MICRO COMPUTER SET

APRIL 1972 rt Int el Corpo ration 1972 8008 8 Bit Parallel Central Processor Unit The 8008 is a complete computer system central processor unit which may be interfaced with memories having capacities up to 16K bytes. The processor communicates over an 8-bit data and address and uses two leads for internal control and four leads for external control. The CPU contains an 8-bit parallel arithmetic unit, a dynamic RAM (seven 8-bit data registers and an 8x14 stack), and complete instruction decoding and control logic.

Features

• 8-Bit Parallel CPU on a single chip • 48 instructions, data oriented • Complete instruction decoding & control included • TTL compatible (inputs, outputs & clocks) • Can be used with any type or speed semi­ conductor memory in any combination • Directly addresses 16K x 8 bits of memory (RAM, ROM, or S.R.) • Memory capacity can be indefinitely expanded through bank switching using I/O instructions • Address stack contains eight 14 bit registers (including ) which permit nesting of subroutines up to seven levels • Contains seven 8-bit data registers • capability • Packaged in 18 pin DIP

BLOCK DIAGRAM PIN CONFIGURATION

ACCUMULATOR,DATA REGISTERS, PROG, V 18 INTERRUPT COUNTER STACK DD D7 o- 2 17 READY 3 16 ¢,

INTEL 15 ¢2 8008 DATA 5 BUS 13 INT D2 12 TIMING -D,o-a 11 RDY DO 0- 9 10 Vee

S,

CONTENTS Page

I. Introduction...... 3 II. Processor Timing...... 4 III. Basic Functional Blocks...... 7 IV. Basic Instruction Set ...... 8 V. Processor Control Signals...... 10 VI. Electrical Specification ...... 13 VII. MCS-8 Prototype System...... 18 VIII. MCS-8 PROM Programming System ...... 22

APPENDIX

I. Functional Definition ...... 33 II. I nternal Processor Operation ...... 38 III. Programming Example...... 42 8008 Photomicrograph With Pin Designations

2 I. INTRODUCTION The 8008 is a single chip MOS 8-bit parallel central processor unit for the MCS-8 micro computer system. A micro computer system is formed when the 8008 is interfaced with any type or speed standard up to 16K 8-bit words. Examples are INTEL's 1101, 1103 (RAMs), 1301, 1601, 1701 (ROMs), 1404,2401 (Shift Registers).

The processor communicates over an 8-bit data and address bus (Do through D7 ) and uses two input leads (READ and INTERRUPT) and four output leads (So' S1, S2 and Sync) for control. Time multiplexing of the data bus allows control information, 14 bit addresses, and data to be transmitted between the CPU and external memory. This CPU contains six 8-bit data registers, an 8-bit accumulator, two 8-bit temporary registers, four flag bits, and an 8-bit parallel binary arithmetic unit which implements addition, subtraction, and logical operations. A memory stack containing a 14-bit program counter and seven 14-bit words is used internally to store program and subroutine addresses. The 14-bit address permits the direct addressing of 16K words of memory (any mix of RAM, ROM or S.R.). The control portion of the chip contains logic to implement a variety of register transfer, arithmetic control, and logical instructions. Most instructions are coded in one byte (8 bits); data immediate in­ structions use two bytes; jump instructions utilize three bytes. Presently operating with a 500 kHz clock, the CPU executes non-memory referencing instructions in 20 microseconds. All inputs (including clocks) are TTL compatible and ail outputs are low-power TTL compatible. The instruction set of the 8008 consists of 48 instructions including data manipulation, binary arith­ metic, and jump to subroutine. The normal program flow of the 8008 may be interrupted through the use of the "INTERRUPT" control line. This allows the servicing of slow I/O peripheral devices while also executing the main program. The "READY" command line synchronizes the 8008 to the memory cycle allowing any type or sp-eed of semiconductor memory to be used. STATE and SYNC outputs indicate the state of the processor at any time in the instruction cycle.

3 II. PROCESSOR TIMING The 8008 is a complete intended for use in any arithmetic, control, or decision­ making system. The internal organization is centered around an 8-bit internal data bus. All communication within the processor and with external components occurs on this bus in the form of 8-bit bytes of address, instruction or data. (Refer to the accompanying block diagram for the relationship of all of the internal elements of the processor to each other and to the data bus.) For the MCS-8 a logic "1" is defined as a high level and a logic "0" is defined as a low level.

A. State Control ~oding S' 0 S1 S2 STATE The processor controls the use of the data bus and 0 1 0 Tl determines whether it will be sending or receiving 0 1 1 T11 data. State signals 50' 51' and 52' along with SYNC 0 0 1 T2 inform the peripheral circuitry of the state of the 0 0 0 WAIT 1 0 0 T3 processor. A table of the binary state codes and 1 1 0 STOPPED the designated state names is shown below. 1 1 1 T4 1 0 1 T5 B. Timing Typically, a machine cycle consists of five states, two states in which an address is sent to memory (Tl and T2), one for the instruction or data fetch (T3), and two states for the execution of the in­ struction (T4 and T5). If the processor is used with slow memories, the READY line synchronizes the processor with the memories. When the memories are not available for either sending or receiving data, the processor goes into the WAIT state. The accompanying diagram illustrates the processor activity during a single cycle.

T11 T1 T2 WAIT T3 STOPPED T4

HIGHER LOWER 6·BITS EXTERNAL INSTRUCTION HALT CPU a·BITS ADDRESS. MEMORY OR DATA INSTRUCTION EXECUTION OF INTERRUPTED ADDRESS TWO BITS NOT READY FETCH. OR RECEIVED BY INSTRUCTION OUT CONTROL (OPTIONAL) DATA OUT CPU OUT (S·BITS)

TYPICAL PROCESSOR CYCLE INCLUDES T1. T2. T3. T4. T5

Figure 1. Basic 8008 Instruction Cycle

4 The receipt of an INTERRUPT is acknowledged by the T11. When the processor has been interrupted, this state replaces T1. A READY is acknowledged by T3. The STOPPED state acknowledges the receipt of a HALT instruction. Many of the instructions for the 8008 are mUlti-cycle and do not require the two execution states, T4 and T5. As a result, these states are omitted when they are not needed and the 8008 operates asyn­ chronously with respect to the cycle length. The external state transition is shown below. Note that the WAIT state and the STOPPED may be indefinite in length (each of these states will be 2n clock periods). The use of READY and INTER RUPT with regard to these states will be explained later.

YES

Figure 2. CPU State Transition Diagram

C. Cycle Control Coding As previously noted, instructions for the 8008 require one, two, or three machine cycles for complete execution. The first cycle is always an instruction fetch cycle (PCI). The second and third cycles are for data reading (PCR), data writing (PCW), or I/O operations (PCC).

The cycle types are coded with two bits, D6 and D7 , and are only present on the data bus during T2.

D6 D7 CYCLE FUNCTION

0 0 PCI Designates the address is for a memory read (first byte of instruction). 0 1 PCR Designates the address is for a memory read data (additional bytes of instruction or data). 1 0 PCC Designates the data as a command I/O operation. 1 1 PCW Designates the address is for a memory write data.

5 TT111!11 INTERNAL DATA BUS t 8 BIT DATA BUS Isp ADDRES~ I ISSS OR DDD INTERNAL DATA BUS

r- 1oo S ~ ACCUMULATOR INSTRUCTION REGISTER I REGISTER a REGISTER b MEMORY CYCLESI ADDRES~r ~ '" f-. AND I POINTER :!i I-- 0 ~ 1-1 (8 BITS) (8 BITS) CONTROL CODING (8 BITS) :s I 1 f --. A H L ~ ~ ~ 81-1 SCRATCH PAD tfflf,Tf , ~ ~ t-- [5 ~n-· 1 • :1:5 ti~J-- MEMORY REGISTER ~:JI--o:::::E (1)0~~~ 7 WORDS X B BITS ~ CARRY ~ AND LOOK AHEAD ARITHMETIC MEMORY ~~ (8 BITS) INSTRUCTION I UNIT AND I f---- DECODER f--- MEMORY CONTROL I/O CONTROL H,REFRESH MUL TIPLEXER AND i ~ COUNTER REFRESH B - BIT PARALLEL AMPLIFIERS ARITHMETIC I I..,.. UNIT f-+ % I ~ r--f-t 1 ADDRESS STACK AND ., 00 f-Io 00 f-t ~ (f)", ~ f-- PROGRAM COUNTER CONDITION -t + Ww '" f-t .1 MACHINE• I STACK :5 x o:!i FLlP- FLOPS (Z,C,S,P) 1 CYCLE f--- 0 w r- oof-t 8 WORDS x 14 BITS ·1 CONTROL 1 POINTER ..: n' ..: 8 f-t AND CONDITION ~ t= ~ w~ I • (.)...J t- ~o LOGIC I I ~i ~ ~ t I I..-- I-- STATE TIMING GENERATOR STATUS ~ ~ SIGNALS • INT. l~l !'t~{i r F.F. F.F. S2 SI So SYNC ¢2 ¢ ~READY INTERRUPT

Figure 3. 8008 Block Diagram III. BASIC FUNCTIONAL BLOCKS The four basic functional blocks of this Intel processor are the instruction register, memory, arithmetic­ logic unit, and I/O buffers. They communicate with each other over the internal 8-bit data bus.

A. Instruction Register and Control The instruction register is the heart of all processor control. Instructions are fetched from memory, stored in the instruction register, and decoded for control of both the memories and the ALU. Since instruction executions do not all require the same number of states, the instruction decoder also controls the state transitions.

B. Memory Two separate dynamic memories are used in the 8008, the pushdown address stack and a scratch pad. These internal memories are automatically refreshed by each WAIT, T3, and STOPPED state. In the worst case the memories are completely refreshed every eighty clock periods. 1. Address Stack The address stack contains eight 14-bit registers providing storage for eight lower and six higher order address bits in each register. One register is used as the program counter (storing the effective address) and the other seven permit address storage for nesting of subroutines up to seven levels. The stack automatically stores the content of the program counter upon the execution of a CALL instruction and automatically restores the program counter upon the execution of a RETU RN. The CALLs may be nested and the registers of the stack are used as last in/first out pushdown stack. A three-bit address pointer is used to designate the present location of the program counter. When the capacity of the stack is exceeded the address pointer recycles and the content of the lowest level register is destroyed. The program counter is incremented immediately after the lower order address bits are sent out. The higher order address bits are sent out at T2 and then incremented if a carry resulted from T1. The 14-bit program counter provides direct addressing of 16K bytes of memory. Through the use of an I/O instruction for bank switching, memory may be indefinitely expanded. 2. Scratch Pad Memory or Index Registers The scratch pad contains the accumulator (A register) and six additional 8-bit registers (B, C, D, E, H, L). All arithmetic operations use the accumulator as one of the operands. All registers are independent and may be used for temporary storage. In the case of instructions which require operations with a register in external memory, scratch pad registers H & L provide indirect ad­ dressing capability; register L contains the eight lower order bits of address and register H contains the six higher order bits of address (in this case bit 6 and bit 7 are "don't cares").

C. Arithmetic/Logic Unit (ALU) All arithmetic and logical operations (ADD, ADD with carry, SUBTRACT, SUBTRACT with borrow, AND, EXCLUSIVE OR, OR, COMPARE, INCREMENT, DECREMENT) are carried out in the 8-bit parallel arithmetic unit which includes carry-look-ahead logic. Two temporary resisters, register "a" and register "b", are used to store the accumulator and operand for ALU operations. In addition, they are used for temporary address and during intra-processor transfers. Four control bits, carry flip-flop (c) , zero flip-flop (z) , sign flip-flop (s) , and parity flip-flop (p) , are set as the result of each arithmetic and logical operation. These bits provide conditional branching capability through CALL, JUMP, or RETURN on condition instructions. In addition, the carry bit provides the ability to do mul­ tiple precision binary arithmetic.

D. I/O Buffer This buffer is the only link between the processor and the rest of the system. Each of the eight buffers is bi-directional and is under control of the instruction register and state timing. Each of the buffers is low power TTL compatible on the output and TTL compatible on the input.

7 IV. BASIC INSTRUCTION SET The following section presents the basic instruction set of the 8008. For a detailed description of the execution of each instruction, refer to Appendix I. Data And Instruction Formats Data in the 8008 is stored in the form of 8-bit binary integers. All data transfers to the system data bus will be in the same format.

I 0 7 0 6 0 5 0 4 0 3 O2 0 1 DO I DATA WORD The program instructions may be one, two, or three bytes in length. The instruction formats then depend on the particular operation executed. FORMAT TYPICAL INSTRUCTIONS One Byte Instructions Register to register, memory reference, OP CODE I/O arithmetic or logical, rotate or I 0 7 0 6 0 5 0 4 0 3 O2 0 1 DO I return instructions

Two Byte Instructions OPCODE OPERAND

I 0 7 0 6 0 5 0 4 0 3 O2 0 1 DO I 0 7 0 6 0 5 0 4 0 3 02 0 1 DO I mmediate mode instructions

Three Byte Instructions OP CODE LOW ADDRESS HIGH ADDRESS*

*For the third byte of this instruction, 0 6 and 0 7 are "don't care" bits.

Index Register Instructions The load instructions do not affect the flag flip-flops. The increment and decrement instructions affect all fiip­ flops except the carry. MINIMUM INSTRUCTION CODE MNEMONIC STATES ~D6 0 5 0 4 0 3 0 2 0 1 DO DESCRIPTION OF OPERATION REQUIRED

(1} Lr1r2 (5) 1 1 S S S Load index register r1 with the content of index register r2. '..!'LrM (8) 1 1 ° ° ° 1 1 1 Load index register r with the content of memory register M. LMr (7) 1 1 °1 °1 °1 S S S Load memory register M with the content of index register r. \3JLrl (8) 0 0 1 1 0 Load index register r with data B .•. B. B B B° ° B B° B B B (9) LMI 0 0 1 1 1 1 1 0 Load memory register M with data B ••. B. B B B B B B B B INr (5) 0 0 0 0 0 I ncrement the content of index register r (r f AI. OCr (5) 0 0 ° ° ° 0 0 1 Decrement the content of index register r (r f AI. ° ° ° Accumulator Group Instructions

The result of the ALU instructions affect all of the flag flip-flops. The rotate instructions affect only the carry flip-flop.

ADr (5) 1 0 0 0 0 S S S Add the content of index register r, memory register M, or data ADM (8) 1 0 0 0 0 1 1 1 B ... B to the accumulator. ADI (8) 0 0 0 0 0 1 0 0 B B B B B B B B ACr (5) 1 0 0 0 1 S S S Add the content of index register r, memory register M, or data ACM (8) 1 0 0 0 1 1 1 1 B ••. B to the accumulator with carry. ACI (8) 0 0 0 0 1 1 0 0 B B B B B B B B SUr (5) 1 0 0 1 0 S S S Subtract the content of index register r, memory register M, or SUM (8) 1 0 0 1 0 1 1 1 data B .•• B from the accumulator. SUI (8) 0 0 0 1 0 1 0 0 B B B B B B B B SBr (5) 1 0 0 1 1 S S S Subtract the content of index register r, memory register M, or SBM (8) 1 0 0 1 1 1 1 1 data B ••• B from the accumulator with borrow. 5BI (8) 0 0 0 1 1 1 0 0 B B B B B B B B

8 MINIMUM INSTRUCTION CODE MNEMONIC STATES D7 D6 DsD4 D3 ~ D,i:b DESCRIPTION OF OPERATION REQUIRED NDr (5) 1 0 1 0 0 S S S Compute the logical AND of the content of index register r, NDM (8) 1 0 1 0 0 1 1 1 memory register M, or data B ••• B with the accumulator. NDI (8) 0 0 1 0 0 1 0 0 B B B B B B B B XRr (5) 1 0 1 0 1 S S S Compute the EXCLUSIVE OR of the content of index register XRM (8) 1 0 1 0 1 1 1 1 r, memory register M, or data B .•• B with the accumulator. XRI (8) 0 0 1 0 1 1 0 0 B B B B B B B B ORr (5) 1 0 1 1 0 S S S Compute the INCLUSIVE OR of the content of index register ORM (8) 1 0 1 1 0 1 1 1 r, memory register m, or data B ••• B with the accumulator. ORI (8) 0 0 1 1 0 1 0 0 B B B B B B B B CPr (5) 1 0 1 1 1 S S S Compare the content of index register r, memory register M, CPM (8) 1 0 1 1 1 1 1 1 or data B ••• B with the accumulator. The content of the CPI (8) 0 0 1 1 1 1 0 0 accumulator is unchanged. B B B B B B B B RLC (5) 0 0 0 0 0 0 1 0 Rotate the content of the accumulator left. RRC (5) 0 0 0 0 1 0 1 0 Rotate the content of the accumulator right. RAL (5) 0 0 0 1 0 0 1 0 Rotate the content of the accumulator left through the carry. RAR (5) 0 0 0 1 1 0 1 0 Rotate the content of the accumulator right through the carry. Program Counter and Stack Control Instructions

(4)JMP ( 11) 0 1 X X X 1 0 0 Unconditionally jump to B3 .•• B3B2 .•• B2. B2 B2 B2 B2 B2 B2 B2 B2 X X B3 B3 B3 B3 B3 B3 (5) JFc (9 or 11) 0 1 0 C4 C3 0 0 0 Jump to memory address B3 ••• B3B2 ••• B2 if the condition B2 B2 B2 B2 B2 B2 B2 B2 flip-flop c is false. Otherwise, execute the next instruction in sequence. X X B3 B3 B3 B3 B3 B3 JTc (9 or 11) 0 1 1 C4 C3 0 0 0 Jump to memory address B3 ••• B3B2 ••• B2 if the condition B2 B2 B2 ~ B2 B2 B2 B2 flip-flop c is true. Otherwise, execute the next instruction in sequence. X X B3 B3 B3 B3 B3 B3 CAL (11 ) 0 1 X X X 1 1 0 Unconditionally call the subroutine at memory address B3 ••. B2 B2 B2 B2 B2 B2B2B2 B3B2 •.• B2. Save the current address (up one level in the stack). X X ~B3B3 B3 B3 B3 CFc (9 or 11) 0 1 0 C4 C3 0 1 0 Call the subroutine at memory address B3 ••• B3B2 ••• B2 if the B2B2 B2 B2 B2 B2 B2 B2 condition flip-flop c is false, and save the current address (up one X X ~B3 B3 B3 B3 B3 level in the stack,) Otherwise, execute the next instruction in sequence. CTc (9 or 11) 0 1 1 C4 C3 0 1 0 Call the subroutine at memory address B3 ••• B3B2 ••• B2 if the B2 B2 B2 B2 B2 B2 B2 B2 condition flip-flop c is true, and save the current address (up one X X B3 B3 B3 B3 B3 B3 level in the stack), Otherwise, execute the next instruction in sequence. RET (5) 0 0 X X X 1 1 1 Unconditionally return (down one level in the stack), RFc (3 or 5) 0 0 0 C4 C3 0 1 1 Return (down one level in the stack) if the condition flip-flop c is false. Otherwise, execute the next instruction in sequence. RTc (3 or 5) 0 0 1 C4 C3 0 1 1 Return (down one level in the stack) if the condition flip-flop c is true. Otherwise, execute the next instruction in sequence. RES (5) 0 0 A A A , 0 1 Call the subroutine at memory address AAAOOO (up one level in the stack). Input/Output Instructions INP (8) 0 1 0 0 M M M 1 Read the content of the selected input port (MMM) into the accumulator. OUT (6) 0 1 R R M M M 1 Write the content of the accumulator into the selected output port (RRMMM, RR '" 00), Machine Instruction HLT (4) o 0 000 o 0 X Enter the STOPPED state and remain there until interrupted. HLT (4) Enter the STOPPED state and remain there until interrupted. NOTES: (1) SSS = Source Index Register } These registers, 1], are designated A(accumulator-OOO), DOD = Destination Index Register B(001), C(010), 0(011), E(100), H(101), L(110), (2) Memory registers are addressed by the contents of registers H & L. (3) Additional bytes of instruction are designated by BBBBBBBB. (4) X = "Don't Care". (5) Flag flip-flops are defined by C4C3: carry (00), zero (01), sign (10), parity (11).

9 V. PROCESSOR CONTROL SIGNALS

A. Interrupt Signal (lNT)

1) INTERRUPT REQUEST If the interrupt line is enabled (Logic "1"), the CPU recognizes an interrupt request at the next instruction fetch (PCI) cycle by outputting So S1 S2 = 011 at Tll time. The lower and higher order address bytes of the program counter are sent out, but the program counter is not advanced. A successive instruction fetch cycle can be used to insert an arbitrary instruction into the instruction register in the CPU. (If a multi-cycle or multi­ byte instruction is inserted, an interrupt need only be inserted for the first cycle.)

I I

------~~~------~~~------I I I I I I

TlI _------:-----1

INTERRUPT

INTERRUPT INTERRUPT MAY BE TURNED MAY BE TURNED OFF AT ANY TIME

ON AT ANY TIME , I INTERRUPT RECOGNIZED

THE INTERRUPT SHOULD BE RETURNED TO A LOGIC "0" BEFORE THE BEGINNING OF THE NEXT PCI CYCLE

Figure 4. Recognition of Interrupt

If a HALT is inserted, the CPU enters a STOPPED state; if a NOP is inserted, the CPU continues; if a "JUMP to 0" is inserted, the processor executes program from location 0, etc. The RESTART instruction is particularly useful for handling interrupt routines since it is a one byte call.

ADDR. LOCATION PC CONTENTS N -1INTR. N-1 N (INTERRUPT ARRIVES HERE) N INSTR. N N + 1 INSTR. N + 1 USER SUPPLIES ALTERNATE '-----1 INSTRUCTION (RESTART OR ~--~----~ CALL TO SRT). RELEASES INTERRUPT. PC IS SAVED IN STACK (VALUE = N) SUBROUTINE FOR HANDLING INTERRUPT: S INSTR.S S + 1 INSTR. S + 1 S+2 S+ K RETURN STACK POPS - WITH VALUE N

AFTER COMPLETION OF SUBROUTINE. 8008 RETURNS TO EXECUTE ORIGINALLY REQUESTED INSTRUCTION. WHICH BLOCKING ADVANCE OF PC HAS SAVED.

Figure 5. 8008 Interrupt

10 2) START-UP OF THE 8008 When power (Voo ) and clocks (<1>1 , <1>2) are first turned on, a flip-flop internal to the 8008 is set by sensing the rise of Voo . This internal signal forces a HALT (00000000) into the instruction register and the 8008 is then in the STOPPED state. The following sixteen clock periods after entering the STOPPED state are required to clear (logic "0") memories (accumulator, scratch pad, program counter, and stack). During this time the interrupt line has been at logic "0". Any time after the memories are cleared, the 8008 is ready for normal operation. To reset the flip-flop and also escape from the stopped state, the interrupt line must go to a logic "1"; It should be returned to logic "0" by decoding the state T11. Note that whenever the 8008 is in a T11 state, the program counter is not incremented. As a result, the same address is sent out on two successive cycles.

I I I I I I I

______-J~~--~ __--~~~~------~~ I I I I Tli ------+:--~i--~--~---J' I I

STOPPED I : I I \------I I

INTE I I I INTERRUPT EXIT I !lNTERNALI INTERRUPT MAY BE TURNED MAY BE TURNED I FROM I I INTER- OFF AT ANY TIME ON AT ANY TIME I S~~:~~D I IIFL~~~~oPII I I SET I I I I I INTERRUPT RECOGNIZED I

THE INTERRUPT SHOULD BE RETURNED TO A LOGIC "0" BEFORE THE BEGINNING OF THE NEXT PCI CYCLE

Figure 6. Start-up of the 8008- Interrupt Required

Three possible sequences for starting the 8008 are shown on the following page. The RESTART instruction is effectively a one cycle call instruction, and it is convenient to use this instruction to call an initiation subroutine. Note that it is not necessary to start the 8008 with a RESTART instruction.

The selection of initiation technique to use depends on the sophistication of the system using the 8008. If the interrupt feature is used only for the start-up of the 8008 l,lse the ROM directly, no additional external logic associated with instructions from source other than the ROM program need be considered. If the interrupt feature is used to jam in­ structions into the 8008, it would then be consistent to use it to jam the initial instruction. The timing for the interrupt with the start-up timing is shown on an accompanying sheet. The jamming of an instruction and the suppression of the program counter update are handled the same for all .

11 EXAMPLE 1: Shown below are two start-up alternatives where an instruction is not forced into the 8008 during the interrupt cycle. The normal program flow starts the 8008. a. 8008 ADDR ESS OUT INSTRUCTION IN ROM

o 0 0 0 0 0 000 0 0 0 0 0 NOP (LAA 11 000 000) 000 0 0 0 00000 0 0 0 NOP Entry Directly To o 0 0 0 0 0 000 0 0 0 0 1 INSTR1 Main Program o 0 0 0 0 0 o 0 0 000 1 0 INSTR2 } b. 8008 ADDRESS OUT INSTRUCTION IN ROM

o 0 0 0 0 0 000 000 0 0 RST (RST =00 XYZ 101) } 000 0 0 0 OOXYZOOO INSTR1 A Jump To The o 0 0 0 0 0 00XYZ001 INSTR2 Main Program

EXAMPLE 2: A RESTART instruction is jammed in and first instruction in ROM initially ignored. 8008 ADDRESS OUT INSTRUCTION IN ROM

000 0 0 0 0000000 0 INSTR1 (RST = 00 XYZ 101)} 000 000 OOXYZOOO INSTRa Start-up o 0 0 0 0 0 00XYZ001 INSTRb Routine

00000 0 o 0 n n n n n n RETURN· 00000 0 000 0 0 000 I NSTR1 (I NSTR1 executed now) Main Program 000 000 000 0 0 001 INSTR 2

Note that during the interrupt cycle the flow of the instruction to the 8008 either from ROM or another source must be controlled by hardware external to 8008.

START-UP OF THE 8008

B. Ready (RDY) The 8008 is designed to operate with any type or speed of semiconductor memory. This flex­ ibility is provided by the READY command line. A high-speed memory will always be ready with data (tie READY line to Vcc ) almost immediately after the second byte of the address has been sent out. As a result the 8008 will never be required to wait for the memory. On the other hand, with slow ROMs, RAMs or shift registers, the data will not be immediately avail­ able; the 8008 must wait until the READY command indicates that the valid memory data is available. As a result any type or any combination of memory types may be used. The READY command line synchronizes the 8008 to the memory cycle. When a program is being developed, the READY signal provides a means of stepping through the program, one cycle at a time.

12 VI. ELECTRICAL SPECIFICATION The following pages provide the electrical characteristics for the 8008. All of the inputs are TTL compatible, but input pull-up resistors are recommended to insure proper VIH levels. All outputs are low-power TTL compatible. The transfer of data to and from the data bus is controlled by the CPU. During both the WAIT and STOPPED states the data bus output buffers are disabled and the data bus is floating.

------v:-1 1 I FROM ------1_----...... I INTERNAL ...___ ""1 ..... DATA BUS DATABUS------+---~ I/O

TO INTERNAL DATA BUS

8008 vee _____ .J ------.--_ .....

Data Bus I/O Buffer

r--- I I I I I _--+--.... OUT I I IN.. I I L_

Vee Input Buffer Output Buffer (

Figure 7. I/O Circuitry

13 ABSOLUTE MAXIMUM RATINGS*

Ambient Temperature *COMMENT Under Bias O°C to+70°C Stresses above those listed under" Absolute Max­ Storage Temperature -55°C to +150°C imum Ratings" may cause permanent damage to I nput Voltages and Supply the device. This is a stress rating only and func­ Voltage With Respect tional operation of the device at these or any other to Vss +0.5 to -20V condition above those indicated in the operational sections of this specification is not implied. Power Dissipation 1.0 W @ 25°C

. D. C. and OPERATING CHARACTERISTICS T A = O°C to 70°C, Vce = +5V ±5%, Voo = -9V ±5% unless otherwise specified Logic "1" is defined as the more positive level (V1H , VOH ). Logic "0" is defined as the more negative level (V1L , VOL ).

LIMITS TEST SYMBOL PARAMETER UNIT MIN. TYP. MAX. CONDITIONS

100 AVERAGE SUPPLY CURRENT- OUTPUTS LOADED* 30 60 mA T A = 25°C

III INPUT LEAKAGE CURRENT 10 pA V1N = OV

V1L INPUT LOW VOLTAGE (INCLUDING CLOCKS) Voo Vec -4.2 V

V1H INPUT HIGH VOLTAGE (INCLUDING CLOCKS) Vee-1.5 Vee+0.3 V

VOL OUTPUT LOW VOLTAGE 0.4 V IOL = 0.44mA CL = 200 pF

VOH OUTPUT HIGH VOLTAGE Vee -1.5 V IOH = 0.2mA

*Measurements are made while the 8008 is executing a typical sequence of instructions. The test load is selected such that at VOL = OAV, IOL = OA4mA on each output. The test load is shown below.

TEST LOAD TEST CONDITIONS vee Vee = 5.25V RL = 11kn

CL = 100pF

8008

14 TYPICAL D. C. CHARACTERISTICS

POWER SUPPLY CURRENT OUTPUT SINKING CURRENT VS. TEMPERATURE VS. TEMPERATURE

60 2.4

0 ..J ..9 _0 « 50 « 2.2 ..s ..s I- I- 2 2 w 40 w 2.0 a:: a:: a:: r--~ a:: :::J Do ~ 14.7511. :::J u u r-- II: -II: >- 30 -~CC DO ~ 1411. (!) "-.. -' 2 1.8 0.. r-- V -II: 0.. ;2 :::J --":"C,;.. DO ~ 13.2511. 2 (fl --- = 14V en ~ ~VOO a:: I- "' 20 w --- :::J 1.6 s: 0.. 1-"'" 0 I- r-- 0.. :::J VOL = O.4V 0 r-- 10 1.4 --

1.2 10 20 30 40 50 60 70 80 o 10 20 30 40 50 60 70 80

AMBIENT TEMPERATURE (DC) AMBIENT TEMPERATURE (DC)

OUTPUT SOURCE CURRENT OUTPUT SINKING CURRENT VS. OUTPUT VOLTAGE VS. OUTPUT VOLTAGE 8 5

v 1= DO -9) 7 Vee =5V - l 4 J: TA = 70°C • .!? i' LpTTL ..J 6 _0 I' INPUT « :, CHARACTERISTIC ..s « 3 I- ..s , 2 5 , V w I- a:: 2 a:: ""- w , :::J a:: 2 / u 4 ~ a:: w :::J \ u u Vvec-voo = 14V a:: (!) \ :::J 2 3 \ / 0en ;2 2 I- OPERATING POINT" :::J en / 0.. I- I- 2 "- :::J :::J 0.. ~ ------0 " I- 0 - :::J - " 0 "" -1 o 1.0 2.0 3.0 4.0 "' 5.0 -2 -1 o 1· OUTPUT VOLTAGE (V). VOH '" OUTPUT VOLTAGE (V). VOL

15 A. C. CHARACTERISTICS

TA = O°C to 70°C; Vee = +5V ±5%, Voo = -9V ±5% All measurements are referenced to 1.5V levels

LIMITS TEST SYMBOL PARAMETER UNIT MIN. MAX. CONDITIONS

tey CLOCK PERIOD 2 3 ps tR ,tF = 50ns

tR ,tF CLOCK RISE AND FALL TIMES 50 ns t¢l PULSE WIDTH OF ¢1 .70 1.0 ps

t¢2 PULSE WIDTH OF ¢2 .55 .70 ps t01 CLOCK DELAY FROM FALLING EDGE OF ¢1 TO FALLING EDGE OF ¢2 .90 1.1 ps

t02 CLOCK DELAY FROM FALLING EDGE OF ¢2 TO RISING EDGE OF ¢1 .40 ps

too DATA OUT DELAY 1.0 ps CL = 100pF tOH HOLD TIME FOR DATA OUT .10 ps tlH HOLD TIME FOR DATA IN .50 ps

tso SYNC OUT DELAY .70 ps CL = 100pF tS1 STATE OUT DELAY (ALL STATES EXCEPT T1 and T11) * 1.1 ps CL = 100pF

tS2 STATE OUT DELAY (STATES T1 AND T11) 1.0 ps CL = 100pF

tRW PULSE WIDTH OF READY DURING ¢22 TO ENTER T3 STATE .35 ps

t RO READY DELAY TO ENTER WAIT STATE .20 ps

*If the INTERRUPT is not used, all states have the same output delay, t S1 .

CLOCK WAVEFORM

1'...... I---~~----~---- tCY--~------~ J -----II--t¢1-----11..... ------....I1 1-~~~--tD1 .. 10-90% OF INPUT AMPLITUDE 1 -tD2 ------1'II_t¢2__ 1 "------

16 TIMING DIAGRAM

SYNC

DATA BUS LINES (07" .00)

IS2 _____ S, -ts,---- STATE LINES

~tRW ...-

I '~- ~-I tRD 1,--1------

T1 T2 T3 Tl

CAPACITANCE f = 1 MHz; TA = 25°C; Unmeasured Pins Grounded LIMIT (pF) SYMBOL TEST TYP. MAX.

CIN INPUT CAPACITANCE 5 10

Cos DATA BUS I/O CAPACITANCE 5 10

COUT OUTPUT CAPACITANCE 5 10

TYPICAL A. C. CHARACTERISTICS DATA OUT DELAY VS. MINIMUM CLOCK PULSE WIDTH OUTPUT LOAD CAPACITANCE VS. TEMPERATURE '.1 800....-----,.------,------;-----,

I 1.0 ~~ / > --+ ~~ ": o "'600~----1------+--~~~~---~ " .s J: >5 .9 /v >­ o @ ~ V w ~"" / 3 400~~--_+-----+------r-----~ "' .8 '" ..:0 c.. >« / "g ...J ...J ~ .7 / (J :;; >­ :::> :::> c.. :;; 200~---_+-=~~_+-----~------~ >­ I :::> Z o .6 ~

.5 o~--~---~---~---~ o 50 100 150 200 250 300 o 20 40 60 80

DATA BUS CAPACITANCE (pF). CDS AMBIENT TEMPERATURE ("C)

17 VII MCS-8 PROTOTYPE SYSTEM

The 8008 is designed to operate with standard semiconductor memories. TTL interface circuitry to memories is required to latch the time mUltiplexed addresses and gate data or instructions onto the data bus. As an aid to program development, Intel has developed a complete prototyping system, the SIM8-01. The preliminary schematic of this board is shown on pages 20 and 21. The SIM8-01 is a single board which contains all of the circuitry required to interface the 8008 with standard ROMs and RAMs. It contains a 1 K x 8 static RAM memory and has sockets for up to 2K x 8 ROM memory. During program development, Intel's 1702 electrically programmable and erasable ROM may be used. The 8008 can directly address up to 16K x 8 of memory. All control lines, address bits, and data lines are provided for memory expansion. Both the INTERRUPT and READY control lines are also made available. The 8008 can directly reference 32 different I/O ports. Six ports are included on the SI M8-01, two input ports and four output ports with latches. In addition, a 500 kHz system clock and TTY interface circuits are on the board.

I/O INPUT AND INTERRUPT INSTRUCTION SOURCES HHHH

MEMORY BUFFERS ~ ROM-RAM & ~ 8BITS/BYTE MPXERS TO 16 K BYTES 1= I-.~ ~

8008 I/O DATA MEMORY, OUTPUT BUS INTERRUPT DATA & INPUT r;:::::;-, ENABLES ADDRESS, CONTROL~ ADDRESS REGISTER - 8 BITS REGISTER - 8 BITSr 'uu TTTl ~ f: BUFFERS

STATUS WR

LOGIC SYNC 8008 EXTERNAL INTERRUPT INT. H I CLOCK I I GENERATOR

Figure S. MCS-S Basic System

18 SIMS-01 SPECI FICATIONS

Card Dimensions: D.C. Power Requirement: • 11.S inches high • Voltage: • 8.0 inches deep Vee = SV ±S% TTL GRD = OV System Components Included on Board: Voo = -9V ±5% • S008 • Complete TTL interface to memory • Current: • 1 K x S R AM memory No ROMs • Sockets for 2K x 8 PROM memory Icc = 1.8 amps • TTY interface ckts. 100 =.6 amps • Two input and four output ports Eight ROMs Maximum Memory Configuration: Icc = 2.2 amps • 1 K x 8 RAM 100 = 1 amp • 2K x 8 PROM Connector: • All control lines are provided for • Wire wrap type Amphenol S6 pin memory expansion connector PIN 261-10043-2 Operating Speed • 2 {J.S clock period • 20 {J.S typical instruction cycle cs, cS2 cs ~FOR ------r======r======r~~~~~~~~~~~~~~~~~~~~~~~~~c~4 I ~ ~ I cs ROM """""~"""""~ 14 14 ~ ~ ~ ~g.~ ...~-_____1 ...... Ao cs _ cs _ cs _ cs _ cs _ cs _ cs _ cs

:: 1702 == 1702 == 1702 == 1702 == 1702 == 1702 == 1702 == 1702 ~A4 A4 ------v.B~3~+ As As ______~c~ _ _ _ _ _ "~-9V ~: ~: = = _ _ _ _ _ v"o ]~~flliD,_.I~I'"iei''iii~di,I'''I''''~~il'''1"'1"~di"I"iiiil_~'I"il""il ei'~"I"'I'~'_J~~~A

r.,.6-+-----~---+----~~--+-----~--~----~~~~----~--~----~--_f------~,~6--t---oC~

Ao CSOATA 13 cs cs cs cs cs cs CSOATA 13 OUT :: :: = = = OUT 1101 1'01 = 1101 - 1101 :: 1101 - 1101 = 1101 1101 DATA 12 = DATA 12 A7 R/W IN 1-= = 1-= - = IN 15 15 r'6~~~------1r---~----~--~+----~~--~+---~--~~----~r--+-~---~J--~~---~~'~6--~~CS,

13 .. CS 13 :: :: :: - 1101 ,::, 1101 2 1101 = 1101 :: 1101 :: 1101 = 1101 12 cs rr= ,= ~= = FOR RAM. 15 15

15 '5 1~~g'~6~~ilr.:==c:~ri~::][::~i-:::J:::l-t~::J:::l-t-:::J:J::i-t-:::I::~II~::I'~6~ti~~ A. cs 13 1= i= = = _ cs 13 ~ 1101 1101 I~ 1101 I ::: 1101 :: '101 - 1101 1101 = 1101 ~ ~ R!W ~ I-f = f-t ~ f- ' ~ f- :: f- = f-:: RIW

+5V PIN 5 -9V - PIN 4, 8 R~'~NO~T~E'~'~1O,~,~:':5:::1~::-:::~1:~::::-::j~::::::~~:;;;;;~~~;;;;;:~~iiiiii~~~~i'i5~~~~~}'ON~APIN .14 NOT USED - DATA OUT The memory system shown above or an equivalent will be used for the 81M 8-01 micro computer. Figure 9. MCS-8 Memory System

19

11,/ T °liln Sl~t. .1 II; r~==- 4 = =- 1; I s V; V- =- ~:P. R.M ==- 2 ---<>]), .DIIT~ ~ - "P ---() J),. IN c B ---() Jl.. Vee Vee' + Tfrlr OJ N.o. +~~ IK posh '$5<- ""~cL!/ !~p BuTTOlOI D;~5q ~L N.c. ,-~ f5DTil

ZNT. 0, ;3205 ;~ 0, £'~~

vee- + '01/, I{.,1(4 ~

L?: ~ ~: '--:-". I L.:§' .,.J

~DOPAI ~ Vee CLOtK ~ ~ + q 9 q q 0--

'160:l.S'fX .""""~.q

~R~y~> ______~

20 Vee EN~b ~1 11'11 "'56, 0, 1/, HI' r/o R lIEC~E i320S "".e; ",!J 1J. I, Pt.~

' L hy! xix! I .. 1-1== .~ b ()fI.'FINI 1I11DAJ , I~ t. '?~'~!OPTION w 92 -u- II I\,R, ~2. E,f,,, ~ I-- .. "' ... E3~1~ i32.05 132.05

0. a, q. 0, IfI£NlO~ Y 11111111 cs" I O~'ANI'ZATlt>N IIIU "1 <1 O'P'" D '" I I cs, cSt'

CS? j 34-04 II RC,." CS" cs. ~ flwm I I ryl I I ~I~ I , Po'-."'" t::: w A, s""t. I MEMORY ARRAY I vet. s ,:r 21< )( 8 ROM l( 'I lie" 10 J:'A~ rF' Lllr'H 'fI/w I~ >< 8 RAM -F"~ " :t y'fLf3 ~ IK :R8M DATI -r>Th~I:D",.", ft) , :rN m{mM·y J>ItTA M~ ],1 ~ OIlT ~ ~ Do, IKT

D-f>- ~ ~ I- 1i: J), ~~ ~,~O- \0,,<11. t" () ~ ",. ~~ Vee. <1:'" t . ~,~~ Q~ ~ ~~ M- ~ ll,f f"'" Ii. /I f. ~ ll,f 8 ]), [ 1', n ]), f IVIPX I\\PX J>. ztn: ~f-- , t---- n. ])~ ~ :D; s~ ])1 ~ Y. I-- f3 :D~ rs;-s. .~ s,"-Ii': So. So s i8008 50 '0 , a~ &.....'l.. s, ..... l!1 $. ~ CPU K J),. f- 1/ f.. ~ J1~ Ilf 81-- 0:. 9, J)~ JI,. !', f. l>:!- or MPX I-- '1- ,,'11 ~ J/( ~:l I- f. C'D., f. 1'" :», "--- i...... - L!:[)\7frO'-

IJA bLb- IYl PX - S; "ETl'~5 - N8;l63

Figure 10. Preliminary SIMS·01 Schematic

21 VIII. MCS-8 PROM PROGRAMMING SYSTEM

A. General System Description and Operating Instructions

Intel has developed a low-cost micro-computer programming system for its electrically programmable ROMs. Using two special printed circuit boards produced by Intel and a standard ASR 33 teletype (TTY), a complete low cost and easy to use ROM programming system may be assembled. The system features the following functions: 1) ROM programming 2) Format checking 3) Error checking 4) Program listing

For specifications of the I ntel ROMs, refer to the 1601/1701, 160211702 data sheet.

CONTROL PROGRAM I I I

0 1 2 3

ROM PROGRAMMING BOARD mm m ~ I I • / SIMB-01 MP7-02 ~ ROM SO&ETS 1 PROM ~OCKET 0ASR 33

Figure 11. MCS-8 PROM Programming System This programming system has four basic parts:

1) The micro-computer (SI M8-01 ) This is the MCS-8 prototype board, a complete micro-computer which uses ROMs (1601/ 1701 or 1602/1702) for the microprogram control. The total system is controlled by the 8008 CPU_

2) The cOl)trol programs (I ntel tape numbers A0660, A0661 , A0662) These three 1602 ROMs contain the microprograms which control the programming, format and error checking, and listing functions. 3} The programmer (MP7-02) This is the programmer board which contains all of the timing and level shifting required to program the Intel ROMs. 4) ASR 33 (Automatic Send Receive) Teletype This provides both the keyboard and paper tape I/O devices for the programming system. In addition, a short-wave ultraviolet light is required if the erasable and reprogrammable 1701 's or 1702's are used.

This system has two modes of operation:

1} Automatic - A paper tape is used in conjunction with the tape reader on the teletype. The tape contains the program for the ROM.

2} Manual - The keyboard of the TTY is used to enter the data content of the word to be programmed.

22 PROGRAMMING THE 1601/1701 AND 1602/1702

Information is introduced by selectively programming "1"s (output high) and "O"s (output low) into the proper bit locations. Note that these ROMs are defined in terms of positive logic.

Word address selection is done by the same decoding circuitry used in the READ mode. The eight . output terminals are used as data inputs to determine the information pattern in the eight bits of each word. A low data input level (-40V - P on tape) will leave a "1" and a high data input level (ground-N on tape) will allow programming of "0" (see table below). All eight bits of one word are programmed simultaneously by setting the desired bit information patterns on the data input terminals.

When the Data Input for the Program Mode is: Then the Data Output during the Read Mode is:

VILIP = ",-40 V pulsed Logic Level High = VOH = 'P' on tape

VIHP = ..... OV Logic Level Low = VOL = 'N' on tape

~WORD A7 A6 A5 A4 A3 A2 A1 Ao 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 I I I I I I I I I I I I I I I I I I 255 1 1 1 1 1 1 1 1

Address Logic Level During Read Mode: Logic 0 = VIL ("'-'.3V) Logic 1 = VIH ("'-'3V)

Address Logic Level During Program Mode:* Logic 0 = VIL2P (",-,-40V) Logic 1~ VIHP (rvOV)

'The Logic Levels for the address inputs are inverted from the Logic Levels for the data inputs during the Program Mode.

TAPE FORMAT The tape reader used with a model 33 ASR teletype accepts 1" wide paper tape using 7 or 8 bit ASCII code. For a tape to correctly program a 1601/1701 or 1602/1702, it must follow exactly the format rules below:

5<", Ch,,,ct"' 1 S'"P C"",,ct"' 11 D,,, F'oId MSB f" '" LSBr" 4,

Leader: B P P P N N N N N F B N N N N N N P P F ... B N P N P P P N N F Trailer:

Rubout for at ~ ____~ ______~J\~ ____~ ____~ Rubout for at least 25 frames. T least 25 frames Word Field 0 Word Field 1 Word Field 255

The format requirements are as follows: 1) There must be exactly 256 word fields in consecutive sequence, starting with word field 0 (all address lines low - refer to the table shown above) to program an entire ROM. If a short tape is needed to program only a portion of the ROM, the same format requirements apply.

23 2) Each word field must consist of ten consecutive characters, the first of which must be the start character B. Following that start character, there must be exactly eight data characters (P's or N's) and ending with the stop character F. NO OTHER CHARACTERS ARE ALLOWED ANYWHERE IN A WORD FIELD. If an error is made while preparing a tape and the stop character" F" has not been typed, a typed rubout w"ill eliminate the previous character entered. If a B is entered in place of a rubout, the entire word is eliminated. This is a feature not available on Intel's 7600 programmer; the format shown in the 1601/1701 data sheet must be used when preparing tapes for other programming systems. An example of this error correcting feature is shown below:

TYPED ON TTY PROGRAMMED IN ROM one letter removed ~ BNPPN\PNPN\\NN F ------'.-- NPPNPN N N Y last two letters removed

BNNPPNPBNPPPNPNPF ------.- NPPPNPNP I I I data word \ = rubout eliminated

If any character other than P or N is entered, a format error is indicated. If the stop character is entered before the error is noticed, the entire word field, including the B and F, must be rubbed out. Within the word field, a P results in a high level output, and N results in a low level output. The first data character corresponds to the desired output for data bit 8 (pin 11), the second for data bit 7 (pin 10), etc. 3) Preceding 'the first word field and following the last word field, there must be a leader/ trailer length of at least 25 characters. This should consist of rubout punches. 4) Between word fields, comments not PROM PIN CONFIGURATION containing B's or F's may be inserted. A2~ Voo It is important that a carriage return A, 2 23 ¢1 and line feed characters be inserted AO 3 22 q,2 (as a "comment") just before each *DATAOUT 1 4 (l$S) 21 A3 word field or at least between every *DATA OUT 2 5 four word fields. When these carriage "DATA OUT 3 6 19 AS returns are inserted, the tape may be *DATAOUT 4 7 '"DATA OUT 5 8

easily listed on the teletype for *DATA OUT 6 9 16 VGG~(1601/170' lv AND purposes of error checking. It may .DATA OUT 7 10 15 J BS 1602/1702}

also be helpful to insert the word ·DATA OUT 8 11 (MSB) t4 cs {(160l/170l lpROGRAM AND number (as a "comment") at least Vee L':....'_~13 J 1602/1702)

every four word fields. "THIS PIN IS THE DATA INPUT LEAD FOR THE 1601/1701 AND 1602/1702 DURING PROGRAMMING

IMPORTANT It should be noted that the PROM's are described in the data sheet with respect to positive logic (high level = p-Iogic 1). The MCS-8 system is also defined in terms of positive logic. Consider the instruction code for LLD (one of the 48 instructions for the MCS-8).

1 1 101 0 1 1 When entering this code to the programmer it should be typed, BPPPNPNPPF This is the code that will be put into the 1301, Intel's mask programmed ROM, when the final system is defined.

24 OPERATING THE PROGRAMMER

PROGRAMMING

Two different modes of operation are available* 1) A complete program tape consisting of 256 data words in sequential order may be used. a) To program the complete ROM place the ROM to be programmed into the socket on the MP7-02 board, reset the system, and then type.

S (start command)

000 (initial address - address 0 of the ROM)

255 (final address - address 255 of the ROM)

Start the tape (data words may also be entered in sequence manually). The ROM will be programmed in all 256 locations. b) To skip a section of the ROM (skipping the same number of data words on the tape) and then program a section of the ROM while still keeping the addresses in sequential form on the complete tape, type,

S (start command)

xxx (initial address)

YYY (final address)

Start the tape. The ROM will only be programmed in the specified locations.

*Operate the TTY in the "Iine" position. Depress the RETURN key 8 after each manual data word entry. When using the tape reader to enter the program data, sWitch the reader to "start" after the final address is entered.

EXAMPLE 1:

Typed -{S .....1------start command by 005 ...... 1------initial address User 010 .....1------final address

000 BNPNPNPNNF] 001 B P P P P P P P P F Listing 002 B P P P P P P P P F ..- data words skipped on of 003 B P P N P P P N P F programming tape tape 004 B P P P P P P P P F by 005 B N N P N N P P P F* ~ programming begins TTY 006 BNPNNPNPPF 007 BPNPNPPPPF 008 BNPNPPNPPF 009 BNNNNPPPNF 010 BPPNPPPPNF F .....1------programming completed

In this example the first five data words on the tape are skipped and the next six data words are programmed in the ROM locations 005 to 010. The "*,, indicates the first instruction programmed, and the "F" at end of the listing indicates the completion of the programming.

25 2) To program any portion of the ROM without skipping a section of the tape, use a short tape (data words in sequence) and type

P (program command)

XXX (initial address)

YYY (final address)

Start the tape (data words may also be entered manually).

EXAMPLE 2:

Typed .-----'------... program co.mmand by .------... initial address User -{:"016 .------~---... final address 011 BNNNNPNPPF Listing 012 B N N N P P P P N F of 013 BNNNNP NNP F tape 014 BNPNPPPNPF by 015 BNNNNP NNP F TTY 016 BNPNNPPNPF F ... programming completed

This example shows that the first six instruction words in sequence on a tape are read and directly programmed into ROM locations 011 through 016 without skipping.

FORMAT CHECKING When the programmer detects the first format error (data words enter either on tape or manually), it will stop programming the ROM, and it will print out the address where the format error occurred. If a tape is being used, the programming system will continue to list the content of the tape and will print out the address of each subsequent format error.

EXAMPLE 3:

Typed by ~20 User -{024

020 BNPNPNPNPF 021 B P P P P N N N N F 022 BNNNNPPPPN Listing F E 0 2 2 ...... t------format error indicated at address of #022 (too many characters in Tape data field). by 023 BNPNPNPNPF TTY 024 B P N M F E 0 2 4 ...... t------format error indicated at address #024 (illegal character in data field).

F ...... 1------sequence completed

If data words are being entered manually and a format error is encountered, the system must be reset before continuing the programming.

26 ERROR CHECKING

After each location in ROM is programmed, the content of the location is read and compared against the programming data. I n the event that the programming is not correct, the ROM location will be programmed again. The MCS-8 programming system allows each location of the ROM to be reprogrammed up to four times. A "$" will be printed for each reprogramming. If a location in ROM will not accept a data word after the fourth time, the system will stop programming and a "7" will be printed. This feature of the system guarantees that the programmed ROM will be correct, and incompletely erased or defective ROM's will be identified.

EXAMPLE 4:

Typed by r~06 User L009 1st programming 2nd programming 1~r------3rd programming Listed by System i006 B NNNP NP NP F$ $ $ 7 ...... 1----- failure to program F ...... f------programming stopped

If a location in the ROM will not program, a new ROM must be inserted in the programmer. The system must be reset before continuing. (If erasable ROMs are being used, the "faulty" ROM should be erased and reprogrammed).

PROGRAM LISTING

After the programming is complete, the complete content of the ROM, or any portion may be listed on the teletype. A duplicated programming tape may also be made using the teletype tape punch. To list the ROM, type

L (list command)

xxx (initial address)

YYY (final address)

EXAMPLE 5:

Typed by ~00 User -{010

000 B P P P P P P P P F; 001 B P P P P P P P P F; 002 B P P P P P P P P F; 003 B P P P P P P P P F; Listed 004 B P P P P P P P P F; 005 B N N P N N P P P F; by 006 B N P N N P N P P F; 007 B P N P N P P P P F; System 008 B N P N P P N P P F; 009 B N N N N P P P N F; 010 B P P N P P P P N F; F ...... l------listing complete

Note that this is a listing of the ROM programmed in Example 1. The listing feature may also be used to verify that a 1701 or 1702 is completely erased.

27 1701,1702 ERASING PROCEDURE:

The 1701 and 1702 may be erased by exposure to a high intensity ultraviolet light source. A 1701 or 1702 placed 1 to 1.5 inches from alight source with an ultraviolet wavelength of 2536A at an intensity of 10 mW/cm2 (i.e. a dosage of 6W sec/cm2 ) will be erased in 3 minutes. An example of a light source which is capable of producing the required ultraviolet wavelength and intensity is the Model R51 manufactured by Ultraviolet Products (San Gabriel, California). Any inexpensive light source that meets the spec may be used.

B. MP7-02 Programming System

The MP7-02 easily interfaces with the SIMS-01. All address and data lines are completely TTL compatible. The MP7-02 requires +5 VDC @ O.S amps, -9 VDC @ 0.2 amps, and 50 Vrms @ 1 amp. Two Stancor PS1S0 (or equivalent) filament transformers (25.2 Vrms @ 1 amp) with their secondaries connected in series provide the 50 Vrms.

The MP7-02 features three data control options: 1) Data-in switch (Normal-Complement). If this switch is in the complement position, data into the PROM is complemented. 2) Data-out switch (Normal-Complement). If this switch is in the complement position, data read from the PROM is complemented.

3) Data-out switch (Enable-Disable). If this switch is in the enable position, data may be read from the PROM. In the disable position, the output line may float up to a high level (logic "1"). As a resu It, the input ports on the prototype system may be used for other functions without removing the MP7-02 card.

The schematic and board layout for the MP7-02 are shown on the following pages.

Programmer Board Specifications

Dimensions: Connector: S.4 inches high a. Solder lug typel Amphenol 9.5 inches deep 72 pin connector Power Requirement: PIN 225-23621-101 Vee == +5 @ O.S amps b. Wire wrap type - Amphenol TTL GRD == OV 72 pin connector *Voo == -9V @ 0.2 amps PIN 261-15636 Vp== 50Vrms @ 1 amp Features: *This board may be used with a -10V supply elnputs and outputs TTL because a pair of diodes (i.e. 1 N914 or compatible equivalent) are located on the board in series e Board sold complete with trans­ with the supply. Select the appropriate pin formers, capacitor and connector for either -9 V or -10 V operation. • Directly interfaces with SIMS-Ol Boards (I nterconnection available on request)

28 c. Electrically Programmable ROMs

The Intel 1601, 1602, 1701, and 1702 is a 256 word by 8 bit electrically programmable ROM ideally suited for uses where fast turnaround and pattern experimentation are important such as in prototype or in one of a kind systems. The 1601, 1602, 1701, and 1702 is factory reprogrammable which allows Intel to perform a complete programming and functional test on each bit PQsition before delivery. The four devices 1601, 1602, 1701, and 1702 use identical chips. The 1601 and 1701 is operable in both the static and dy­ namic mode while the 1602 and 1702 is operable in the static mode only. Also, the 1701 and 1702 has the unique feature of being completely erasable and field reprogrammable. This is accomplished by a quartz lid that allows high intensity ultraviolet light to erase the 1701 and 1702. A new pattern can then be written into the device. This procedure can be repeated as many times as required. The 1301 is a direct replacement part which is programmed bv a metal mask and is ideal for large volume and lower cost production runs of systems initially using the 1601 /1701 or the static only 1602/1702. The dynamic mode of the 1601/1701 and 1301 refers to the decoding circuitry and not to the . Dynamic operation offers higher speed and lower power dissipation than the static operation. The 1601, 1602, 1701, and 1702 is fabricated with silicon gate technology. This low threshold technology allows the design and production of higher performance MaS circuits and provides a higher functional density on a monolithic chip than con­ ventional MaS technologies.

D.C. Characteristics for static operation D.C. Characteristics for dynamic operation

(TA = O°C to 70°C, Vee = +5V ±5%, Voo = -9V ±5%, VGG = -9V ±5%) (TA = O°C to 70°C, Vee = VGG = +5V ±5%, Voo = -9V ±5%, Test Min. Max. Unit unless otherwise noted) - Test Typ. Standby power supply current @ 25°C 10 ~tA Max. Unit Power supply current @ 25° C Unselected average power under continuous operation 46 mA supply current at 25°C 5 10 mA Input load current VA Average power supply { 1601 30 45 mA current @TA = 25°C 1301 28 40 mA Input "high" voltage Vee -2 Vee +.3 V Input "low" voltage Vee -10 Vee -4.2 V Output "low " voltage @ A.C. Characteristics for dynamic operation

~_= 1.6mA 0.45 V (TA = O°C to 70°C, Vee = + 5V ±5%. Voo = -9V ±5%, unless other· Output "high" voltage @ wise noted) 1601/1701 1301 ~= 1OO VA 3.5 V - Test Min. Typ. Max. Min. Typ. Max. Unit

01 Clock pulse width 0.260 2 .260 2 ~tS A.C. Characteristics for static operation 02 Clock pulse width 0.140 2 .140 2 l·tS (TA = O°C to 70°C, Vee = +5V ±5%, Voo = -9V ±5%, VGG = -9V 02 delay from 01 0.150 2 .150 2 !-',S ±5% unless otherwise noted) 1601/1701 1602/1702 1301 01 delay from 02 .05 2 .05 2 ,u,s Address to output access ns Test Typ. Max. Typ. Max. Unit 450 650 450 650 Repet ition Rate 1 1 MHz Addre ss to output delay .700 1 .550 1 VS Switching Characteristics for Dynamic Operation Switching Characteristics for Static Operation Condition of test: Conditions of: Input pulse amplitude: 0 to 4V Input pulse amplitudes: 0 to 4V Input rise and fall times ~ 50 nsec Output load is 1 TTL gate Output load is 1 TTL gate; measurements made at output of TTL gate (tpd ~ 15 nsec) Normal Operation (constant V GG) DESELECTIDN OF DATA OUTPUT Read timing IN OR·TIE OPERATION VIHC ----... VIH 1 ADORESS VILC "D:~ Y. :X VIHC --+---t----~ !'--"!-t ? 0 ns 1-­ I VILC IH I V 10% ~ V CS I ADDRESslH I VIL 90% I VIL ---J-F~¥-+-----+------J I too-I i- VIH ---"\. VOL~~ VIL DATA OUT I I 1 tACC2 VOH I VOH I ------!---.., OUTPUT ~ I --I tCOll-- I VOL '------' I tACC1--~t-OUTPUT VALlD __

29 POW"~ 6UP'P'LY e ...ULATO& r " \

+ eo'"

5 J:'ILTEIlt CAP 1Z58 ~~~------~~~----.---.-~~ 1·0

~~------i------~~------1------~--~---1------t--~-----~~;~~OUT ,----+ fZ ("7 fZ 1.1 10 0 ~I 3.310: EfoI'Z901 2,.,

C"'7 , ... 91. PIN ."

\/(iZ 1 .... '2'70 '''S2t.!oA '''''47.58'''

_/0 14~------4'-----~------i

''0 eS4 II<. -9 9~------+

P2.06JtAM PUL1tE TIMIN,,"

r_------JA~------~\ +5 +5

.s +6 ZiP2 +80" 101<.

Z"'IO ~""74DS' '2.7~ 1.C.11

.. 5 ",.G. 275 101< -=

/I

4 ~~~-----i 127'2. '27 i£. SN1405 I.C.II IJ

+5

e~1 4'0 D~------~------~ , C ~------~

~~------~.~~~~6------~ 6lJ1405 r.C.11

+sv NOTES: Unless Otherwise Specified 1. Resistors are rated in ohms %w, 10%_ 2. Transistors are S E 6021. 3. Pin numbers are specified for the solder lug connector.

30 ve.e. .. OUT OA~r ... ,N J

~::T~~~ w DATA OUT 1

DATA OUT EIrt.IA&L&

OATA'" e. .... ".LE

DATA OUT COUTItOL..

~~------~yr------~) A002E!'>!'> 02''''''2.

". .. VOO A, n ~, 4. • u h DATA. oo.lT I "(lla') A~ • .'to " J .. .s " .. .. ,; .. ' ,~'. r. " V.,. 7 V .... " OA.'TA. OUT II II (M'.> .. Z; vC< 'Z ,.£"" e .... "

oe.vlce T'O eE' PROGRAMMED

.1<..

~~------~yr------~)

DATA. Dl2lvEIIZ Figure 12. MP7-02 PROM Programmer Board Schematic

31 SOLOER CONNECTOR r<>/N ZZS ·236Z1-10, WIAfWRAP CONNECTOR I=>/N Z.61 -15'36-Z Figure 13. Circuit Side of MP7-02 Card

RIi.~l~TOa~ "'U 2ATED '" OHM' \'4y1Jlo1c> SOLDER. CONNECTOR F'/N 2.2,5-236;2.1-101 ~. c:."'P"',TOIl" AU ItjO,:1'SO '''' ""'~F",~I)'::I WIRI!:WRAP CONNI!CTOR P/N tIS! -15636 -2. n 69 H ~5" 63 " 59 51 5"5" 53 51 4'1 ~7 ~5 ~~ ~1 39}7 3533 31 1917 15 Z3 2;1 19 17 15 I} 11 Figure 14. Component Side of MP7-02 Card

32 APPENDIX I FUNCTIONAL DEFINITION

Symbols Meaning

Second byte of the instruction Third byte of the instruction One of the scratch pad register references: A, B, C, D, E, H, L One of the following flag flip-flop references: C, Z, S, P Flag flip-flop codes: 00 carry 01 zero 10 sign 11 parity M Memory location indicated by the contents of registers Hand L ( ) Contents of location or register A Logical product '¥ Exclusive "or" V I nclusive "or" Am Bit m of the A-register STACK I nstruction counter (P) pushdown register P Program Counter Is transferred to xxx A "don't care" SSS Source register for data DDD Destination register for data Register # Register Name (SSS or DDD) 000 A 001 B 010 C 011 D 100 E 101 H 110 L

33 INDEX REGISTER INSTRUCTIONS

LOAD DATA TO INDEX REGISTERS - One Byte Data may be loaded into or moved between any of the index registers, or memory registers.

Lr,r2 11 DOD SSS (rl)-(r2) Load register rl with the content of r2' (one cycle - PCI) The content of r2 remains unchanged. If SSS=DDD, the instruction is a NOP (no operation). LrM 11 ODD 111 (r)-(M) Load register r with the content of the (two cycles - memory location addressed by the contents of PCI/PCR) registers Hand L. (000#111 - HALT instr.) LMr 11 111 SSS (M)-(r) Load the memory location addressed by (two cycles - the contents of registers Hand L with the content PCI/PCW) of register r. (SSS#111 - HALT instr.)

LOAD DATA IMMEDIATE - Two Bytes A byte of data immediately following the instruction may be loaded into the processor or into the memory Lrl 00 DOD 110 (r) - Load byte two of the instruction into (two cycles - register r. PCI/PCR) LMI 00 111 110 (M) - Load byte two of the instruction into (three cycles - < B2> the memory location addressed by the contents of PC I fPC R/PCW) registers Hand L. INCREMENT INDEX REGISTER - One Byte INr 00 DOD 000 (r) - (r)+1. The content of register r is incremented by (one cycle - PCI) one. All of the condition flip-flops except carry are affected by the result. Note that DDDi=OOO (HALT instr.) and 000#111 (content of memory may not be incremented). DECREMENT INDEX REGISTER - One Byte DCr 00 DOD 001 (r)--(r)-1. The content of register r is decremented (one cycle - PCI) by one. All of the condition flip-flops except carry are affected by the result. Note that DDDi=OOO (HALT instr.) and DDD:!111 (content of memory may not be decremented) .

ACCUMULATOR GROUP INSTRUCTIONS

Operations are performed and the status flip-flops, C, Z, S, P, are set based on the result of the operation. Logical operations (NOr, XRr, ORr) set the carry flip-flop to zero. Rotate operations affect only the carry flip-flop.

ALU INDEX REGISTER INSTRUCTIONS - One Byte (one cycle - PCI) Index Register operations are carried out between the accumulator and the content of one of the index registers (SSS=OOO thru SSS=110). The previous content of register SSS is unchanged by the operation. ADr 10 000 SSS (A)-(A)+(r) Add the content of register r to the content of register A and place the result into register A. ACr 10 001 SSS (A)-(A)+(r)+(carry) Add the content of register r and the contents of the carry flip-flop to the content of the A register and place the result into Register A. SUr 10 010 SSS (A)-(A)-(r) Subtract the content of register r from the content of register A and place the result into register A.

34 ACCUMULATOR GROUP INSTRUCTIONS - Cont'd.

SBr 10 011 SSS (A)-(A)-(r)-(borrow) Subtract the content of register r and the content of the carry flip-flop from the content of register A and place the resu It into register A. NDr 10 100 SSS (A)-(A) I\(r) Place the logical product of the register A and register r into register A. XRr 10 101 SSS (A)-(A)V(r) Place the "exclusive - or" of the content of register A and register r into register A. ORr 10 110 SSS (A)-(A)V(r) Place the "inclusive - or" of the content of register A and register r into register A. CPr 10 111 SSS (A)-(r) Compare the content of register A with the content of register r. The content of register A remains unchanged. The flag flip-flops are set by the result of the subtraction.

ALU OPERATIONS WITH MEMORY - One Byte (two cycles - PCI/PCR) Arithmetic and logical operations are carried out between the accumulator and the byte of data addressed by the contents of registers Hand L. ADM 10 000 111 (A)-(A)+(M) ADD ACM 10 001 111 (A)-(A)+(M)+(carry) ADD with carry SUM 10 010 111 (A)-(A)-(M) SUBTRACT SBM 10 011 111 (A)-(A)-(M)-(borrow) SUBTRACT with borrow NDM 10 100 111 (A)-(A)I\(M) Logical AND XRM 10 101 111 (A)-(A)V(M) Exclusive OR ORM 10 110 111 (A)-(A)V(M) Inclusive 0 R CPM 10 111 111 (A)-(M) COMPARE

ALU IMMEDIATE INSTRUCTIONS - Two Bytes (two cycles -PCI/PCR) Arithmetic and logical operations are carried out between the accumulator and the byte of data immediately following the instruction. ADI 00 000 100 (A)-(A)+ ADD ACI 00 001 100 (A)-(A)++(carry) ADD with carry SUI 00 010 100 (A)-(A)- SUBTRACT SBI 00 011 100 (A)-(A)- -(borrow) SUBTRACT with borrow NDI 00 100 100 (A)-(A)I\ Logical AND XRI 00 101 100 (A)-(A)¥ Exclusive OR ORI 00 110 100 (A)-(A)V Inclusive 0 R CPI 00 111 100 (A)- COMPARE

35 ROTATE INSTRUCTIONS - One Byte (one cycle - PCI) The accumulator content (register A) may be rotated either right or left, around the carry bit or through the carry bit. Only the carry flip-f.lop is affected by these instructions; the other flags are unchanged. RLC 00 000 010 A m+1-Am, Ao-A7, (carry)-A7 Rotate the content of register A left one bit. Rotate A7 into Ao and into the carry flip-flop. RRC 00 001 010 A m-Am+1 , A 7-Ao, (carry)-Ao Rotate the content of register A right one bit. Rotate Ao into A7 and into the carry flip-flop. RAL 00 010 010 A m+1-Am ,Ao-(carrY),(carry)-A7 Rotate the content of Register A left one bit. Rotate the content of the carry flip-flop into Ao. Rotate A7 into the carry flip-flop. RAR 00 011 010 Am-Am+1,A7 -(carry), (carry)-Ao Rotate the content of register A right one bit. Rotate the content of the carry flip-flop into A 7. Rotate Ao into the carry flip-flop. PROGRAM COUNTER AND STACK CONTROL INSTRUCTIONS JUMP INSTRUCTIONS - Three Bytes (three cycles - PCI/PCR/PCR) Normal flow of the microprogram may be altered by jumping to an address specified by bytes two and three of an instruction. JMP 01 XXX 100 (P)- Jump unconditionally to the (Jump Unconditionally) instruction located in memory location addressed by byte two and byte three.

JFc 01 OC4C3 000 If (c) = 0, (P)- ' Otherwise, (P) == (P)+3. (Jump if Condition <~> If the content of flip-flop c is zero, then jump to False) the instruction located in memory location ; otherwise, execute the next instruction in sequence.

JTc 01 1C4 C3 000 If (c) == 1, (P)- ' Otherwise, (P) == (P)+3. (Jump if Condition If the content of flip-flop c is one, then jump to the True) instruction located in memory location ; otherwise, execute the next instruction in sequence. CALL INSTRUCTIONS - Three Bytes (three cycles - PCI/PCR/PCR) Subroutines may be called and nested up to seven levels. CAL 01 XXX 110 (Stack)-(P), (P)- . Shift the content of P (Call subroutine to the pushdown stack. Jump unconditionally to the Unconditionally) < B3> instruction located in memory location addressed by byte two and byte three.-

CFc 01 OC4 C3 010 If (c) == 0, (Stack) ..... (P), (Pl-. Otherwise, (Call subroutine (P) == (P)+3. If the content of flip-flop c is zero, then if Condition False) shift contents of P to the pushdown stack and jump to the instruction located in memory location ; otherwise, execute the next instruction in sequence.

CTc 01 1C4 C3 010 If (c) == 1, (Stack)-(P), (P)- . Otherwise, (Call subroutine (P) == (Pl+3. If the content of flip-flop c is one, then if Condition True) shift contents of P to the pushdown stack and jump to the instruction located in memory location ; otherwise, execute the next instruction in sequence. In the above JUMP and CALL instructions < B2 > contains the least significant half of the address and contains the most significant half of the address. Note that D6 and D7 ofare "don't care" bits since the CPU uses fourteen bits of address.

36 RETURN INSTRUCTIONS - One Byte (one cycle - PCI) A return instruction may be used to exit from a subroutine; the stack is popped-up one level at a time. RET 00 XXX 111 (P)-(Stack). Return to the instruction in the memory location addressed by the last value shifted into the pushdown stack. The stack pops up one level. RFc If (c) = 0, (P)-(Stack); otherwise, (P) = (P)+1. (Return Condition If the content of flip-flop c is zero, then return to False) the instruction in the memory location addressed by the la,,( value inserted in the pushdown stack. The stack pops up one level. Otherwise, execute the next instruction in sequence. RTc If (c) = 1, (P)-(Stack); otherwise, (P) = (P)+1. (Return Condition If the content of flip-flop c is one, then return to True) the instruction in the memory location addressed by the last value inserted in the pushdown stack. The stack pops up one level. Otherwise, execute the next instruction in sequence. RESTART INSTRUCTION - One Byte (one cycle - PCI) The restart instruction acts as a one byte call on eight specified locations of page 0, the first 256 instruction words. RET 00 AAA 101 (Stack)-(P) ,(P)-(OOOOOO OOAAAOOO) Shift the contents of P to the pushdown stack. The content, AAA, of the instruction register is shifted into bits 3 through 5 of the P-counter. All other bits of the P-counter are set to zero. As a one­ word "call", eight eight-byte subroutines may be accessed in the lower 64 words of memory. INPUT /OUTPUT I NSTR UCTI ONS One Byte (two cycles - PCI/PCC) Eight input devices may be referenced by the input instruction INP 01 OOM MM1 (A)-(input data lines). The content of register A is made available to external equipment at state T1 of the PCC cycle. The content of the instruction register is made available to external equipment at state T2 of the PCC cycle. New data for the accumulator is loaded at T3 of the PCC cycle. MMM denotes input device number. The content of the condition flip-flops, S,Z,P,C, is output on Do, 0 1 , O2 , 03 respectively at T 4 on the PCC cycle. Twenty-four output devices may be referenced by the output instruction. OUT 01 RRM MM1 (Output data lines)-(A). The content of register A is made available to external equipment at state T1 and the content of the instruction register is made available to external equipment at state T2 of the PCC cycle. R RMMM denotes output device number (R R i- 00). MACHINE INSTRUCTION HALT INSTRUCTION - One Byte (one cycle - PCI) HLT 00 000 OOX On receipt of the Halt Instruction, the activity of the or processor is immediately suspended in the STOPPED 11 111 111 state. The content of all registers and memory is un­ changed. The P-counter has been updated and the internal dynamic memories continue to be refreshed.

37 APPENDIX II

INTERNAL PROCESSOR OPERATION Internally the processor operates through five different states:

Internal State Typical Function NORMAL Send out lower eight bits of address and increment program counter. T1 -----i Send out lower eight bits of address and surpress INTERRUPT incrementing of program counter. Send out six higher order bits of address and two T2 ---l control bits, D6 and D]" Increment program coun­ ter if there has been a carry from T1.

WAIT Wait for READY signal to come true. Refresh in­ ternal dynamic memories while waiting. Fetch and decode instruction; fetch data from T3 ---l NORMAL memory; output data to memory. Refresh internal memories. Remain stopped until INTERRUPT occurs. STOPPED Refresh internal memories. Execute instruction and appropriately transfer data within processor. Content of data bus transfer is available at I/O bus for convenience in testing. T4 and T5 ---l Some cycles do not require these states. In those cases, the states are skipped and the processor goes directly to T1.

The 8008 is driven by two non-overlapping clocks. Two clock periods are requiredJor each state of the processor. A SYNC signal (divide by two of if>2) is sent out by the 8008. This signal distinguishes between the two clock periods of each state.

The following timing diagram shows the typi­ cal activity during each state. Note that if>, is generally used to precharge all data lines and memories and if>2 controls all data transfers within the processor. SYNC J \'------'(

fooIl..r----- ONE MACHINE STATE-----i.~1 I 1 I , 'I 1 I.., I. ..,- '1 PRECHARGE I PRECHARGE 1 WRITE/ INTERNAL , INTERNAL REFRESH MNEMDDDRAYTAA I MEMDRY 1 INTERNAL WRITE & .1 MEMORY BUS I OATA BUS I. • • .1 READ INTERNAL EXECUTE 1 MEMORY AND ALU PRECHARGE OPERATION I ADDER CKTS 1

Figure 15. Internal Timing Activity Within Any State

38 (CYCLE 1) (HLT. INT + RETURN (CF)) + (CYCLE 2) (OUT + LMr) + (CYCLE 3) (LMI + JUMP (CF) + CALL (CF)) l

CYCLE 1 (CYCLE 1) (HL T • iNT) J r-ICYCLE 21 T1 T2 T3 T4 T5 imc"V t (CYCLE 2) (LMI + JUMP + CALL)

(CYCLE 1) (LrM + ALUM + ALUI + INP + OUT + Lrl + JUMP + CALL)

(CYCLE 1) (LMr)

NORMAL RETURN AT END OF MEMORY CYCLE

NOTE: C.F. INDICATES A FAILED CONDITION

Figure 16. Transition State Diagram (Internal)

39 INTERNAL PROCESSOR OPERATION

INDEX REGISTER INSTRUCTIONS

INSTRUCTION CODING #OF STATES MEMORY CYCLE ONE (1) OPERATION TO EXECUTE 0 7 0 6 0 5 0 4 0 3 ~01 DO INSTRUCTION T1 (2) T2 T3 T4(3) T5 1 1 D D D S S S Lrl r2 (5) PCLOUT PCHOUT FETCH INSTR,(5) SSSTO REG. b REG. b TO DD -- (4) TO IR & REG. b (6) 1 1 D D D 1 1 1 LrM (8) PCLOUT PCHOUT FETCH I NSTR. .. TO IR & REG.b (7) 1 1 1 1 1 S S S LMr (7) PCLOUT PCHOUT FETCH INSTR. SSSTO REG. b .. TO IR & REG. b 0 0 D D D 1 1 0 Lrl (8) PCLOUT PCHOUT FETCH INSTR. TO IR & REG.b .. 0 0 1 1 1 1 1 0 LMI (9) PCLOUT PCHOUT FETCH INSTR. .. TO IR & REG.b 0 0 D D D 0 0 1 INr (5) PCLOUT PCHOUT FETCH INSTR. X ADD OP" FLAGS TO IR & REG. b AFFECTED 0 0 D D D 0 0 0 DCr (5) PCLOUT PCHOUT FETCH INSTR. X SUB OP. FLAGS TO IR & REG. b AFFECTED ACCUMULATOR GROUP INSTRUCTIONS 1 0 P P P S S S ALU OP r (5) PC LOUT PCHOUT FETCH INSTR. SSS TO REG. b ALU OP " FLAGS TO IR & REG. b AFFECTED 1 0 P P P 1 1 1 ALU OP M (8) PCLOUT PCHOUT FETCH INSTR. .. TOIR®.b 0 0 P P P 1 0 0 ALU OP I (8) PCLOUT PCHOUT FETCH INSTR. .. TO IR & REG. b 0 0 0 0 0 0 1 0 RLC (5) PC LOUT PCHOUT FETCH INSTR. X ROTATE REG. A TO IR & REG. b CARRY AFFECTED 0 0 0 0 1 0 1 0 RRC (5) PCLOUT PCHOUT FETCH INSTR. X ROTATE REG. A TO IR & REG.b CARRY AFFECTED 0 0 0 1 0 0 1 0 RAL (5) PCLOUT PCHOUT FETCH INSTR. X ROTATE REG. A TOIR®.b CARRY AFFECTED 0 0 0 1 1 0 1 0 RAR (5) PCLOUT PCHOUT FETCH INSTR. X ROTATE REG. A TOIR®.b CARRY AFFECTED PROGRAM COUNTER AND STOCK CONTROL INSTRUCTIONS 0 1 X X X 1 0 0 JMP (11 ) PCLOUT PCHOUT FETCH INSTR. .. TO IR & REG. b 0 1 0 C C 0 0 0 JFc (90rll) PCLOUT PCHOUT FETCH INSTR. .. TO IR & REG. b 0 1 1 C C 0 0 0 JTc (9 or 11) PCLOUT PCHOUT FETCH INSTR. .. TO IR & REG. b 0 1 X X X 1 1 0 CAL (11 ) PCLOUT PCHOUT FETCH INSTR. .. TO IR & REG. b 0 1 0 C C 0 1 0 CFc (9 or 11) PCLOUT PCHOUT FETCH INSTR. .. TOIR®.b 0 1 1 C C 0 1 0 CTc (9 or 11) PCLOUT PCHOUT FETCH INSTR. .. TO IR & REG. b 0 0 X X X 1 1 1 RET (5) PC LOUT PCHOUT FETCH INSTR. POP STACK X TOIR®.b 0 0 0 C C 0 1 1 RFc (30r 5) PCLOUT PCHOUT FETCH INSTR. POP STACK (13) X TOIR®.b 0 0 1 C C 0 1 1 RTc (30r 5) PCLOUT PCHOUT FETCH INSTR. POP STACK (13) X TO IR & REG. b 0 0 A A A 1 0 1 RST (5) PC LOUT PCHOUT FETCH INSTR. REG. a TOPCH REG. b TO PCL TOREG.bAND (14) PUSH STACK (O-REG. a) I/O INSTRUCTIONS 0 1 0 0 M M M 1 INP (8) PCLOUT PCHOUT FETCH INSTR. .. TOIR®.b 0 1 R R M M M 1 OUT (6) PCLOUT PCHOUT FETCH INSTR. .. TO IR & REG.b MACHINE INSTRUCTIONS 0 0 0 0 0 0 0 X HLT (4) PCLOUT PCHOUT FETCH INSTR. TOIR®.b & HALT (18) 1 1 1 1 1 1 1 1 HLT (4) PCLOUT PCHOUT FETCH INSTR. TOIR®.b & HALT (18) NOTES: 1. The first memory cycle is always a PCI (instruction) cycle. 6. Temporary registers are used internally for arithmetic operations 2. Internally, states are defined as Tl through T5. In some cases and data transfers (Register a and Register b.l more than one memory cycle is required to execute an instruction. 7. These states are skipped. 3. Content of the internal data bus at T4 and T5 is available at the 8. PCR cycle (Memory Read Cycle). data bus. This is designed for testing purposes only. 9. "X" denotes an idle state. 4. Lower order address bits in the program counter are denoted 10. PCW cycle (Memory Write Cycle). by PCL and higher order bits are designated by PCH. 11. When the JUMP is conditional and the condition fails, states 5. During an instruction fetch the instruction comes from memory T4 and T5 are skipped and the state counter advances to to the instruction register and is decoded. the next memory cycle.

40 MEMORY CYCLE TWO MEMORY CYCLE THREE

T1 T2 T3 T4 T5 T1 T2 T3 T4 TS

REG. LOUT REG. H OUT DATA TO X REG.b (S) REG.b (9) TO DOD REG. LOUT REG. H OUT REG.b (10) TO OUT PCLOUT (S) PCHOUT DATA TO X REG.b REG.b TO DOD PCLOUT(10) PCHOUT DATA TO REG.L REG.H REG.b .. OUT OUT TO OUT REG.b

REG. LOUT REG. H OUT DATA TO X ALU OP - FLAGS (S) REG.b AFFECTED PCLOUT (S) PCHOUT DATA TO X ARITH OP - FLAGS REG.b AFFECTED

PCLOUT(S) PCHOUT LOWER ADD. PCLOUT PCHOUT HIGHER ADD . REG.a REG.b .. TOPCH TO PCl TO REG. b REG.a PC LOUT (B) PCHOUT LOWER ADD. PCLOUT PCHOUT HIGHER ADD . REG.a REG.b .. TOPCH TO PCl TO REG. b REG.a (11) - - PCLOUT(B) PCHOUT LOWER ADD. PC LOUT PCHOUT HIGHER ADD . REG.a Ht:ll. D .. TOPCH TO PCl TO REG.b REG.a (11) PCLOUT(S) PCHOUT LOWER ADD. .. PC LOUT PCHOUT HIGHER ADD . "REG: a REG.b TO REG. b REG.a TO PCH TO PCl PCLOUT(S) PCHOUT LOWER ADD. PClOUT PCHOUT HIGHER ADD . REG.a REG.b TO REG b .. REG. a (12) TOPCH TO PCl PC LOUT (B) PCHOUT LOWER ADD. PCLOUT PCHOUT f'UGHER ADD. REG.a REG.b .. TO PCH TO pel TO REG. b REG.a ·(12)

REG.A REG.b DATA TO ONDff REG.b TO OUT (1S) TO OUT REG.b IoUT(16 TO REG.A REG. A (1S) REG.b X TO OUT TO OUT (17)

I I I I I I I I 12. When the CALL is conditional and the condition fails, states 15. PCC cycle 0/0 Cycle). T4 and T5 are skipped and the state counter advances to 16. The content of the condition flip·flops is available at the data bus: the next memory cycle. If the condition is true, the stack S at DO, Z at 01, Pat 02, C at 03. Is pushed at T4, and the lower and higher order address 17. A READY command must be supplied for the OUT operation bytes are loaded into the program counter. to be completed. An idle T3 state is used and then the state 13. When the RETURN condition is true, pop up the stack; counter advances to the next memory cycle. otherwise, advance to next memory cycle skipping T4 and T5. 18. When a HALT command occurs, the CPU internally remains 14. Bits 03 through Os are loaded into PCL and all other bits in the T3 state until an INTERRUPT is recognized. Externally. are set to zero; zeros are loaded into PCH. the STOPPED state is indicated.

41 101-103

INITIALIZE H & L TO 200

104

104 FETCH CHARACTER FROM MEMORY (H & L ADDRESS)

RETURN

CALL SUBROUTINE TO INCREMENT H&L

Figure 17. Subroutine to Search For Period

42 APPENDIX III PROGRAMMING EXAMPLE

Sample Program To Search A String Of Characters In Memory Locations 200-220 For A Period (.)

MNEMONIC OPERAND EXPLANATION BYTES LOCATION ROM CODE COMMENT LLI 200 Load L with 200 2 100 00110110 101 11001000 (200) LHI 0 Load H with 0 2 102 00101110 103 00000000 (0) Loop: LAM Fetch Character from 104 11000111 ASC II Memory CPI " •" Compare it with period 2 105 00111100 106 00101110 ( .) JTZ Found If equal go to return 3 107 01101000 108 01110111 ( 119) 109 00000000 CAL INCR Call increment H&L 3 110 01000110 subroutine 111 00111100 (60) 112 00000000 LAL Load L to A 113 11000110 CPI 220 Compare it with 220 2 114 00111100 115 11011100 (220) JFZ Loop If unequal go to loop 3 116 01001000 117 01101000 (104) 118 00000000 Found: RET Return 119 00000111 INCR: INL Increment L 60 00110000 RFZ Return if not zero 61 00001011 INH Increment H 1 62 00101000 RET Return 1 63 00000111

43 Packaging Information Ordering Information (1) The 8008 CPU is available in ceramic only and should be ordered as C8008. (2) SIMS-01 Prototyping System This MCS-8 system for program development provides complete interface between the CPU and ROMs and RAMs. 1702 electrically pro­ grammable and erasable ROMs may be used for the program development. Each board contains one 8008 CPU, 1 K x 8 RAM, and sockets for up to eight 1702's(2Kx8PROM). CERAMIC PACKAGE OUTLINE This system should be ordered as SIM8-01 ALTERNATE PIN #1 IDENT. (I F NO NOTCH AT END OF PKG.' ~~ (the number of PROMs should also be spe­ cified). Contact Intel regarding availability. '0 J I.275 L ~ (3) Memory Expansion Additional memory for the 8008 may be developed from individual memory com­ ponents. Specify RAM 1101 ROM 1702/1602 SR 1404 1103 1301 2401 Complete RAM memory systems are available from I ntel's Memory System Group. Specify in-14 in-16 in-20 8K x 8 4K x 8 1 K x 8 (4) MP7-02 ROM Programmer This is the programmer board for 1601/1701 or 1602/1702. The three 1602 control ROMs used with the SIM8-01 for an automatic pro­ gramming system are specified by pattern numbers A0660, A0661, A0662. Contact Intel regarding availability.

U. S. REGIONAL SALES OFFICES Western Tustin, California 92680 17401 Irving Blvd., Suite K (714) 838-1126, TWX 910-595-1114

Central Bloomington, Minnesota 55437 800 Southgate Office Plaza, 500 West 78th St. (612) 925-3144

Eastern Lexington, Mass. 02173 594 Marrett Road, Suite 27 (617) 861-1136, Telex: 923493

ORIENT SALES OFFICE EUROPEAN SALES OFFICE

Japan Tokyo 160 INTEL JAPAN CORP. Belgium Bruxelles INTEL CORP. Han-Ei 2nd Bldg. 216 Avenue Louise 1-1, Shinjuku, Bruxelles 1050, Belgium Shinjuku-Ku Phone: 492003 Tokyo 160, Japan Telex: 21060 03-354-8251 Telex: 28426

44 MCS-8 INSTRUCTION SET

Index Register Instructions The load instructions do not affect the flag flip-flops. The increment and decrement instructions affect all flip· flops except the carry. MINIMUM INSTRUCTION CODE MNEMONIC STATES DJo 06 Os 04 03 C7: 0, DO DESCRIPTION OF OPERATION REQUIRED

(lILr1r2 151 1 1 0 D D 5 5 5 Load index register " with the content of index register '2. \""LILrM 181 1 1 D 0 0 1 1 Load index register r with the content of memory register M. LM, 171 1 1 5 S Load memory register M with the content of index register r. 3 Lri 181 0 D 1 1 0 Load index register r with data B ... B. B B B B B B B B LMI 191 0 0 Load memory register M with data B ..• B. B 8 IN, 151 0 0 D D 0 0 0 I ncrement the content of index register r (r j A). DC, 151 0 0 D D 0 0 1 Decrement the content of index register r (r '" A). Accumulator Group Instructions

The result of the ALU instructions affect all of the flag flip~flops. The rotate instructions affect only the carry flip~flop.

AD, 151 1 0 0 0 5 5 5 Add the content of index register r, memory register lVI, or data ADM 181 1 0 0 0 1 1 1 8 .•. 8 to the accumulator. ADI lSi 0 0 0 0 0 1 0 0 8 8 B B B B B AC, 151 0 0 0 5 5 5 Add the content of index register r, memory register M, or data ACM 181 0 0 8 .•. 8 to the accumulator with carry. ACI 181 0 0 1 8 B 8 B 8 8 B B 5U, 151 0 0 1 0 5 5 5 Subtract the content of index register r, memory register M, or SUM (8) 0 1 data 8 ... 8 from the accumulator. 5UI 181 0 1 B 8 B B B 8 5B, 151 1 0 1 1 5 5 Subtract the content of index register r, memory register M, or 58M 181 1 0 0 1 1 1 1 data 8 ... B from the accumulator with borrow. 581 181 0 0 0 1 1 0 B B B B 8 8 B ND, 151 1 0 1 0 0 5 5 5 Compute the logical AND of the content of index register r, NDM 181 1 0 1 0 0 1 1 1 memory register M, or data 8 ... B with the accumulator. NDI 181 0 0 0 0 1 0 0 B B B B B 8 XR, 151 1 0 1 0 1 5 5 Compute the EXCLUSIVE OR of the content of index register XRM 181 1 0 1 0 1 1 1 r, memory register M, or data 8 .•. 6 with the accumulator. XRI lSi 0 0 1 0 1 1 0 B B B B B B B 8 OR, 151 1 0 1 1 0 5 5 5 Compute the INCLUSIVE OR of the content of index register ORM 181 1 0 1 1 0 1 1 1 r, memory register m, or data 8 •.• 6 with the accumulator. ORI 181 0 0 1 0 0 0 8 8 B 8 B 8 CP, 151 1 0 1 1 1 5 5 5 Compare the content of index register r, memory register M, CPM 181 1 0 1 1 1 1 1 1 or data B ... 6 with the accumulator. The content of the CPI 181 0 0 1 1 1 1 0 0 accumulator Is unchanged. B B B B B B RLC 151 0 0 0 0 1 0 Rotate the content of the accumulator left. RRC 151 0 0 0 0 0 1 0 Rotate the content of the accumulator right. RAL 151 0 0 0 1 0 1 0 Rotate the content of the accumulator left through the carry. RAR 151 0 0 0 1 1 0 1 0 Rotate the content of the accumulator right through the carry. Program Counter and Stack Control Instructions

141JMP 1111 0 1 X X X 1 0 0 i Unconditionally jump to memory address 83 .•• 8382 ... 82· 82 82 82 6 2 8 2 82 8 2 8 2 X X 83 8 3 8 3 83 83 83 (5) JFc (9 or 111 0 1 0 C4 C3 000 IJump to memory address 83 ... 8 38 2 ... 82 if the condition 82 82 82 8 2 8 2 82 8 2 8 2 fljp~flop c is false. Otherwise, execute the next instruction in sequence. X X 83 8 3 8 3 83 8 3 8 3 JTe (9 or 11) 0 1 1 C4 C3 000 I Jump to memory address 83 ... B 382 ... 82 if the condition 82 82 82 ~ 82 82 82 82 flip~flop c is true. Otherwise, execute the next instruction in sequence. X X 63 8 3 83 83 8 3 83 CAL 1111 0 1 X X X 1 1 0 Unconditionally call the subroutine at memory address 83 ... B2 a, B2 a, a, B2 a, a, 8382 ..• 82. Save the current address (up one level in the stack). X X B3 B3 B:3 83 8 3 8 3 CFe (9 or 111 0 1 0 C4 C3 0 1 0 Call the subroutine at memory address 83 ..• 8382 ..• 82 if the a, 82 82 82 ~ ~ 82 82 condition flip-flop c is false, and save the current address (up one X X 83 83 83 83 B3 B3 level in the stack.) Otherwise, execute the next instruction in sequence. CTe (90r 11) 0 1 1 C4 C 3 0 1 0 Call the subroutine at memory address B3 ... 8382 •.. 82 if the a, B2 82 ~ 82 a, a, B2 condition flip-flop c is true, and save the current address (up one X X 83 8 3 8 3 83 B3 83 level in the stack). Otherwise. execute the next instruction in sequence. RET 151 0 0 X X X 1 1 1 Unconditionally return (down one level in the stack). RFe (3 or 5) 0 0 0 C4 C3 0 1 1 Return (down one level in the stack) if the condition flip-flop c is false. Otherwise, execute the next instruction in sequence. RTe (3 or 5) 0 0 1 C4 C3 0 1 1 Return (down one level in the stack) if the condition flip-flop c is true. Otherwise, execute the next instruction in sequence. RES 151 0 0 A A A 1 0 1 ! Call the subroutine at memory address AAAOOO (up one level in the Istack). \ Input/Output Instructions INP 18i 0 1 0 0 M M M 1 Read the content of the selected input port (MMM) into the accumulator. OUT 161 0 1 R R M M M 1 Write the content of the accumulator into the selected output port (RRMMM, RR f. DOl. Machine Instruction HLT 141 0 0 0 0 0 0 0 X Enter the STOPPED state and remain there until interrupted. HLT 141 1 1 1 1 1 1 1 1 Enter the STOPPED state and remain there until interrupted". NOTES. (1) SSS = Source Index Register } These registers, '1. are designated A(accumulator-OOO), DOD'" Destination Index Register 8to01), C(010}, 0(011), E(100), H(101), L(1101. (2) Memory registers are addressed by the contents of registers H & L. (3) Additional bytes of instruction are designated by BBBBBBBB. (4) X = "Don't Care". (5) Flag flip-flops are defined by C4C3: carry (00)' zero (01). sign {10l, parity (111.

45

INTEL CORP. 3065 Bowers Avenue, Santa Clara , California 95051 • (408) 246-7501

Printed in U.S.A .