gpa in double prescision

Dependencies:   mbed

Revision:
10:b7f142952df9
Parent:
9:4e6f3404d473
Child:
21:c0d1a661f26e
--- a/main.cpp	Tue Mar 13 20:23:44 2018 +0000
+++ b/main.cpp	Tue Mar 20 19:50:04 2018 +0000
@@ -75,6 +75,8 @@
 IIR_filter FilterACCy(tau, Ts, 1.0f);                // 1st order LP for complementary filter acc_y
 IIR_filter FilterGYRZ(tau, Ts, tau);     // 1st order LP for complementary filter gyro
 
+/*
+// gpa measurement
 float fMin = 1.0f;
 float fMax = 1.0f/2.0f/Ts*0.9f;
 int NfexcDes = 100;
@@ -90,8 +92,9 @@
 short counts = 0;           
 float omega = 0.0f;
 float desCurrent = 0.0f;
+*/
 
-/* // simulation on nucleo
+// simulation on nucleo
 float Oexc = 1.0f;
 float fMin = 0.7f;
 float fMax = 1.0f/2.0f/Ts*0.72f;
@@ -107,8 +110,6 @@
 IIR_filter SysSecOrder(w0, D, Ts, 10.0f);
 float u = Oexc;
 float y = 10.0f*u;
-float exc = 0.0f;
-*/
 
 // IIR_filter FilterANG(1.0f/(2.0f*PI*fg), Ts, 1.0f);
 // IIR_filter FilterDiffANG(1.0f/(2.0f*PI*fg), Ts);
@@ -163,7 +164,7 @@
 
 void updateControllers(void)
 {
-    
+    /*
     counts = MotorEncoder;            // counts in 1
     omega = MotorDiff(counts);        // angular velocity motor
 
@@ -174,8 +175,8 @@
     }
     desCurrent = pi_w((n_soll + excWobble - omega)/0.217f);
     out.write(u3k3_TO_1V(i2u(desCurrent)));
+    */
     
-    /*
     u = Wobble(u, y) + Oexc;
     y = SysSecOrder(u);
     k += 1;
@@ -183,7 +184,6 @@
     if(k == 11000) {
         Wobble.printGPAmeasTime();
     }
-    */
     
     /*
     // read encoder data