汇编时出现重复定义
ORG0000HSTART:MOVP0,#00HJBP1.0,$LCALLFILTERJNBP1.0,$MOVR0,#00HPRESS_1:MOVA,R0MOVP0,AM...
ORG 0000H
START:
MOV P0,#00H
JB P1.0,$
LCALL FILTER
JNB P1.0,$
MOV R0,#00H
PRESS_1: MOV A,R0
MOV P0,A
MOV R5,#10
ADD_1: MOV R6,#200
LCALL DELAY
DJNZ R5,ADD_1
MOV A,R0
ADD A,#01H
DA A
MOV R0,A
JMP PRESS_1
PRESS_2: LCALL FILTER
JB P1.0,PRESS_3
JMP PRESS_2
PRESS_3: JB P1.0,$
LCALL FILTER
RELEASE: JB P1.0,START
JMP RELEASE
DELAY: MOV R7,#248
JNB P1.0,PRESS_2
DJNZ R7,$
DJNZ R6,DELAY
RET
FILTER: MOV R6,#60
F1: MOV R7,#248
DJNZ R7,$
DJNZ R6,F1
RET
END
这是一个秒表,编译时老出现重复定义,请高手指点???? 展开
START:
MOV P0,#00H
JB P1.0,$
LCALL FILTER
JNB P1.0,$
MOV R0,#00H
PRESS_1: MOV A,R0
MOV P0,A
MOV R5,#10
ADD_1: MOV R6,#200
LCALL DELAY
DJNZ R5,ADD_1
MOV A,R0
ADD A,#01H
DA A
MOV R0,A
JMP PRESS_1
PRESS_2: LCALL FILTER
JB P1.0,PRESS_3
JMP PRESS_2
PRESS_3: JB P1.0,$
LCALL FILTER
RELEASE: JB P1.0,START
JMP RELEASE
DELAY: MOV R7,#248
JNB P1.0,PRESS_2
DJNZ R7,$
DJNZ R6,DELAY
RET
FILTER: MOV R6,#60
F1: MOV R7,#248
DJNZ R7,$
DJNZ R6,F1
RET
END
这是一个秒表,编译时老出现重复定义,请高手指点???? 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询