电路如图
程序如下(求大神指点)
ORG 0000H
LJMP MAIN
ORG 0100H
MAIN: MOV TMOD,#01H
MOV TH0,#3CH
MOV TL0,#0B0H
SETB TR0
SETB P0.0
CLR P0.1
MOV R3,#00
LOOP: JNB TF0,LOOP
MOV TH0,#3CH
MOV TL0,#0B0H
INC R3
CLR TF0
CJNE R3,#20,LOOP
MOV R3,#00
CPL P0.0
CPL P0.1
AJMP LOOP
END
|