This site is developed to help engineering students. The site is new. Right now, we have only microprocessor programs in here. We will keep including more topics on more subjects in the future.
Microprocessor 8085 Programs

Monday, June 24, 2013

Find The Larger Number Between Two Numbers Stored In Memory

Program: Find the larger between two numbers stored in memory.

Note:  Program starts from 8000H.
          Assuming the two numbers are stored at 9000H and 9001H.
          To store the larger number at 9002H.

Label
Memory Location
Mnemonics
Opcode
Operand



8000
LDA 9000H
3A
OO

9O

8003
MOV B, A
47




8004
LDA 9001H
3A
O1

9O

8007
CMPB
B8




8008
JNC SKIP
D2
OC

8O

800B
MOV A,B
78



 SKIP:
800C
STA 9002
32
O2

90 
800F
HLT
76


No comments:

Post a Comment