Sunteți pe pagina 1din 10

MICROPROCESSOR LAB MANUAL

INTRODUCTION TO MICROPROCESSOR 8085


Aim

To study the basics of 8085 microprocessor


To study the 8085 microprocessor kits

Theory
The salient features of 8085 processor are
It is a 8 bit microprocessor.
It is manufactured with N-MOS technology.
It has 16-bit address bus and hence can address up to 216 = 65536 bytes (64KB)
memory locations through A -A .
0

15

The first 8 lines of address bus and 8 lines of data bus are multiplexed AD AD .

Data bus is a group of 8 lines D D .

It supports external interrupt request.


A 16 bit program counter (PC)
A 16 bit stack pointer (SP)
Six 8-bit general purpose register arranged in pairs: BC, DE, HL.
It requires a signal +5V power supply and operates at 3.2 MHZ single phase clock.
It is enclosed with 40 pins DIP (Dual in line package).

Architecture of 8085 Microprocessor


a) General purpose registers
In 8085 there are 6 general purpose 8 bit registers i.e. B,C,D,E,H and L. The combination of 8
bit register is known as register pair, which can hold 16 bit data. The possible register pairs
in 8085 are B-C, D-E and H-L. Here HL pair is used as the memory pointer.
b) Accumulator
It is an 8 bit register which holds one of the data to be processed by ALU and stores the
result of the operation.
c) Program counter (PC)
This 16-bit register deals with sequencing the execution of instructions. Thus PC contains
the address of next instructions to be executed.
d) Stack pointer (Sp)
It is a 16 bit special purpose register which is used to hold memory address of stack top.

1
Dept. of EEE

T.K.M COLLEGE OF ENGINEERING

MICROPROCESSOR LAB MANUAL

e) Arithmetic and logical unit


It carries out all arithmetic and logical operation between accumulator content and memory
or internal register contents and the ALU result is stored back into accumulator.
f) Temporary register
It is an 8 bit register associated with ALU which hold data for operation temporarily and is
not accessible to the programmer.
g) Flags
Flag Register has five 1-bit flags.
Sign - set if the most significant bit of the result is set.
Zero - set if the result is zero.
Auxiliary carry - set if there was a carry out from bit 3 to bit 4 of the result.
Parity - set if the parity (the number of set bits in the result) is even.
Carry - set if there was a carry during addition, or borrow during
subtraction/comparison/rotation.

h) Increment/decrement register

The 8-bit contents of a register or a memory location can be incremented or


decremented by 1.
This 16-bit register is used to increment or decrement the content of program
counter and stack pointer register by 1.
Increment or decrement can be performed on any register or a memory location.

i) Address /data buffer and address buffer:

The contents of the stack pointer and program counter are loaded into the address
buffer and address-data buffer.
These buffers are then used to drive the external address bus and address-data bus.
As the memory and I/O chips are connected to these buses, the CPU can exchange
desired data to the memory and I/O chips.
The address-data buffer is not only connected to the external data bus but also to
the internal data bus which consists of 8-bits.
The address data buffer can both send and receive data from internal data bus.

j) Interrupts signals
8085 processor has 5 interrupts. They are presented below in the order of their priority
(from lowest to highest)
INTR

RST5.5

RST6.5

RST7.5

TRAP

2
Dept. of EEE

T.K.M COLLEGE OF ENGINEERING

MICROPROCESSOR LAB MANUAL

k) Reset Signals
RESET IN
When this signal goes low Program counter is set to zeroes , p is reset and resets the
interrupt enable and HLDA flip-flops.
RESET OUT:
This signal indicates that p is being reset. This signal can be used to reset other devices.
The signal is synchronized to the processor clock and lasts an integral number of clock
periods.
l) Serial communication Signal
SID - Serial Input Data Line:
The data on this line is loaded into accumulator bit 7 whenever a RIM instruction is
executed.
SOD Serial Output Data Line:
The SIM instruction loads the value of bit 7 of the accumulator into SOD latch if bit 6 (SOE)
of the accumulator is 1.
m) Instruction register and decoder:

Instruction register is 8-bit register just like every other register of microprocessor.
The instruction may be anything like adding two data's, moving a data, copying a
data etc.
When such an instruction is fetched from memory, it is directed to Instruction
register. So the instruction registers are specifically to store the instructions that are
fetched from memory.
There is an Instruction decoder which decodes the information present in the
Instruction register for further processing.

n) DMA Signals
HOLD:

Indicates that another master is requesting the use of the address and data buses.
The CPU, upon receiving the hold request, will relinquish the use of the bus as soon
as the completion of the current bus transfer.
Internal processing can continue. The processor can regain the bus only after the
HOLD is removed.

3
Dept. of EEE

T.K.M COLLEGE OF ENGINEERING

MICROPROCESSOR LAB MANUAL

HLDA: Hold Acknowledge:


Indicates that the CPU has received the HOLD request and that it will relinquish the bus in
the next clock cycle.
o) READY:

This signal Synchronizes the fast CPU and the slow memory, peripherals.
If READY is high during a read or write cycle, it indicates that the memory or
peripheral is ready to send or receive data.
If READY is low, the CPU will wait an integral number of clock cycle for READY to go
high before completing the read or write cycle.

p) Timing and control unit:

Timing and control unit is a very important unit as it synchronizes the registers and
flow of data through various registers and other units.
This unit consists of an oscillator and controller sequencer which sends control
signals needed for internal and external control of data and other units.
The oscillator generates two-phase clock signals which aids in synchronizing all the
registers of 8085 microprocessor.

4
Dept. of EEE

T.K.M COLLEGE OF ENGINEERING

MICROPROCESSOR LAB MANUAL

PIN Description (40 pins)


Address Bus (8 pin)8
1. The pins Ao A15 denote the address bus.
2. They are used for most significant bit
Address / Data Bus (8 pin) 16
1. AD0 AD7 constitutes the address / Data bus
2. These pins are used for least significant bit
ALE : (Address Latch Enable) (1 pin) 17
1. The signal goes high during the first clock cycle and enables the lower
order address bits.
IO/

(1 pin) 18
1. This distinguishes whether the address is for memory or input.
2. When this pins go high, the address is for an I/O device.

S0 S1 (2 pin).20
S0 and S1 are status signal which provides different status and functions.
(1pin)..21
1. This is an active low signal
2. This signal is used to control READ operation of the microprocessor.
(1pin)..22
1. This is also an active low signal
2. Controls the write operation of the microprocessor.
HOLD (1pin).. 23
1. This indicates if any other device is requesting the use of address and data bus.
HLDA (1pin)...24
1. HLDA is the acknowledgement signal for HOLD
2. It indicates whether the hold signal is received or not.
INTR (1pin)....25
1. INTE is an interrupt request signal
2. IT can be enabled or disabled by using software
(1pin)..26
1. Whenever the microprocessor receives interrupt signal
2. It has to be acknowledged.

5
Dept. of EEE

T.K.M COLLEGE OF ENGINEERING

MICROPROCESSOR LAB MANUAL

RST 5.5, 6.5, 7.5 (3pin)29


1. These are nothing but the restart interrupts
2. They insert an internal restart junction automatically.

6
Dept. of EEE

T.K.M COLLEGE OF ENGINEERING

MICROPROCESSOR LAB MANUAL

TRAP (1pin)..30
1. Trap is the only non-maskable interrupt
2. It cannot be enabled (or) disabled using program.
RESET IN (1pin)...31
1. This pin resets the program counter to 0 to 1 and results interrupt enable and
HLDA flip flops.
RESET OUT (1pin) )...32

It indicates CPU is being reset.


Used to reset all the connected devices when the microprocessor is reset.

READY (1 pin) ...33

Memory and I/O devices will have slower response compared to microprocessors.
Before completing the present job such a slow peripheral may not be able to handle
further data or control signal from CPU.
The processor sets the READY signal after completing the present job to access the
data.
The microprocessor enters into WAIT state while the READY pin is disabled.

X1, X2 (2pin)...35
These are the terminals which are connected to external oscillator to produce the necessary
and suitable clock operation.
CLK (1 pin)..36
Clock Output is used as the system clock for peripheral and devices
SID (1pin)..37
This pin provides serial input data
SOD (1pin)...38
This pin provides serial output data
VCC and VSS (2 pin ).. .40
1. VCC is +5V supply pin
2. VSS is ground pin

7
Dept. of EEE

T.K.M COLLEGE OF ENGINEERING

MICROPROCESSOR LAB MANUAL

STUDY OF STS 8085 MICROPROCESSOR KIT


STS 8085 microprocessor kit includes
8085 microprocessor
32Kb RAM
32 Kb ROM
16 bit programmable timer / Counter
Programmable peripheral Interface(PPI)8255
Interrupt controller(8259)
28 key keyboard,
6 seven segment LED for display.
The keyboard and the display are interfaced with 8085 through the keyboard/display
interface 8279. The keyboard enables the user to enter and store the 8085 hex machine
code representing the 8085 assembly language programs on R/W memory. A program can
be executed using the function keys on the keyboard and the result can be displayed on the
7 segment LEDs. The LEDs are also used to display memory addresses and their contents
while entering, modifying or examining the programs.

KEYBOARD DESCRIPTION
STS 8085 LED has 28 keys and 6 digit seven segment display to communicate with outside
world. When the system initially is switched on a message STS 85 is displayed. The
following are the commands which are selected using the keys.
RESET
VCT INT
SHIFT
GO
EMEM

- Reset the system.


- Hardware interrupt via keyboard, RST 7.5.
- Provides dual function to all keys.
- To execute a program.
- Examine memory helps the user to examine any memory location and modify
any location.
REG
- Examine register and modify the contents.
PRE
- To verify the contents of previous memory location from that of existing location.
NEXT
- To verify the contents of next memory location.
.
- Terminator used to terminate the command.
DEL
- Delete the part of the program or data with relocation by one or more bytes.
INS
- Insert the part of the program or data with relocation by one or more bytes.
BLOCK MOVE Allows user to move a block of memory to any RAM area.
FILL
- Allows user to fill RAM area with a constant.
REL
- Relocate program written for some memory area to be transferred to another
area.
INSD
- Inserts one or more bytes in the users program/ data area.
DELD
- Deletes one or more data bytes in the users program/data area.
STRG
- Finds out the strings of data lying at a particular address or addresses.
MEMC
- Memory compare used for comparing two blocks of memory for equality.
0-F
- Hexadecimal keys.

8
Dept. of EEE

T.K.M COLLEGE OF ENGINEERING

MICROPROCESSOR LAB MANUAL

All commads are followed by a set of numerical parameters by PREV, NEXT and . (execute)
to work as delimiters.
A - on MSD shows that the system is waiting for a command.
Err shows an invalid command.
A . on the LSD of address field shows that system expects an address.
Assembly language program for addition of two 8 bit numbers is shown below:
MVI A, 32
MVI B, 12
ADD B
STA 2150
HLT
PRESS

ADDRESS FIELD

RESET
EMEM
2100
NEXT

XXXX

3E
NEXT
32
NEXT
06
NEXT
12
NEXT
80
NEXT
32
NEXT
50
NEXT
21
NEXT
76

2100
2101
2101
2102
2102
2103
2103
2104
2104
2105
2105
2106
2106
2107
2107
2108
2108

DATA FIELD

2100
2100
3E
32
06
12
80
32
50
21
76

To modify the contents of a memory location, press


1. EMEM Memory address and NEXT : Memory addresses and its content will be
displayed.
2. New data byte and NEXT: New data byte will be stored and its contents will be
displayed.
To execute the program
9
Dept. of EEE

T.K.M COLLEGE OF ENGINEERING

MICROPROCESSOR LAB MANUAL

PRESS
RESET
GO 4100
NEXT or (Terminals)
To execute program instruction by instruction
PRESS
RESET
SI 4100
NEXT
To examine the contents of any register, the command must be terminated
by pressing .
Then press
SHIFT
REG to view register
Terminate to command again
To run the program, further press SHIFT and SI.
The program came back at the same address where we left.
Then press
NEXT
RESET
The program has gone back to monitor.

10
Dept. of EEE

T.K.M COLLEGE OF ENGINEERING

S-ar putea să vă placă și