关于电机正反转的单片机实用程序 #include #include sbit p10=P1^0; sbit p11=P1^1; sbit p12=P1^2; #define UP 20 #define DOWN 30 #define STOP 40 void delay()//延时程序 { unsigned i,j,k; for(i=0;i