Professional Documents
Culture Documents
18 July 2013
Module 1
Basics of 8085
Basic 8085 microprocessor architecture and its functional blocks. 8085 microprocessor IC pin outs and signals, address, data and control buses. 8085 features
Prepared By AJIT SARAF
INTA INTR
SID
SOD
Interrupt control
Accumulator
Temporary register
Flag register
Instruction register
Instruction Decoder And Machine Cycle encoder
POWER SUPPLY
+5V GND
X1
CLK IN
X2
CONTROL
STATUS
DMA
RESET
RD WR
ALE S0
S1 IO/M
HOLD
Address buffer
A15 A8 Address bus
Address/Data buffer
AD7 AD0 Data / Address bus
Architecture of 8085
18 July 2013
Registers
General Purpose Registers (Scratchpad registers) ( B, C, D, E, H, L ) Temporary Registers. 1) Temporary data register. 2) W and Z registers Special Purpose Registers. 1) Accumulator (A) 2) Flag registers. 3) Instruction register. 4) Program Counter (PC). 5) Stack Pointer (SP).
Temporary Registers
1) Temporary data register. One of the Input of ALU. Not accessible for user. Internally used for execution of most of the arithmetic and logical instructions. 2) W and Z registers Used to hold 8-bit data during execution of some instructions. Not available for programmer. 8085 uses them internally. Used in CALL and XCHG instructions.
18 July 2013
Accumulator
8-bit Special Purpose Register. It is a multipurpose register. Accumulate the result. One of the input to the ALU. Extensively used in arithmetic, logical, load and store as well as input/output operations. It holds operands & result of ALU operations.
Flag Register
Flag is nothing but group of flipflops. 8-bit Register. It provides status of the result to the user. User can access this register. Flag get affected only when operation is to be performed in ALU.
Flag Register
D7 D6 D5 D4 D3 D2 D1 D0 S Z AC P CY
Instruction Register
Used to hold operation code of the current instruction. User can read content of Instruction register. The instruction register is loaded during the opcode fetch cycle. This register is only activated when instruction code or opcode is available for programmer use.
S-Sign Flag. Z-Zero Flag. AC-Auxiliary Carry Flag. P-Parity Flag. CY-Carry Flag.
18 July 2013
Program Counter
16-bit register used for execution of program. Program is a series of instructions stored in the memory. These instructions must be executed in a proper order to get the correct result. This sequence of instruction execution is monitored by the program counter. It stores address of the next instruction to be fetched and executed. This register always points to address of program memory where the next instruction is to be fetched and executed so it acts as a memory pointer. When reset is activated PC is set to the location 0000H (Starting location of ROM).
Stack Pointer
Stack is a reserved are of the memory in the RAM. Before going to the subroutine program next instruction location (Return address) is stored in stack. The memory address of the stack area is given by a special register called the stack pointer. 16-bit register used to define the stack starting address. It points to the current stack location. It always points to the top of the stack. Usually stack operations are 2 byte operations. Stack operates in LIFO (Last In First Out).
Instruction Decoder
It accepts bit pattern from instruction register decodes it and sends decoded information to the timing and control circuit. It is 8:256 Decoder.
18 July 2013
Address Buffer
8-bit unidirectional buffer. It is used to drive external high order address bus (A15 - A8). Used to tri-state the high order address bus under certain conditions such as reset, hold, halt and when address lines are not in use.
Address/Data Buffer
8-bit bi-directional buffer. It is used to drive multiplexed address/data bus, i.e. low order address bus (A7 A0) and data bus (D7 D0). Used to tri-state the multiplexed address/data bus under certain conditions such as reset, hold, halt and when address lines are not in use
Interrupt Control
The occurrence of special condition is referred to as interrupt. This block has five interrupt request inputs such as TRAP, RST7.5, RST6.5, RST5.5, INTR and one acknowledge signal INTA.
18 July 2013
X1
X2 RESET OUT SOD SID TRAP RST 7.5 RST 6.5 RST 5.5 INTR INTA AD0 AD1 AD2 AD3 AD4 AD5 AD6 AD7 Vss
8 0 8 5
18 July 2013
18 July 2013
Interrupt Signals
TRAP: It is an Edge & Level triggered highest priority, non mask able interrupt. After TRAP, restart occurs and execution starts from address 0024H. RST 7.5, 6.5, 5.5: These are maskable interrupts and have low priority than TRAP. INTR & INTA: INTR is a interrupt request signal after which P generates INTA or interrupt acknowledge signal.
DMA Signals
HOLD & HLDA: HOLD is an input signal. When P receives HOLD signal it completes current machine cycle and stops executing next instruction. In response to HOLD P generates HLDA that is HOLD Acknowledge signal.
18 July 2013
Reset Signals
RESETIN: This is input signal. When RESETIN is low p restarts and starts executing from location 0000H. RESETOUT: Used to reset connecting peripherals.
Features of 8085
It is an 8-bit microprocessor. It is a single chip N-MOS device with 40 pins. It works on 5 Volt dc power supply. It operates on a clock cycle with 50% duty cycle. It has on chip clock generator. The maximum clock frequency is 3 MHz while minimum frequency is 500kHz. It has multiplexed address and data bus.(AD0-AD7) to reduce number of external pins. It provides 74 instructions with 5 different addressing.
Features of 8085
It generates 8 bit I/O address so it can access 2^8 = 256 I/O ports. It provides 16 address lines so it can access 2^16 = 64Kbytes of memory. It provides Acc, one flag register, 6 general purpose registers and two special purpose registers (SP,PC). It provides 5 hardware interrupts, TRAP, RST 5.5, RST 6.5, RST 7.5,INTR. It provides serial lines SID, SOD. So serial peripherals can be interfaced with 8085 directly.
Features of 8085
It provides control signals (IO/M, RD, WR) to control the bus cycles, and hence external bus controller is not required.
18 July 2013
architecture
10