1 D Division

You might also like

Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 2

1.C.

MULTIPLICATION
AIM:
To write an ALP for Division of two 16 bit data and execute the program using 8086
microprocessor.

EQUIPMENTS REQUIRED:
1. 8086 microprocessor kit
2. Keyboard
3. Connecting probes

Algorithm:
1. Copy the 16 bit Dividend data to the AX register.
2. Copy the 8 bit divisor data to the BL register.
3. Initialize the DX register to store the remainder value.
4. Divide the content of AX by the BX. The Quotient is stored in AX and the remainder is
stored in DX register.
5. Store the Content of AX, DX in the specified memory location.
6. Stop the program.

MULTIPLICATION

MEMOR
Y HEXCODE LABEL MNEMONICS COMMENTS
ADDRESS
Copy the first immediate operand
MOV AX,1111H (dividend-16 bit)to the AX register
AX←2222
Copy the second immediate
MOV BL,02H operand(divisor- 8 bit) to the Bl register
BL←02
Initialize the DX=0000 Register to store the
MOV DX,0000H
remainder value
(DX) (AX)←AX ÷ BX, divide the content of
DIV BL AX by BX and the result is stored in
AX(quotient)and DX(remainder)
The quotient which is in AX register stored
MOV [9000],AX
in the specified memory location 9000
The remainder which is in DX stored in the
MOV [9002],DX
specified memory location 9002
HLT Stop the execution of Program
FLOW CHART:
Start

Get the dividend data in AX

Get the divisor data in BL

Initialize Data register DX

Divide the content of AX by BL

Store the content of AX and DX in memory

Stop

INPUT OUTPUT
MEMORY MEMORY
DATA DATA
ADDRESS ADDRESS
8001 22H(AL) 9000 11H(AL)
8002 22H(AH) 9001 11H(AH)
8004 02H(BL) 9002 00H(DL)
9003 00H(DH)

RESULT:
Thus the ALP program for division of 16 bit data by 8 bit data was executed
successfully and the output was verified.

You might also like