MM Lab Manual 8085 Part1
MM Lab Manual 8085 Part1
MICROPROCESSOR &
MICROCONTROLLER LAB (KEC-552)
LAB MANUAL
ACADEMIC SESSION 2021-22
Mission
M1:To provide a supportive environment for effective knowledge transfer and nurturing ideas.
M2:To equip students with technical and leadership skills, and abilities to face the global
challenges.
M3:To create an environment conducive for research and development with continuous
involvement of industry.
1. Exhibit multi-disciplinary technical and leadership skills for better employability, higher
education and entrepreneurship.
2. Possess strong knowledge in the field of Electronics and Communication Engineering to
develop solutions for real life problems.
3. Undertake professional responsibilities through strong team-work, communication skills and
life-long learning.
4. Become socially responsible professionals with moral values and ethics.
1. Engineering knowledge: Apply the knowledge of mathematics, science, engineering fundamentals, and
an engineering specialization to the solution of complex engineering problems.
2. Problem analysis: Identify, formulate, review research literature, and analyze complex engineering
problems reaching substantiated conclusions using first principles of mathematics, natural sciences, and
engineering sciences.
3. Design/development of solutions: Design solutions for complex engineering problems and design
system components or processes that meet the specified needs with appropriate consideration for the
public health and safety, and the cultural, societal, and environmental considerations.
4. Conduct investigations of complex problems: Use research-based knowledge and research methods
including design of experiments, analysis and interpretation of data, and synthesis of the information to
provide valid conclusions.
5. Modern tool usage: Create, select, and apply appropriate techniques, resources, and modern
engineering and IT tools including prediction and modeling to complex engineering activities with an
understanding of the limitations.
6. The engineer and society: Apply reasoning informed by the contextual knowledge to assess societal,
health, safety, legal and cultural issues and the consequent responsibilities relevant to the professional
engineering practice.
7. Environment and sustainability: Understand the impact of the professional engineering solutions in
societal and environmental contexts, and demonstrate the knowledge of and need for sustainable
development.
8. Ethics: Apply ethical principles and commit to professional ethics and responsibilities and norms of the
engineering practice.
9. Individual and team work: Function effectively as an individual, and as a member or leader in diverse
teams, and in multidisciplinary settings.
10. Communication: Communicate effectively on complex engineering activities with the engineering
community and with society at large, such as, being able to comprehend and write effective reports and
design documentation, make effective presentations, and give and receive clear instructions.
12. Life-long learning: Recognize the need for, and have the preparation and ability to engage in
independent and life-long learning in the broadest context of technological change.
PSO1: Design embedded solutions for existing problems of society and industry.
PSO2: Design and test systems in the field of Communications Systems and Networks.
KEC552.2. Examine 8085 & 8086 microprocessor and its interfacing with peripheral devices.
KEC552.3. State various conversion techniques using 8085 & 8086 and generate waveforms
using 8085.
CO – PO Mapping
PO1 PO2 PO3 PO4 PO5 PO6 PO7 PO8 PO9 PO10 PO11 PO12 PSO1 PSO2
KEC 553.1
1 2 2 - 3 - - 1 2 1 - 1 2 -
KEC 553.2
3 3 3 1 3 - - - 2 1 - 1 2 -
KEC 553.3
3 2 2 - 3 - - - 2 1 - 1 2 -
KEC 553.4
3 3 2 1 3 - - - 2 1 - 1 2 -
KEC 553.5
3 3 3 2 3 2 2 1 3 1 2 1 2 -
Note: In addition, institutes may include two more experiments based on the expertise.
15. To convert two BCD numbers in memory to the equivalent HEX number and vice versa
using 8085.
To find the largest and smallest number in an array of data using 8085
4 C01
instruction set.
To write a program using 8086 to arrange an array of data in ascending
5 CO2
and descending order.
To convert given Hexadecimal number into its equivalent ASCII
6 number and vice versa using 8086 instruction set. CO2
13 Write a program to show the use of INT0 and INT1 of 8051. CO4
Write a program for temperature & to display on intelligent LCD
14 CO5
display.
8085 MICROPROCESSOR
Internal Architecture
a) General purpose register
It is an 8 bit register i.e. B, C, D, E, H, I... The combination of an 8 bit registers
pair, which can hold 16 bit data. The HL pair is used to act as memory pointer is
accessible to program.
b) Accumulator
It is an 8 bit register which hold one of the data to be processed by ALU and stored
the result of the operation
d) Stack pointer ( SP )
It is a 16 bit special purpose register which is used to hold line memory address
for line next instruction to be execution.
f) Temporary register
It is an 8 bit register associated with ALU hold data, entering an operation,
used by the microprocessor and not accessible to programs.
g) Flags
Flag register is a group of fire, individual flip flop line content of line flag
register will change after execution of arithmetic and logic operation. The line stages
flags are
i. Carry flag (C)
ii. Parity flag (P)
iii. Zero flag(Z)
iv. Auxiliary carry flag(AC)
v. Sign flag(S)
1. The signal goes high during the first clock cycle and
Enables the lower address bits.
IO / M
S0 – S1
S0 and S1 are status signal which provides different status and Functions.
RD
WR
HOLD
1. This indicates if any other device is requesting the use of address and data bus.
HLDA
INTR
INTA
TRAP
RESET IN
1. This pin resets the program counter to 0 to 1 and result interrupts enabled and HLDA flip
flops.
X1, X2
These are the terminals which are connected to external oscillator to produce the
necessary and suitable clock operation.
SID
SOD
APPARATUS REQUIRED:
ALGORITHM:-
HEXADECIMAL ADDITION : Write a program to takes the content of 200A, adds it to 200B &
stores the result back at 200C.
Steps: 1. Initialize HL Reg. pair with address where the first number is lying.
5. Go back to Monitor
Let: (200A H) = 80 H
(200B H) = 15 H
Result = 80 H + 15 H = 95 H
(200A H) A
A B
(200B H) A
A + B A
A (200C H)
END
PROGRAM:-
2008 RST 5
2 nd METHOD:-
MICROPROCESSORS & MICROCONTROLLER LAB (KEC-552), ECE Dept., Page 15
Memory Label Mnemonics Remarks
location
20OB RST 5
CONCLUSION:-
PRECAUTION:-
1.verify the hex code before executing in program
2. Memory location varies as per kit
APPARATUS REQUIRED:
ALGORITHM:-
HEXADECIMAL SUBTRACTION : The program takes the content of 2009, subtracts it to 200A &
stores the result back at 200B.
STEPS:-
1. Initialize HL Reg. pair with address where the first number is lying.
2. Store the number in accumulator.
3. Get the second number.
4. Subtract second no from acc and store the result in 200B.
5. Go back to Monitor
FLOWCHART:-
Start
END
PROGRAM:-
2008 RST 5
CONCLUSION:-
PRECAUTION:-
1.verify the hex code before executing in program
available.
Q4.What are the contents of all flags after execution of program for addition.
S. No.
Name of Specification/ Range/ Quantity
Equipment/Compnents/Software Rating
1. 8085 Microprocessor SCIENTECH-8085 01
programming kit, instruction
coding sheet.
2. Power supply A.C (230V Mains)
ALGORITHM:-DECIMAL ADDITION:
Steps: 1. Initialize HL Reg. pair with address where the first number is lying.
5. Go back to Monitor
FLOWCHART: Start
END
RST 5
Input at 3001= 32
output at 3002= 86
CONCLUSION:-
S. No.
Name of Specification/ Range/ Quantity
Equipment/Compnents/Software Rating
1. 8085 Microprocessor SCIENTECH-8085 01
programming kit, instruction
coding sheet.
2. Power supply A.C (230V Mains)
ALGORITHM:-DECIMAL SUBTRACTION :
STEPS:-
1. Initialize HL Reg. pair with address where the first number is lying.
2. Store the number in accumulator.
3. Get the second number.
4. Subtract second no from acc and store the result in 200B.
5. Adjust the decimal
6. Go back to Monitor
FLOWCHART:- Start
end
RST 5
Input at 3001= 10
onput at 3002= 52
CONCLUSION:-
PRECAUTION:-
1.verify the hex code before executing in program
Viva Questions:
Q.1.Write a small program to enter animmediate data to accumulator and move it to all registers.
Q2. Why DAA instruction is to be written just after ADD&SUB instruction.
Q3.In above program why MOV A,M instruction is used if direct instruction LDA, address is
available.
Q4.What are the contents of all flags after execution of program for addition.
AIM: Write a program to perform multiplication of two 8 bit numbers using bit addition method.
APPARATUS REQUIRED:
ALGORITHM:-
*Assume number to be multiplied is stored at location 2150H and 2151H and result is at
location 2152 AND 2153.
1) Start the program by loading HL register pair with address of memory location.
7) Check whether repeated addition is over and store the value of product and carry
in memory location.
Start
Is carry
Increment D register
Is zero
END
CONCLUSION:-
PRECAUTION:-
AIM: Write a program to perform division of two 8 bit numbers using Repeated Subtraction
method. `
APPARATUS REQUIRED:
ALGORITHM:-
Assume number to be multiplied is stored at location 2150H and 2151H and result is at
location 2152 AND 2153.
1) Start the program by loading HL register pair with address of memory location.
7) Check whether repeated subtraction is over and store the value of product and
LXI H, 2150
INX H ;
MOV A, C ;
PRECAUTION:-
Viva Questions:
Q.1 The contents of register (B) and accumulator (A) of 8085 microprocessor are 49H & 39H
respectively. What are the contents of A and the status of carry flag (CY) and sign flag (S) after
exceeding SUB B instructions.
Q.2 Why did you use HLT at the end of the program?
Q.3 What is difference between call and jump.
ALGORITHM:-
2003 MVI C, 0F
2005 MVI A, 00
2008 CMP B
200C MOV A, B
200E DCR C
JNZ: UPP1
STA 9210
HLT
Input at 3001= 0A H
Input at 3002= 1F H
Input at 3003= 26 H
Input at 3004= FE H
Input at 3005= F1 H
output at 3100= FE H
PRECAUTION:-
1.verify the hex code before executing in program
2.Take memory locations according model of kit.
ALGORITHM:-
2003 MVI C, 0F
2005 MVI A, 00
2008 CMP B
200C MOV A, B
200E DCR C
JNZ: UPP1
STA 9210
HLT
Input at 3001= 00 H
Input at 3002= 1F H
Input at 3003= 26 H
Input at 3004= FE H
Input at 3005= F1 H
PRECAUTION:-
Viva Questions:-
6015H ADDH
2. Suppose HL=ABCD, stack painter = 1234, what happens after SPHL is executed.