ORG 0000H AJMP MAIN ORG 000BH AJMP INTT0 ORG 0030H MAIN:MOV TMOD,#01H MOV TH0,#3CH MOV TL0,#0B0H MOV DPTR,#TAB SETB EA SETB ET0 SETB TR0 L2: MOV R7,#00H L1: MOV A,#0 MOV B,#10 DIV AB SETB P2.2 SETB P2.1 SETB P2.0 MOVC A,@A+DPTR MOV P0,A CLR P2.3 SETB P2.3 MOV A,B MOVC A,@A+DPTR MOV P0,A CLR P2.2 SETB P2.2 MOV A,#10 MOV B,#10 DIV AB MOVC A,@A+DPTR MOV P0,A CLR P2.1 SETB P2.1 MOV A,B MOVC A,@A+DPTR MOV P0,A CLR P2.0 SETB P2.0 CJNE R7,#14H,L1 LOOP1:MOV R6,#20H MOV R2,#00H MOV R4,#09H LOOP:MOV R3,#59 HERE:MOV A,R3 MOV B,#10 DIV AB SETB P2.2 SETB P2.1 SETB P2.0 MOVC A,@A+DPTR MOV P0,A CLR P2.3 SETB P2.3 MOV A,B MOVC A,@A+DPTR MOV P0,A CLR P2.2 SETB P2.2 MOV A,R4 MOV B,#10 DIV AB MOVC A,@A+DPTR MOV P0,A CLR P2.1 SETB P2.1 MOV A,B MOVC A,@A+DPTR MOV P0,A CLR P2.0 SETB P2.0 KAIGUAN:JB P2.6,L4 CLR TR0 L6: MOV A,R3 MOV B,#10 DIV AB SETB P2.2 SETB P2.1 SETB P2.0 MOVC A,@A+DPTR MOV P0,A CLR P2.3 SETB P2.3 MOV A,B MOVC A,@A+DPTR MOV P0,A CLR P2.2 SETB P2.2 MOV A,R4 MOV B,#10 DIV AB MOVC A,@A+DPTR MOV P0,A CLR P2.1 SETB P2.1 MOV A,B MOVC A,@A+DPTR MOV P0,A CLR P2.0 SETB P2.0 JB P2.7,L6 SETB TR0 AJMP L4 L4:CJNE R2,#14H,HERE DJNZ R6,$ MOV R2,#00H DEC R3 CJNE R3,#0FFH,HERE DEC R4 CJNE R4,#0FFH,LOOP AJMP L2 INTT0:MOV TH0,#3CH MOV TL0,#0B0H INC R2 INC R7 RETI TAB:DB 040H,079H,24H,030H,019H,12H,02H,78H,00H,10H END