刚刚用KEIL编写了流水灯,请问我编写的流水灯程序那里出了问题,为何程序运行到P0.3就不运行了,低电平发光管亮,谢谢!
程序如下:
ORG 0000H
LJMP MAIN
ORG 0030H
MAIN:MOV 54H,#3
MOV A,#07FH
S:MOV P0,A
LCALL DELAY
RR A
RR A
DJNZ 54H, S
SJMP $
ORG 0100H
DELAY:MOV R0,#10
L:MOV R1,#0FFH
M:MOV R2,#0FAH
DJNZ R2,$
DJNZ R1,M
DJNZ R0,L
RET
END |