X-Git-Url: https://git.gag.com/?p=fw%2Faltos;a=blobdiff_plain;f=src%2Fao_gps_test.c;h=cdcc6f4c375ce0fbb14eb454f2c2f235810ae3bb;hp=366bca718a76851a31c26434a124b794324f3d10;hb=9394393c24c0a96b94319f2d0aa78fb498a121c9;hpb=fb8f3fee6a1bab1e46d782e84405845cee2dadb4 diff --git a/src/ao_gps_test.c b/src/ao_gps_test.c index 366bca71..cdcc6f4c 100644 --- a/src/ao_gps_test.c +++ b/src/ao_gps_test.c @@ -27,8 +27,12 @@ #define AO_GPS_VALID (1 << 4) #define AO_GPS_RUNNING (1 << 5) +#define AO_GPS_DATE_VALID (1 << 6) struct ao_gps_data { + uint8_t year; + uint8_t month; + uint8_t day; uint8_t hour; uint8_t minute; uint8_t second; @@ -55,7 +59,6 @@ struct ao_gps_data { struct ao_gps_sat_data { uint8_t svid; - uint8_t state; uint8_t c_n_1; }; @@ -397,6 +400,8 @@ ao_serial_set_speed(uint8_t speed) tcflush(fd, TCIFLUSH); } +#define ao_time() 0 + #include "ao_gps_print.c" #include "ao_gps_sirf.c" @@ -431,9 +436,9 @@ ao_dump_state(void *wchan) printf("\n"); printf ("\t"); for (i = 0; i < 12; i++) - printf (" %2d(%02x)", + printf (" %2d(%02d)", ao_gps_tracking_data.sats[i].svid, - ao_gps_tracking_data.sats[i].state); + ao_gps_tracking_data.sats[i].c_n_1); printf ("\n"); }