Micro processor Lab Manual / Count Negative Numbers in Five 8 Bit Numbers list ALP

Program Name

Write a Assembly Language Program for Count Negative Numbers in Five 8 Bit Numbers list .
Theory
Instruction Mnemonic Operand Comments
MVI C,O5H Move immediately the value of register C to Accumulator
LXI H,8100 Instruction load 16-bit data to the register pair HL
MVI B,00 Move immediately the value of register B to Accumulator
MOV A,M Move the contents of Memory to Accumulator
RAL Rotate Accumulator to left carry
JNC XX Jump to 800D if the carry flag is not set
INR B Increment the value of register B to 10’s complement
INX H Increment the contents of HL pair to fetch next output
DCR C Decrement the contents of register B by 1
JNZ YY Jump to 8007 when not zero
MOV A,B Move the contents of register B to accumulator
STA 8200 Store the output in address 8200
HLT Stop
Program Code


Online compiler for 8085 Microprocess Compiler


Home     Back