Paparazzi UAS  v4.2.2_stable-4-gcc32f65
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
ahrs_sim.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2011 The Paparazzi Team
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, write to
18  * the Free Software Foundation, 59 Temple Place - Suite 330,
19  * Boston, MA 02111-1307, USA.
20  */
21 
22 #ifndef AHRS_SIM_H
23 #define AHRS_SIM_H
24 
25 #include "subsystems/ahrs.h"
26 #include "std.h"
27 
28 extern bool_t ahrs_sim_available;
29 
30 #ifdef AHRS_UPDATE_FW_ESTIMATOR
31 #include "estimator.h"
32 // TODO copy ahrs to state instead of estimator
33 void ahrs_update_fw_estimator(void);
34 extern float ins_roll_neutral;
35 extern float ins_pitch_neutral;
36 #endif
37 
38 extern void update_ahrs_from_sim(void);
39 
40 #define AhrsEvent(_available_callback) { \
41  if (ahrs_sim_available) { \
42  update_ahrs_from_sim(); \
43  _available_callback(); \
44  ahrs_sim_available = FALSE; \
45  } \
46  }
47 
48 
49 
50 #endif /* AHRS_SIM_H */
Attitude and Heading Reference System interface.
bool_t ahrs_sim_available
Definition: jsbsim_ahrs.c:17
void update_ahrs_from_sim(void)
Definition: ahrs_sim.c:42
float ins_pitch_neutral
Definition: ins_arduimu.c:15
void ahrs_update_fw_estimator(void)
State estimation, fusioning sensors.
float ins_roll_neutral
Definition: ins_arduimu.c:14