diff options
author | Keith Packard <keithp@keithp.com> | 2013-05-14 09:12:29 -0700 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2013-05-15 22:11:21 -0700 |
commit | 5e9193f6375be27e5f7a0321fd34b6acfe81247f (patch) | |
tree | a7222f619868ec65d99bfd1046bb07b368849e37 /src/test/ao_gps_test_skytraq.c | |
parent | cdad289a0803babecd30cbc0a95be99c5caadeb5 (diff) |
altos: Add 'g' command to ublox GPS code.
Take the gps_dump function from ao_gps_skytraq.c and move it to a new
file so it can be shared with the u-blox driver. That affects every
skytraq and u-blox user as they need to include the new file.
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.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/test/ao_gps_test_skytraq.c b/src/test/ao_gps_test_skytraq.c index 81008b39..89cbd767 100644 --- a/src/test/ao_gps_test_skytraq.c +++ b/src/test/ao_gps_test_skytraq.c @@ -75,6 +75,11 @@ struct ao_gps_tracking_orig { #define ao_telemetry_satellite ao_gps_tracking_orig #define ao_telemetry_satellite_info ao_gps_sat_orig +extern __xdata struct ao_telemetry_location ao_gps_data; +extern __xdata struct ao_telemetry_satellite ao_gps_tracking_data; + +uint8_t ao_gps_mutex; + void ao_mutex_get(uint8_t *mutex) { @@ -432,17 +437,14 @@ uint8_t ao_task_minimize_latency; #define ao_usb_getchar() 0 #include "ao_gps_print.c" +#include "ao_gps_show.c" #include "ao_gps_skytraq.c" void ao_dump_state(void *wchan) { if (wchan == &ao_gps_data) - ao_gps_print(&ao_gps_data); - else - ao_gps_tracking_print(&ao_gps_tracking_data); - putchar('\n'); - return; + ao_gps_show(); } int |