Yuri De Stefani / CrazyflieController_final
Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers VerticalEstimator.h Source File

VerticalEstimator.h

00001 #ifndef VerticalEstimator_h
00002 #define VerticalEstimator_h
00003 
00004 #include "mbed.h"
00005 #include "Library.h"
00006 #include "VL53L0X.h"
00007 
00008 
00009 // Vertical estimator class
00010 class VerticalEstimator
00011 {
00012 public :
00013 //Class constructor
00014     VerticalEstimator () ;
00015 // Initialize class
00016     void init () ;
00017 // Predict vertical position and velocity from model
00018     void predict () ;
00019 // Correct vertical position and velocity with measurement
00020     void correct (float phi, float theta);
00021 // Vertical position (m) and velocity (m/s) estimation
00022     float w_est, z_est;
00023 
00024 private :
00025 // Range sensor object
00026     VL53L0X range ;
00027 // Last vertical position (m) measurement
00028     float z, w, zml, wm, zm;
00029 };
00030 
00031 # endif