Micro processor Lab Manual / Add contents of two memory locations ALP

Program Name

Write a Assembly Language Program for Add contents of two memory locations.
Theory
Instruction Mnemonic Operand Comments
LXI H,8100 Load the contents of 8100 in H-L pair registers
LXI D,8200 Load the contents of 8200 in DE
MVI C,04 Store size of list in register C
LDAX D Load contents of register D to Accumulator
ADD M Add contents of memory i.e., HL to Accumulator and store in accumulator
MOV M,A Move contents of accumulator to memory i.e., HL pair
INX H Increment HL pair by 1(8100 to 8101)
INX D Increment DE by 1
(8200 to 8201)
DCR C Decrement counter by 1
(size of list reduced by 1)
JNZ BK Jump if not zero(i.e., content of reg. C) to load content of D to accumulator
HLT Stop
Program Code


Online compiler for 8085 Microprocess Compiler


Home     Back