0% found this document useful (0 votes)
4 views2 pages

Lab Task 1

The document outlines various assembly-level programming tasks for the 8085 microprocessor, including addition, subtraction, multiplication, and division of numbers stored in registers and memory locations. It also discusses efficient multiplication and division methods using algorithms based on repeated addition and subtraction. Flowcharts for multiplication and division algorithms are provided to illustrate the processes involved.

Uploaded by

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

Lab Task 1

The document outlines various assembly-level programming tasks for the 8085 microprocessor, including addition, subtraction, multiplication, and division of numbers stored in registers and memory locations. It also discusses efficient multiplication and division methods using algorithms based on repeated addition and subtraction. Flowcharts for multiplication and division algorithms are provided to illustrate the processes involved.

Uploaded by

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

G H PATEL COLLEGE OF ENGINEERING &

TECHNOLOGY,
Vallabh Vidyanagar
(A Constituent College of CVM University)

TASK -1
1 Write an assembly level program for 8085 to add the contents of memory
locations 2000, 2001 & 2002 and store result on memory locations 3000H & 3001.
(Higher byte first).
2 Compare the contents of B, C and D. Store the max on memory location 2000H.
3 Register B & C hold one 16-bit hexadecimal number same way register D & E hold
second hexadecimal number. Write an assembly level program for 8085 to add
them and store result into H & L
4 Subtraction of two 8-bit numbers.
5 Subtraction of two 16-bit numbers.
6 Multiplication of two 8- bit nos. using repeated Addition.
7 Division of two 8- bit nos. using repeated Subtraction.

M U L T IPL IC AT I O N

T H E R E A R E T W O W AY S T O M U L T I P L Y G I V E N N U M B ER :
- U SI NG A D D S H I FT M E T H O D
- U SI NG R EP E AT ED A D D I T I O N

WE AL L H A VE ST U D I ED A BO U T R EP E AT E D AD D I T I O N M ET H O D . I T I S I N EF FI CI E NT
T E CH NI Q U E FO R A L AR G E R M U L T I P L I E R . SO A M O R E EF FI CI E NT T E CH NI Q U E C A N B E
D E VI S ED BY FO L L O W I N G T H E M O D EL O F M A N U AL M U L T I P L I C AT I O N O F D E CI M AL
NU M B ER S .

F O R E X AM P L E : 108
X 15
S T EP -1 (108 X 5) = 540
S T EP -2 S H I FT L E FT A ND AD D (108 X 1) = + 1080
1620

IN T H I S EX AM P L E , T H E M U L T I P L I ER M U L T I P L I E S E A CH D I G I T O F T H E M U L T I P L I C A ND ,
ST AR T I N G FR O M T H E F AR T H EST R I G H T , A ND AD D S T H E P R O D U CT B Y S H I FT I NG T O T H E
L EFT . THE S AM E P R O C E SS C A N B E AP P L I E D I N BI N AR Y M U L T I P L I C AT I O N . THIS M ET H O D
I S K NO W N A S A D D S H I FT M ET H O D .

S AM E WAYS IN D I VI SI O N THERE IS R EP E AT E D S U BT R ACT I O N .


G H PATEL COLLEGE OF ENGINEERING &
TECHNOLOGY,
Vallabh Vidyanagar
(A Constituent College of CVM University)

FLOW CHART OF FEW TASK

For multiplication
ALGORITHM:

1. L O A D T H E N U M B E R W H I C H Y O U W A N T T O M U L T I P L Y I N R E G I S T E R B & C.
2. C O M P A R E C O N T E N T O F R E G I S T E R B A N D C. (I T I S O N L Y D O N E T O F I N D W H I C H N U M B E R I S
G R E A T E R ).
3. T H E L A R G E R N U M B E R I S T O B E A D D E D F O R O T H E R N U M B E R O F T I M E S .
4. S T O R E T H E H I G H E R B Y T E I N R E G I S T E R D A N D L O W E R B Y T E I N R E G I S T E R E.
5. E N D
For division
ALGORITHM:

1. L O A D T H E N U M B E R W H I C H Y O U W A N T T O M U L T I P L Y I N R E G I S T E R B & E.
2. C O M P A R E C O N T E N T O F R E G I S T E R B A N D E. (E > B M U S T I F N O T S W A P T H E C O N T E N T ).
3. T H E S M A L L E R N U M B E R I S T O B E S U B T R A C T E D F R O M L A R G E R N U M B E R U P T I L L L A R G E R N U M B E R
BECOMES SMALLER THAN SMALLER NUMBER .
4. S T O R E T H E R E M A I N D E R A T 300 1 H A N D Q U O T I E N T A T 300 2 H .
5. E N D

You might also like