QQQ

Dependencies:   mbed-rtos mbed

Fork of BX-car_s by Tony Lin

Revision:
17:af867c7512bb
Parent:
16:b1e11b865d05
Child:
18:88b083db7491
--- a/main.cpp	Sat Jun 28 14:21:19 2014 +0000
+++ b/main.cpp	Sat Jun 28 18:59:41 2014 +0000
@@ -99,7 +99,7 @@
         last_brc=b_r_c;
         
         if(first_time==true){
-                r_kp=128;
+                r_kp=0;
                 first_time=false;
             }
         else{
@@ -110,7 +110,7 @@
                 r_kp*=-1.0;
                 r_kp_neg=true;
             }
-        kp=0.016/r_kp;
+        kp=0.016/(1280-r_kp);
         if(r_kp_neg==true){
                 r_kp_neg=false;
                 r_kp*=-1.0;