Micro processor Lab Manual / Find Largest Of 8 Numbers ALP

Program Name

Write a Assembly Language Program for Find Largest Of 8 Numbers .
Theory
Instruction Mnemonic Operand Comments
LXI H,8100 The instruction loads 16-bit data in the HL register pair
MVI C,07 Move immediately input data to register C
MOV A,M Move contents of memory and carry to accumulator
INX H Increment register pair by 1
CMP M The contents of memory are compared with accumulator
JNC XX Jump to memory address 800C if the carry flag is set to 0
MOV A,M Move contents of memory and carry to accumulator
DCR C The contents of register C are decremented by 1 and the result is stored in register C
JNZ YY Jump to memory address 8006 if the zero flag is 0
STA 8200 The contents of accumulator are copied into the memory address 8200
HLT The processor finishes executing the current instruction and halts any further execution.
Program Code


Online compiler for 8085 Microprocess Compiler


Home     Back