在用keil汇编程序的时候老是提示有未定义的符号,就通不过,程序见下面:
程序见下面:MOVP0,#00HCLRP1.0SETBP1.1MOVR0,#50HMOVDPTR,#TABLOOP:MOV@R0,#0MOVA,@R0MOVCA,@A+D...
程序见下面:
MOV P0,#00H
CLR P1.0
SETB P1.1
MOV R0,#50H
MOV DPTR,#TAB
LOOP: MOV @R0,#0
MOV A,@R0
MOVC A,@A+DPTR
MOV P0,A
NEXT: LCALL DELAY
LCALL REFRESH
CJNE @R0,#9,NEXT
LCALL DELAY
SJMP LOOP
END
DELAY: MOV R7,#10
MOV R6,#250
LOOP1: NOP
NOP
DJNZ R6,LOOP1
DJNZ R7,LOOP1
RET
REFRESH:INC @RO
MOV A,@R0
MOVC A,@A+DPTR
MOV P0,A
RET
TAB: DB 0C0H,0F9H,0A4H,0B0H,99H
DB 92H,82H,0F8H,80H,90H
一共有四个错误,分别是,TAB,REFRESH,DELAY,LOOP,未定义
到底是怎么回事?明明定义了的啊 展开
MOV P0,#00H
CLR P1.0
SETB P1.1
MOV R0,#50H
MOV DPTR,#TAB
LOOP: MOV @R0,#0
MOV A,@R0
MOVC A,@A+DPTR
MOV P0,A
NEXT: LCALL DELAY
LCALL REFRESH
CJNE @R0,#9,NEXT
LCALL DELAY
SJMP LOOP
END
DELAY: MOV R7,#10
MOV R6,#250
LOOP1: NOP
NOP
DJNZ R6,LOOP1
DJNZ R7,LOOP1
RET
REFRESH:INC @RO
MOV A,@R0
MOVC A,@A+DPTR
MOV P0,A
RET
TAB: DB 0C0H,0F9H,0A4H,0B0H,99H
DB 92H,82H,0F8H,80H,90H
一共有四个错误,分别是,TAB,REFRESH,DELAY,LOOP,未定义
到底是怎么回事?明明定义了的啊 展开
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询