0% found this document useful (0 votes)
8 views12 pages

LabReport MPI 12112043

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views12 pages

LabReport MPI 12112043

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 12

Microprocessor and Interfacing Lab

(ITC-508)

Lab Report

Submitted To: Submitted By:


Dr. Rajiv Verma
(Assistant Professor) Roll No.:
IIIT Sonepat Branch: IT
Semester: V
Session: 2021-25
INDEX

S.No. List of Experiment Date Sign


1 Addition of two 8-bit numbers
2 Subtraction of two 8-bit numbers
3 Addition of two 8-bit numbers with
carry
4 Subtraction of two 8-bit numbers with
borrow
5 Addition of two BCD Numbers
6 Subtraction of two BCD Numbers
7 The Multiplication two 8-bit numbers
by repeated addition method
8 The Multiplication two 8-bit numbers
by bit rotation method
9 The Division two 8-bit numbers by
repeated subtraction method
10 The Division two 8-bit numbers by bit
rotation method
Experiment-1 : The Addition of two 8-bit numbers

Code:
MVI A,30H
MVI B,52H
ADD B
HLT

Output:
Experiment-2 : The Subtraction of two 8-bit numbers

Code:

MVI A,30H
MVI B,52H
SUB B
HLT

Output:
Experiment-3: Addition of two 8-bit numbers with carry

Code:

MVI A,30H
MVI B,52H
ADC B
HLT

Output:
Experiment-4: Subtraction of two 8-bit numbers with borrow

Code:
MVI A, 40H
MVI B, 20H
SBB B
HLT

Output:
Experiment-5 : The Addition of two BCD numbers

Code:

LXI H, 2000h
MOV A, M
INX H
ADD M
DAA
INX H
MOV M, A
HLT

Output:
Experiment-6: The Subtraction of two BCD numbers

Code:

LXI H, 2000h
MOV A, M
INX H
SUB M
DAA
INX H
MOV M, A
HLT

Output:
Experiment-7: The Multiplication two 8-bit numbers by repeated
addition method.
Code:
MVI A, 00H
MVI B, 07H
MVI C, 06H
START:ADD B
DCR C
JNZ START
HLT

Output:
Experiment-8: The Multiplication two 8-bit numbers by bit Rotation
method.
Code:
MVI A,22H
MVI D,03H
MVI C,08H
LXI H,0000H
LOOP:RRC
JNC SKIP
DAD D
SKIP:XCHG
DAD H
XCHG
DCR C
JNZ LOOP
HLT
Output:
Experiment-9: The Division of two 8-bit numbers by Repeated
Addition method.
Code:
MVI A,25H
MOV E,A
MVI B,03H
MVI C,00H
LOOP: INR C
MOV A,E
SUB B
MOV E,A
SUB B
JP LOOP
HLT

Output:
Experiment-10: The Division of two 8-bit numbers by bit rotation
method.
Code:
MVI E, 00H
LHLD 2000H
LDA 2010H
MOV B , A
MVI C , 08H
NEXT: DAD H
MOV A , E
RLC
MOV E , A
MOV A , H
SUB B
JC SKIP
MOV H , A
INR E
SKIP: DCR C
JNZ NEXT
MOV A , E
STA 2020H
MOV A , H
STA 2030H
HLT

Output:

You might also like