Paparazzi UAS  v5.2.2_stable-0-gd6b9f29
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
gps_sim_nps.h
Go to the documentation of this file.
1 #ifndef GPS_SIM_NPS_H
2 #define GPS_SIM_NPS_H
3 
4 #include "std.h"
5 
6 #define GPS_NB_CHANNELS 16
7 
8 extern bool_t gps_available;
9 extern bool_t gps_has_fix;
10 
11 extern void gps_feed_value();
12 
13 extern void gps_impl_init();
14 
15 #define GpsEvent(_sol_available_callback) { \
16  if (gps_available) { \
17  gps.last_msg_ticks = sys_time.nb_sec_rem; \
18  gps.last_msg_time = sys_time.nb_sec; \
19  if (gps.fix == GPS_FIX_3D) { \
20  gps.last_3dfix_ticks = sys_time.nb_sec_rem; \
21  gps.last_3dfix_time = sys_time.nb_sec; \
22  } \
23  _sol_available_callback(); \
24  gps_available = FALSE; \
25  } \
26  }
27 
28 #endif /* GPS_SIM_NPS_H */
bool_t gps_has_fix
Definition: gps_sim_nps.c:35
void gps_impl_init()
GPS initialization.
Definition: gps_ardrone2.c:38
void gps_feed_value()
Definition: gps_sim_nps.c:37
bool_t gps_available
Is set to TRUE when a new REMOTE_GPS packet is received and parsed.
Definition: gps_datalink.c:32