Paparazzi UAS  v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
wind_estimator.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2016 Johan Maurin, Gautier Hattenberger
3  *
4  * This file is part of paparazzi.
5  *
6  * paparazzi is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2, or (at your option)
9  * any later version.
10  *
11  * paparazzi is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with paparazzi; see the file COPYING. If not, see
18  * <http://www.gnu.org/licenses/>.
19  */
20 
29 #ifndef WIND_ESTIMATOR_H
30 #define WIND_ESTIMATOR_H
31 
32 #include "std.h"
34 
35 struct WindEstimator {
36  struct FloatVect3 airspeed;
37  struct FloatVect3 wind;
39  bool reset;
40 
41  // filter parameters
42  float r_gs;
43  float r_va;
44  float r_aoa;
45  float r_ssa;
46  float q_va;
47  float q_wind;
48  float q_va_scale;
49 };
50 
51 extern struct WindEstimator wind_estimator;
52 
53 extern void wind_estimator_init(void);
54 extern void wind_estimator_periodic(void);
55 extern void wind_estimator_event(void);
56 
57 // paramenters settings handler
58 extern void wind_estimator_Set_R_GS(float _v);
59 extern void wind_estimator_Set_R_VA(float _v);
60 extern void wind_estimator_Set_R_AOA(float _v);
61 extern void wind_estimator_Set_R_SSA(float _v);
62 extern void wind_estimator_Set_Q_VA(float _v);
63 extern void wind_estimator_Set_Q_WIND(float _v);
64 extern void wind_estimator_Set_Q_VA_SCALE(float _v);
65 
66 #endif
67 
Paparazzi floating point algebra.
void wind_estimator_periodic(void)
void wind_estimator_Set_Q_WIND(float _v)
float q_va
noise associated to airspeed vector model
void wind_estimator_Set_R_AOA(float _v)
struct FloatVect3 wind
wind vector in NED frame
float r_va
noise associated to airspeed norm measurement
float q_wind
noise associated to wind vector model
void wind_estimator_Set_Q_VA_SCALE(float _v)
bool data_available
new data available
void wind_estimator_Set_R_SSA(float _v)
bool reset
reset filter flag
void wind_estimator_Set_R_VA(float _v)
void wind_estimator_Set_R_GS(float _v)
float r_ssa
noise associated to sideslip angle measurement
float q_va_scale
noise associated to airspeed scale factor model
struct FloatVect3 airspeed
airspeed vector in body frame
void wind_estimator_Set_Q_VA(float _v)
struct WindEstimator wind_estimator
void wind_estimator_init(void)
void wind_estimator_event(void)
float r_gs
noise associated to ground speed measurement
float r_aoa
noise associated to angle of attack measurement