源程序如下,startup.a51没动,直接将下程序加入project(只有startup.a51和该程序),结果总是编译不过,提示P1,R1没有定义,插入51头文件,又报冲突,编译环境为keilc51 uV3.23
ORG 0000H LJMP BEGIN BEGIN: MOV R3,#64H DELAY: MOV P1,#F0H ACALL MS100 MOV P1,#E0H DJNZ R3,DELAY /*100ms LOOP*/
MS100: MOV R2, #64H MS1: MOV R0,#04H LOOP: MOV R1, #FAH SELF: DJNZ R1, SELF DJNZ R0,LOOP DJNZ R2, MS1 RET END /* 1ms LOOP END */ |