0% found this document useful (0 votes)
44 views4 pages

MPMC Outpu1

Uploaded by

jay
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
0% found this document useful (0 votes)
44 views4 pages

MPMC Outpu1

Uploaded by

jay
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
ORG OH MOV RO,#80H MOV R1,#90H MOV R2,#10d EXCHANGE_LOOP: MOV A,@RO MOV @R1,A INC RO INC RI DINZ R2, EXCHANGE_LOOP RET [= Bd mt! ra * Sektenan oy ah cre, aaa a eh moran orf aoc 3 vez pei = Fegeee Nie Fa a co a a 4 3 # a 2 Se ES°SESSEE EEEEES noe Tome | _ 7 Spa Tite ei Te [ea i ef 9 Sent oe f ' a] FH ela wm stm oe tle 3a a | al " i i ‘ Tat tow : tats wna Sas ORG 00H MOV RO, #40H MOV R1,#10 MOV B,#00H AGAIN: MOV A,@RO CJNE A,B, Next AJMP SKIP Next: JC SKIP MOV B,A SKIP: INC RO DJNZ R1,AGAIN MOV P1,B END ORG 00H MOV RO, #40H are stored MOV RI, #0AH MOV B, #0ffH jmaximum=0 AGAIN: MoV A, @RO #get the number from memory CINE A,B,Next ;compare number wi maximum number AUMP SKIP 7if equal go to SKIP Next: INC SKIP jif not equal check for carry, if carry go to skip MOV B,A jotherwise maximum=[[R0] SKIP: INC RO #Increment memory pointer DINZ R1,AGAIN ;Decrement count, if count=0 stop otherwise go to AGAIN MOV P1,B =ND A Sa nese hese

You might also like