You are on page 1of 2

16 BIT ADDITION. AIM: To write a program to add two 16 bit numbers by various addressing modes. Algorithm. 1.

Move the immediate numbers to AX register . 2. Add the content of AX with second immediate number. 3. Store the result in AX. 4. Move the result in AX to a memory location to view the output. Memory location Label opcode Mnemonics 2000 MOV AX, 0005H ADD AX, 0001H MOV[5000H],AX HLT comments I/P ADDITION OUTPUT

Memory location Label opcode Mnemonics 2000 MOV AX, 0005H MOV BX, 0100H ADD AX,BX MOV[5001H],AX HLT Memory location 2000 Label opcode Mnemonics MOV[5000H], 0005H MOV AX,0001H ADD AX[5000H] MOV[5002H],AX HLT

comments INPUT OUTPUT ADDITION OUTPUT

comments INPUT INPUT ADDITION OUTPUT

Memory location Label opcode Mnemonics 2000 MOV SI,2050H MOV AX,0005H ADD AX,[S1] MOV[5000H],AX HLT RESULT:

comments INDEX INPUT ADDITION OUTPUT

The 16-Bit addition using various address modes are performed and verified.