MC3()
MC3()
1. Prelab Exercise:
Assembly Instruction Instruction Description
Size
START: LXI H,2050H 3
LXID, 2070H 3
MVIB, 0AH 2
1
STAX D
INX H 1
INX D 1
1
DCR B
JNZ NEXT 3
HLT 1
19EAC 285: Microcontroller Lab
Lab Exercise1: Fill the table for the following assembly program by selecting suitable
instructions from the 8085 Instruction Set. Explain each instruction and finally say what the
program does.
Assembly Instruction Memory Object Code Flags or Register
Size Address in Hex Change details
1 4202 47 B = 12
MOV B,A
1 4208 0D C = 02;P = 0
DCR C
Program Explanation:
19EAC 285: Microcontroller Lab
Lab Exercise 2: Add five numbers stored in the consecutive locations in the memory and store
the result in 8200h using a loop for the conditional jump. Follow the template of the table shown
in Lab Exercise 1.
MVI C,05H
2 4203 0E 05 BC = 05
1 420A 23 HL=8201
INX H
DCR C 1 420B 0D C = 04
HLT 1 4212 76
Program Explanation:
19EAC 285: Microcontroller Lab
Lab Exercise 3: Write an assembly language program for the following using the 8085 simulator,
to multiply two 8-bit numbers stored at consecutive memory locations starting from 4500H and to
store the result in 4600H using conditional branching(Hint: Perform multiplication using repeated
addition). Follow the template of the table shown in Lab
Exercise 1.
1 4203 47 B = 02
MOV B,A
3 4204 3A 01 045 A = 04
LDA 4501H
3 4212 3A 02 045
LDA 4502H
1 4215 47 A = 02;Z = 1;P = 1
MOV B,A
HLT
Program Explanation:
19EAC 285: Microcontroller Lab
Evaluation:
Evaluation: