Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Rohini 69771659590

Download as pdf or txt
Download as pdf or txt
You are on page 1of 7

ROHINI COLLEGE OF ENGINEERING & TECHNOLOGY

1.2 ARCHITECTURE OF INTEL 8085 MICROPROCESSOR


Features of 8085
 Intel 8085 is an 8-bit, NMOS microprocessor.
 It is a 40 pin I.C. package fabricated on a single LSI chip.
 The Intel 8085 uses a single +5Vd.c. supply for its operation
 Its clock speed is about 3 MHz
 The clock cycle is of 320 ns.
 It has 80 basic instructions and 256 opcodes.
Figure 1.2.1 shows the functional block diagram of Intel 8085. It consists of three main
sections:
[1] Arithmetic and Logic Unit (ALU)
[2] Timing & Control Unit
[3] Set of registers.

Figure 1.2.1 Architecture 8085 processor


[Source: “Microprocessor Architecture Programming and Application” by R.S. Gaonkar, page-72]

EE8551 MICROPROCESSOR AND MICROCONTROLLER


ROHINI COLLEGE OF ENGINEERING & TECHNOLOGY

1. ALU (Arithmetic & Logic Unit):


As the name suggest, ALU i.e arithmetic & logic unit performs the following
arithmetic & logical opeartions:
i. Addition
ii. Subtraction
iii. Logical AND
iv. Logical OR
v. Logical EXCLUSIVE OR
vi. Complement (logical NOT)
vii. Increment (add 1)
viii. Decrement (Subtract 1)
ix. Left shift, Rotate left, Rorate Right
x. Cler, etc.
2. Timing & Control Unit:
 It generates timing & control signals which are necessary for the execution of
instructions.
 It controls data flow between CPU and peripherals including memory.
 It provides status, control and timing signals which are required for the operation
of memory and I/O devices.
 It controls entire operations of the microprocessor and peripherals connected to it.
 Thus it is seen that the control unit of the CPU acts as the brain of the computer
system.
3. Set of Registers:
 Fig 1.2.1 shows the various registers of Intel 8085 which are used by the
microprocessor for temporary storage and manipulation of data and intsructions.
 Intel 8085 microprocessor has the following registers:
i. One 8-bit Accumulator (ACC) i.e register A
ii. Six 8-bit general purpose registers. These are B, C, D, E, H & L
iii. One 16-bit stack pointer, SP
iv. One 16-bit program Counter, PC

EE8551 MICROPROCESSOR AND MICROCONTROLLER


ROHINI COLLEGE OF ENGINEERING & TECHNOLOGY

v. Intruction register
vi. Temporary register
 In addition to the above mentioned regiter the 8085 microprocessor contains a set
of five flipflops which serve as flag (or status flags). A flag is a flipflop which
indicates some condition which arises after execution of an arithmetic or logical
instruction.
Accumulator:
 The accumulator (register A) is an 8-bit register associated with ALU.
 It is used to hold one of the operands of an arithmetic or logical operation.
 It serves as one input to the ALU. The other operand for an arithmetic or logical
opeartion may be stored either in the memroy or in one of the general purpose
registers.
 Final result of an arithmetic or logical operation is placed in the accumulator.
General Purpose Registers
 The 8085 microprocessor contains six 8-bit general purpose registers. They are B,
C, D, E, H and L.
 To hold 16-bit data a combination of two 8-bit registers can be employed which
known as register pairs.
 The valid register pairs in 8051 are B-C, D-E and H-L. the programmer cannot
form the register pair by selecting any two registers of his choice.
 The H-L pair is used to act as memory pointer and for this purpose it holds the 16-
bit address of a memory location.
 The general purpose registers and the accumulator are accessible to programmer.
He can store data in these registers during writing his program.
Program Counter (PC):
 It is a 16-bit special purpose register used to hold the memory address of the next
instruction which is to be executed.
 It keeps the track of memory addresses of the instructions in the program while
they are being executed.

EE8551 MICROPROCESSOR AND MICROCONTROLLER


ROHINI COLLEGE OF ENGINEERING & TECHNOLOGY

 The microprocessor increments the content of the program counter during the
execution of an instruction so that it points to the address of the next instruction in
the program at the end of the execution of an instruction.
Stack Pointer (SP):
 It is a 16-bit special purpose register.
 “Stack is a sequence of memory location set aside by the programmer to
store/retrieve the content of accumulator, flags, program counter and general
purpose registers during the execution of a program.
 Any portion of the memory can be used as stack. Since the stack works on LIFO
(last in first out) principle, its operation is faster compared normal store/ retrieve
of memory locations.
 “The SP holds the address of the top element of data stored in the stack.
 “The stack is defined and stack pointer is initialized by the programmer at the
beginning of a program which needs stack operation. Stack is also used by the
microprocessor. For example, it stores the contents of program counter when it
jumps to a subroutine using CALL instruction.
Instruction Register:
 The instruction register holds the opcode (operation code or instruction code) of
the instruction which is being decoded and executed.
Temporary Register:
 It is an 8-bit register associated with ALU. It holds data during an
arithmetic/logical operation.
 It is used by microprocessor.
 It is not accessible to programmer.
Flags (Program Status Word i.e. PSW):
 The Intel 8085 microprocessor contains five flip-flops to serve as status flags.
 The flip-flops are set or reset according to the conditions which arises during an
arithmetic or logical operation.
 The five status flags of Intel 8085 are:
i. Carry flag (CS)

EE8551 MICROPROCESSOR AND MICROCONTROLLER


ROHINI COLLEGE OF ENGINEERING & TECHNOLOGY

ii. Parity Flag (P)


iii. Auxiliary Carry Flag (AC)
iv. Zero Flag (Z)
v. Sign Flag (S)
 In fig 1.2.2, five bits indicates the five status flags and three bits are undefined.
“The combination of these 8-bits is called Program Status Word (PSW)”. PSW and
the accumulator are treated as a 16-bit unit for stack operation.

Figure 1.2.2 Flag Register


[Source: “Microprocessor Architecture Programming and Application” by R.S. Gaonkar, page-72]

Carry Flag (CS):


 After execution of an arithmetic instruction if carry is produced, the carry flag CS
is set to 1. Otherwise it is 0.
 The carry flag is set or reset in case of addition as well as subtraction.
 After the addition of two 8-bit numbers, if the sum is larger than 8-bits, a carry is
produce; and the carry flag is set to 1.
 In case of subtraction, if borrow occurs, the carry flag is set to 1.
 The carry flag holds carry out of the most significant bit resulting from the
execution of an arithmetic operation.
Parity Flag (P):
 The parity flag P is set to 1, if the result of an arithmetic or logical operation
contains even number of 1s.
 It is reset i.e it is 0, if the result contains odd number of 1s.

EE8551 MICROPROCESSOR AND MICROCONTROLLER


ROHINI COLLEGE OF ENGINEERING & TECHNOLOGY

Auxiliary Carry Flag (AC):


 The auxiliary carry flag AC hold carry out of the bit number 3 to the bit number 4
resulting from the execution of an arithmetic operation.
 The counting of bits starts from 0, and hence Bit No.3 is actually the fourth bit
from the least significant bit.
Zero Flag (Z):
 The zero status flag Z is set to 1, if the result of an arithmetic or logical operation
is Zero otherwise it is set to 0.
Sign Flag (S):
 The sign flag S is set to 1, if the result of an arithmetic or logical operation is
negative. If the result is positive, the sign flag is set to 0.
 The sign flag has significance only when signed arithmetic operation is performed.
To represent a signed numbed the most significant bit is reserved by the
programmer to represent the sign of a number.
 In other words, the MSB is used as a sign bit.
 If the number is negative, the sign bit is 1. For positive, sign bit is 0.
 In case of 8-bit sign operation, the remaining 7 bits are used to represent the
magnitude of a number.
Data and Address bus:
 The Intel 8085 is an 8-bit microprocessor. Its data bus is 8-bit wide and hence, 8bit
of data can be transmitted in parallel from or to the microprocessor.
 The Intel 8085 requires a 16-bit wide address bus as the memory addresses are of
16 bits.
 The 8 most significant bits of the address are transmitted by the address bus, a-bus
(pins A8 to A15).
 The least significant bits of address are transmitted by address/ data bus, AD-bus
(pins AD0 to AD7).
 The address/ data bus transmits data and address at different moments. At a
particular moment it transmits either data or address. Thus AD-bus operates in time
shared mode.

EE8551 MICROPROCESSOR AND MICROCONTROLLER


ROHINI COLLEGE OF ENGINEERING & TECHNOLOGY

 This technique is known as multiplexing. First all 16-bit memory address is


transmitted by the microprocessor; the 8 MSBs of the address on A-bus and the 8
LSBs of the address on AD- bus. Thus effective width of address bus becomes 16
bit wide.

EE8551 MICROPROCESSOR AND MICROCONTROLLER

You might also like