diff options
| author | Bdale Garbee <bdale@gag.com> | 2014-08-14 17:08:36 -0600 |
|---|---|---|
| committer | Bdale Garbee <bdale@gag.com> | 2014-08-14 17:08:36 -0600 |
| commit | 4828be0ca5252ac9cd6061209385dcd6c4c57965 (patch) | |
| tree | dde4f86d893d280fbeef284120d6f967cdbfeaa5 /src/kernel/ao_gps_show.c | |
| parent | 17e894d1b65231d07df009bc4e8ca92864ccf790 (diff) | |
| parent | 165b7dcf6fba90b15ff32b891cba4b9111c1965b (diff) | |
Merge branch 'master' of ssh://git.gag.com/scm/git/fw/altos
Diffstat (limited to 'src/kernel/ao_gps_show.c')
| -rw-r--r-- | src/kernel/ao_gps_show.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/kernel/ao_gps_show.c b/src/kernel/ao_gps_show.c index 3a05e35a..e45cd795 100644 --- a/src/kernel/ao_gps_show.c +++ b/src/kernel/ao_gps_show.c @@ -19,6 +19,8 @@ #include <ao.h> #endif +#include <ao_data.h> + void ao_gps_show(void) __reentrant { @@ -27,7 +29,11 @@ ao_gps_show(void) __reentrant printf ("Date: %02d/%02d/%02d\n", ao_gps_data.year, ao_gps_data.month, ao_gps_data.day); printf ("Time: %02d:%02d:%02d\n", ao_gps_data.hour, ao_gps_data.minute, ao_gps_data.second); printf ("Lat/Lon: %ld %ld\n", (long) ao_gps_data.latitude, (long) ao_gps_data.longitude); - printf ("Alt: %d\n", ao_gps_data.altitude); +#if HAS_WIDE_GPS + printf ("Alt: %ld\n", (long) AO_TELEMETRY_LOCATION_ALTITUDE(&ao_gps_data)); +#else + printf ("Alt: %d\n", AO_TELEMETRY_LOCATION_ALTITUDE(&ao_gps_data)); +#endif printf ("Flags: 0x%x\n", ao_gps_data.flags); printf ("Sats: %d", ao_gps_tracking_data.channels); for (i = 0; i < ao_gps_tracking_data.channels; i++) |
