diff options
-rw-r--r-- | gps.h | 2 | ||||
-rw-r--r-- | gpsd.h-tail | 19 | ||||
-rw-r--r-- | libgps_json.c | 2 | ||||
-rw-r--r-- | libgpsd_core.c | 4 |
4 files changed, 14 insertions, 13 deletions
@@ -1957,7 +1957,7 @@ struct gps_data_t { #define LOGMESSAGE_SET (1llu<<30) #define ERROR_SET (1llu<<31) #define TIMEDRIFT_SET (1llu<<32) -#define EOF_SET (1llu<<33) +#define PPSDRIFT_SET (1llu<<33) #define SET_HIGH_BIT 34 timestamp_t online; /* NZ if GPS is on line, 0 if not. * diff --git a/gpsd.h-tail b/gpsd.h-tail index 741f58b0..a9d25063 100644 --- a/gpsd.h-tail +++ b/gpsd.h-tail @@ -327,15 +327,16 @@ typedef enum { #define STATUS_DGPS_FIX 2 /* yes, with DGPS */ #define INTERNAL_SET(n) ((gps_mask_t)(1llu<<(SET_HIGH_BIT+(n)))) -#define RAW_IS INTERNAL_SET(1) /* raw pseudorange data available */ -#define USED_IS INTERNAL_SET(2) /* sat-used count available */ -#define DRIVER_IS INTERNAL_SET(3) /* driver type identified */ -#define CLEAR_IS INTERNAL_SET(4) /* starts a reporting cycle */ -#define REPORT_IS INTERNAL_SET(5) /* ends a reporting cycle */ -#define NODATA_IS INTERNAL_SET(6) /* no data read from fd */ -#define PPSTIME_IS INTERNAL_SET(7) /* precision time is available */ -#define PERR_IS INTERNAL_SET(8) /* PDOP set */ -#define PASSTHROUGH_IS INTERNAL_SET(9) /* passthrough mode */ +#define RAW_IS INTERNAL_SET(1) /* raw pseudoranges available */ +#define USED_IS INTERNAL_SET(2) /* sat-used count available */ +#define DRIVER_IS INTERNAL_SET(3) /* driver type identified */ +#define CLEAR_IS INTERNAL_SET(4) /* starts a reporting cycle */ +#define REPORT_IS INTERNAL_SET(5) /* ends a reporting cycle */ +#define NODATA_IS INTERNAL_SET(6) /* no data read from fd */ +#define PPSTIME_IS INTERNAL_SET(7) /* precision time is available */ +#define PERR_IS INTERNAL_SET(8) /* PDOP set */ +#define PASSTHROUGH_IS INTERNAL_SET(9) /* passthrough mode */ +#define EOF_IS INTERNAL_SET(10) /* synthetic EOF */ #define DATA_IS ~(ONLINE_SET|PACKET_SET|CLEAR_IS|REPORT_IS) typedef /*@unsignedintegraltype@*/ unsigned int driver_mask_t; diff --git a/libgps_json.c b/libgps_json.c index f58de8be..156ddf1b 100644 --- a/libgps_json.c +++ b/libgps_json.c @@ -521,7 +521,7 @@ int libgps_json_unpack(const char *buf, status = json_pps_read(buf, gpsdata, end); if (status == 0) { gpsdata->set &= ~UNION_SET; - gpsdata->set |= TIMEDRIFT_SET; + gpsdata->set |= PPSDRIFT_SET; } return status; } else diff --git a/libgpsd_core.c b/libgpsd_core.c index f9eec664..149982fc 100644 --- a/libgpsd_core.c +++ b/libgpsd_core.c @@ -1226,7 +1226,7 @@ gps_mask_t gpsd_poll(struct gps_device_t *session) if (strcmp((const char *)session->lexer.outbuffer, "# EOF\n") == 0) { gpsd_report(&session->context->errout, LOG_PROG, "synthetic EOF\n"); - return EOF_SET; + return EOF_IS; } else gpsd_report(&session->context->errout, LOG_PROG, @@ -1507,7 +1507,7 @@ int gpsd_multipoll(const bool data_ready, for (fragments = 0; ; fragments++) { gps_mask_t changed = gpsd_poll(device); - if (changed == EOF_SET) { + if (changed == EOF_IS) { gpsd_report(&device->context->errout, LOG_WARN, "device signed off %s\n", device->gpsdata.dev.path); |