test4

Dependencies:   mbed BufferedSerial LS7366LIB2 FastPWM

Revision:
4:bf278ddb8504
Parent:
0:7cff999a7f5c
--- a/encoder.h	Tue Jul 28 01:42:16 2020 +0000
+++ b/encoder.h	Tue Dec 08 01:25:06 2020 +0000
@@ -55,37 +55,16 @@
 */
 void reset_check()
 {
-    if(encoder_data[0]==-1 && encoder_data[1]==-1 && encoder_data[2]==-1 && encoder_data[3]==-1 && encoder_data[4]==1 && encoder_data[5]==1)
-    {
-        motor_onoff[0]=false;
-        motor_onoff[1]=false;
-        motor_onoff[2]=false;
-        motor_onoff[3]=false;
-        motor_onoff[4]=false;
-        motor_onoff[5]=false;
+}
 
-        while(1)
-        {
-            
-        pwm1.write(0.4);
-        pwm2.write(0.4);
-        pwm3.write(0.4);
-        pwm4.write(0.4);
-        pwm5.write(0.4);
-        pwm6.write(0.4);
-        
-        wait_ms(50);
-        
+/*
             encoder_data[0] = encoder1.read();
             if(encoder_data[0]!=-1)
             {
                 NVIC_SystemReset();
             }
-                wait_ms(200);
-        }
+*/
         
-    } 
-}
 
 void encoder_reset_cnt()
 {