Microprocessor
Microprocessor
ALGORITHM:-
a) Addition:-
(i) Start the process
(ii) Initialize the count value
(iii) Get the two data.
(iv) Add the two data values
(v) If carry exists increment the count value.
(vi) Store the result.
(vii) Stop the process.
PROGRAM
OUTPUT
16 – BIT ADDITION
Address Output
1100 2B
1101 20
1102 00
1
16 BIT ADDITION
Start
If No
Carry
Yes
Stop
2
1 B) 16 BIT SUBTRACTION
ALGORITHM:-
PROGRAM
16 – BIT SUBTRACTION
3
FLOWCHART:-
Subtraction:-
Start
If No
Carry
exists
Yes
Stop
4
1.C) 16 BIT MULTIPLICATION
ALGORITHM:-
(i) Start the process
(ii) Get the two values
(iii) Multiply the two values.
(iv) Store the result and overflow
(v) Stop the process.
PROGRAM
INPUT OUTPUT
5
FLOW CHART:-
Multiplication:-
Start
Stop
6
D) 16 BIT DIVISION
AIM:
To perform division of a 32 bit number by a 16 bit number and store the quotient and
remainder in memory
ALGORITHM:-
(i) Start the process
(ii) Get the two values
(iii) Initialize „DX‟ register as zero
(iv) Divide the values
(v) Store the quotient and remainder
(vi) Stop the process.
FLOWCHART:
7
D) 16 BIT DIVISION
PROGRAM
16 – BIT DIVISIION
RESULT:-
Thus the assembly language program for 16 Bit Arithmetic and Logical operations has been done
and verified.