Minor BioRobotics BMT Hierbij publish ik mijn code public ter inspiratie voor komende jaarlagen. Het gaat om een serial robot met twee links en een haak als end-effector. Veel plezier ermee!

Dependencies:   mbed QEI HIDScope biquadFilter MODSERIAL FastPWM

Revision:
21:0d86a17f9974
Parent:
20:682ac5b520a0
Child:
22:239075a92d33
--- a/main.cpp	Wed Oct 30 18:36:52 2019 +0000
+++ b/main.cpp	Wed Oct 30 22:43:24 2019 +0000
@@ -314,22 +314,20 @@
     void motor1_controller(void)
     {
         error1_motor1 = (Yref_motor1 - positie_motor1);
-        motor1_pwm();
-        /*if (motor1_calibrated==true&&motor2_calibrated==true)
+        if (motor1_calibrated==true&&motor2_calibrated==true)
             {
                 motor1_pwm();
-            } */
+            } 
         
     }
 
     void motor2_controller(void)
     {
         error1_motor2 = (Yref_motor2 - positie_motor2);
-        motor2_pwm();
-        /* if (motor1_calibrated==true&&motor2_calibrated==true)
+        if (motor1_calibrated==true&&motor2_calibrated==true)
             {
                 motor2_pwm();
-            } */
+            } 
     }   
     
 void emg0_processing()