Library containing Crazyflie 2.0 controller classes: - Attitude estimator - Horizontal estimator - Vertical estimator - Attitude controller - Horizontal controller - Vertical controller - Mixer
VerticalEstimator.h
00001 #ifndef VerticalEstimator_h 00002 #define VerticalEstimator_h 00003 00004 #include "mbed.h" 00005 #include "Parameters.h" 00006 #include "VL53L0X.h" 00007 00008 // Vertical estimator class 00009 class VerticalEstimator 00010 { 00011 public: 00012 // Class constructor 00013 VerticalEstimator(); 00014 // Initialize class 00015 void init(); 00016 // Predict vertical position and velocity from model 00017 void predict(); 00018 // Correct vertical position and velocity with measurement 00019 void correct(float phi, float theta); 00020 // Vertical position (m) and velocity (m/s) estimations 00021 float z, w; 00022 private: 00023 // Range sensor object 00024 VL53L0X range; 00025 // Last vertical position (m) measurement 00026 float z_m_last; 00027 }; 00028 00029 #endif
Generated on Wed Jul 13 2022 17:54:46 by 1.7.2