#include#include#define DIAN P10;unsigned char djia=0x80,djian=0x80;void main()while(1)TMON=0x01;TL0=djian;TH0=djian;TR1=0;TR0=1;ET0=1;EA=1;DIAN=1;while(TF0=0);TMON=0x10;TL1=djia;TH1=djia;TR0=0;TR1=1;ET1=1;EA=1;DIAN=0;while(TF1=0);void T0IST() interrupt 1if(P12=0)if(P1.1=0)TL0=djian;TH0=djian;djian-;elseTL0=djian;TH0=djian;djian+;elseTL0=djian;TH0=djian;TR0=0;void T1IST() interrupt 3if(P12=0)if(P1.1=0)TL1=djia;TH1=djia;djia+;elseTL1=djia;TH1=djia;djia-;elseTL1=djia;TH1=djia;TR1=0;