Library containing Crazyflie 2.0 controller classes: - Attitude estimator - Horizontal estimator - Vertical estimator - Attitude controller - Horizontal controller - Vertical controller - Mixer

Revision:
21:169cc2b1d2ff
Parent:
17:f682b4a5686d
--- a/HorizontalController/HorizontalController.h	Thu Oct 18 13:38:10 2018 +0000
+++ b/HorizontalController/HorizontalController.h	Wed Oct 24 14:24:56 2018 +0000
@@ -4,20 +4,19 @@
 #include "mbed.h"
 #include "Parameters.h"
 
+// Horizontal controller class
 class HorizontalController
 {
   public:
     // Class constructor
     HorizontalController();
-    // Control reference roll and pitch angles (rad) given reference horizontal velocities (m/s) and current horizontal velocities (m/s)
-    void control(float u_r, float v_r, float u, float v);
-    // Control roll and pitch references (rad) given reference horizontal velocities (m/s) and current horizontal velocities (m/s) on take-off
-    void control_take_off(float u_r, float v_r, float u, float v);
-    // Roll and pitch references (rad)
+    // Control reference roll and pitch angles (rad) given reference horizontal positions (m) and current horizontal positions (m) and velocities (m/s)
+    void control(float x_r, float y_r, float x, float y, float u, float v);
+    // Reference roll and pitch angles (rad)
     float phi_r, theta_r;
   private:
-    // Control reference angle (rad) given reference horizontal velocity (m/s) and current horizontal velocity (m/s) with given time constant (s)
-    float control_single(float velocity_r, float velocity, float T_velocity);  
+    // Control acceleration given reference position (m) and current position (m) and velocity (m/s) with given controller gains
+    float control_state_regulator(float position_r, float position, float velocity, float kp, float kd);  
 };
 
 #endif
\ No newline at end of file