summaryrefslogtreecommitdiff
path: root/src/test/ao_gps_test_skytraq.c
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2014-07-10 17:07:48 -0700
committerKeith Packard <keithp@keithp.com>2014-07-10 17:35:44 -0700
commit34d5be68ca23e8beb05db9a480faef63ecc911d0 (patch)
treebcf27108a1680f6c081f583f25b831fc192ac256 /src/test/ao_gps_test_skytraq.c
parent0d044af0c5025a63026d05adcab68f265f179668 (diff)
altos: Extend GPS altitudes to at least 24 bits everywhere
Telemetry gets a special 'mode' flag indicating that 24-bit data is present; log files get new data and log readers are expected to detect that via the firmware version number. Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'src/test/ao_gps_test_skytraq.c')
-rw-r--r--src/test/ao_gps_test_skytraq.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/test/ao_gps_test_skytraq.c b/src/test/ao_gps_test_skytraq.c
index 1b590d5e..5eb7118d 100644
--- a/src/test/ao_gps_test_skytraq.c
+++ b/src/test/ao_gps_test_skytraq.c
@@ -16,6 +16,7 @@
*/
#define AO_GPS_TEST
+#define HAS_GPS 1
#include "ao_host.h"
#include <termios.h>
#include <errno.h>
@@ -53,6 +54,9 @@ struct ao_gps_orig {
uint16_t v_error; /* m */
};
+#define AO_TELEMETRY_LOCATION_ALTITUDE(l) ((l)->altitude)
+#define AO_TELEMETRY_LOCATION_SET_ALTITUDE(l,a) ((l)->altitude = (a))
+
#define SIRF_SAT_STATE_ACQUIRED (1 << 0)
#define SIRF_SAT_STATE_CARRIER_PHASE_VALID (1 << 1)
#define SIRF_SAT_BIT_SYNC_COMPLETE (1 << 2)