www.pudn.com > colck.rar > SSS3.ASM, change:2005-12-23,size:1765b


       AJMP MAIN 
     	  
       ORG 03H                       
	 MOV P3,#0FFH 
	 AJMP AJ2 
       RETI 
	  
       ORG 13H                       
	 MOV P3,#0FFH 
	 AJMP AJ1 
       RETI 
 
       ORG 1BH 
       MOV TH1,#0ECH 
       MOV TL1,#78H 
       DJNZ R6,BACK 
       MOV R6,#200 
       
AJ:    MOV R0,#35H                      ;  
       INC @R0 
       CJNE @R0,#10,$+3 
       JC BACK 
       MOV @R0,#0 
       MOV R0,#34H 
       INC @R0 
       CJNE @R0,#6,$+3 
       JC BACK 
       MOV @R0,#0 
        
 
AJ1:   MOV R0,#33H                       ; 
       INC @R0 
       CJNE @R0,#10,$+3 
       JC BACK 
       MOV @R0,#0 
       MOV R0,#32H 
       INC @R0 
       CJNE @R0,#6,$+3 
       JC BACK 
       MOV @R0,#0 
        
        
AJ2:   MOV R0,#31H                          ;ʱ 
       INC @R0 
       CJNE @R0,#4,$+3 
       JC BACK 
       CJNE @R0,#5,$+3     
       JC S24              
       CJNE @R0,#10,$+3 
       JC BACK 
       MOV @R0,#0 
       MOV R0,#30H 
       INC @R0 
BACK:  RETI 
S24:   DEC R0 
       CJNE @R0,#2,$+3 
       JC BACK 
       MOV @R0,#0              
       MOV 31H,#0 
       RETI 
 
MAIN:  MOV R1,#30H 
       MOV @R1,#0 
	 INC R1 
       CJNE R1,#36H,MAIN+2 
	 MOV P3,#0FFH 
       MOV P0,#0 
 
       MOV DPTR,#SEGPT 
       MOV R6,#200 
       MOV TMOD,#10H 
       MOV TH1,#0ECH 
       MOV TH1,#78H 
       SETB IT0 
	 SETB IT1 
     	 MOV IP,#15H 
       MOV IE,#9FH 
       SETB TR1 
LOOPO: MOV R1,#30H 
       MOV R7,#20H 
LOOPI: MOV P2,#0 
       MOV A,@R1 
       MOVC A,@A+DPTR 
       MOV P1,A     
       MOV P2,R7 
       INC R1 
       MOV A,R7 
       RR A 
       MOV R7,A 
       CJNE R7,#80H,LOOPI 
       SJMP LOOPO 
SEGPT: DB 40H,79H,24H,30H,19H,12H,2,78H,0,18H 
       END