Assembly language program for addition of two 16-bit numbers in 8086
Answers
Answered by
1
Sorry......... I.......... Dont.............. Know
Answered by
0
Problem - Write a program to add two 16-bit numbers where starting address is 2000 and the numbers are at 3000 and 3002 memory address and store result into 3004 and 3006 memory address.
Algorithm-
1. Load 0000H into CX register (for carry).
2. Load the data into AX (accumulator) from memory 3000.
3. Load the data into BX register from memory 3002.
4. Add BX with Accumulator AX
5. Jump if no carry.
6. Increment CX by 1.
7. Move data from AX (accumulator) to memory 3004.
8. Move data from CX register to memory 3006.
9. Stop.
Note:- Myself is not a hardware engineer. So I does not knew much more about hardware.
Algorithm-
1. Load 0000H into CX register (for carry).
2. Load the data into AX (accumulator) from memory 3000.
3. Load the data into BX register from memory 3002.
4. Add BX with Accumulator AX
5. Jump if no carry.
6. Increment CX by 1.
7. Move data from AX (accumulator) to memory 3004.
8. Move data from CX register to memory 3006.
9. Stop.
Note:- Myself is not a hardware engineer. So I does not knew much more about hardware.
Similar questions