summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--configure.ac17
-rw-r--r--drivers.c6
-rw-r--r--gpsd.h16
-rw-r--r--italk.c13
-rw-r--r--libgpsd_core.c4
-rw-r--r--packet_states.h4
-rwxr-xr-xregress-builder7
7 files changed, 27 insertions, 40 deletions
diff --git a/configure.ac b/configure.ac
index 18d50614..d05a0967 100644
--- a/configure.ac
+++ b/configure.ac
@@ -258,19 +258,6 @@ else
AC_MSG_RESULT([no])
fi
-dnl check for iTalk support
-AC_ARG_ENABLE(italk,
- AC_HELP_STRING([--enable-italk],
- [enable iTalk protocol support]),
- [ac_italk=$enableval], [ac_italk=no])
-AC_MSG_CHECKING([for iTalk support])
-if test x"$ac_italk" = "xyes"; then
- AC_MSG_RESULT([yes])
- AC_DEFINE([ITALK_ENABLE], 1, [iTalk binary support])
-else
- AC_MSG_RESULT([no])
-fi
-
dnl check for Navcom support
AC_ARG_ENABLE(navcom,
AC_HELP_STRING([--disable-navcom],
@@ -344,7 +331,7 @@ AC_ARG_ENABLE(rtcm104,
[disable rtcm104 support]),
[ac_rtcm104=$enableval], [ac_rtcm104=yes])
AC_MSG_CHECKING([for rtcm104 support])
-if test x"$ac_earthmate" = "xno" -a x"$ac_evermore" = "xno" -a x"$ac_garmin" = "xno" -a x"$ac_italk" = "xno" -a x"$ac_sirf" = "xno" -a x"$ac_tsip" = "xno" -a x"$ac_navcom" = "xno"; then
+if test x"$ac_earthmate" = "xno" -a x"$ac_evermore" = "xno" -a x"$ac_garmin" = "xno" -a x"$ac_itrax" = "xno" -a x"$ac_sirf" = "xno" -a x"$ac_tsip" = "xno" -a x"$ac_navcom" = "xno"; then
ac_rtcm104=no
fi
if test x"$ac_rtcm104" = "xyes"; then
@@ -607,7 +594,6 @@ echo "Earthmate : $ac_earthmate"
echo "EverMore : $ac_evermore"
echo "FV-18 : $ac_fv18"
echo "Garmin : $ac_garmin"
-echo "iTalk : $ac_italk"
echo "iTrax : $ac_itrax"
echo "NMEA : $ac_nmea"
echo "NTRIP support : $ac_ntrip"
@@ -640,7 +626,6 @@ if test "xdummy" = "xdummy" -a \
x"$evermore" = "xno" -a \
x"$fv18" = "xno" -a \
x"$garmin" = "xno" -a \
- x"$italk" = "xno" -a \
x"$itrax" = "xno" -a \
x"$navcom" = "xno" -a \
x"$nmea" = "xno" -a \
diff --git a/drivers.c b/drivers.c
index 4f90c39c..113de034 100644
--- a/drivers.c
+++ b/drivers.c
@@ -21,7 +21,7 @@ ssize_t generic_get(struct gps_device_t *session)
return packet_get(session->gpsdata.gps_fd, &session->packet);
}
-#if defined(NMEA_ENABLE) || defined(SIRF_ENABLE) || defined(EVERMORE_ENABLE) || defined(ITALK_ENABLE) || defined(NAVCOM_ENABLE)
+#if defined(NMEA_ENABLE) || defined(SIRF_ENABLE) || defined(EVERMORE_ENABLE) || defined(ITRAX_ENABLE) || defined(NAVCOM_ENABLE)
ssize_t pass_rtcm(struct gps_device_t *session, char *buf, size_t rtcmbytes)
/* most GPSes take their RTCM corrections straight up */
{
@@ -880,9 +880,9 @@ static struct gps_type_t *gpsd_driver_array[] = {
#ifdef EVERMORE_ENABLE
&evermore_binary,
#endif /* EVERMORE_ENABLE */
-#ifdef ITALK_ENABLE
+#ifdef ITRAX_ENABLE
&italk_binary,
-#endif /* ITALK_ENABLE */
+#endif /* ITRAX_ENABLE */
#ifdef RTCM104_ENABLE
&rtcm104,
#endif /* RTCM104_ENABLE */
diff --git a/gpsd.h b/gpsd.h
index 78afeff5..cc7da12c 100644
--- a/gpsd.h
+++ b/gpsd.h
@@ -18,7 +18,7 @@
#ifdef EARTHMATE_ENABLE
#define ZODIAC_ENABLE
#endif
-#if defined(ZODIAC_ENABLE) || defined(SIRF_ENABLE) || defined(GARMIN_ENABLE) || defined(TSIP_ENABLE) || defined(EVERMORE_ENABLE) || defined(ITALK_ENABLE) || defined(UBX_ENABLE)
+#if defined(ZODIAC_ENABLE) || defined(SIRF_ENABLE) || defined(GARMIN_ENABLE) || defined(TSIP_ENABLE) || defined(EVERMORE_ENABLE) || defined(ITRAX_ENABLE) || defined(UBX_ENABLE)
#define BINARY_ENABLE
#endif
#if defined(TRIPMATE_ENABLE) || defined(BINARY_ENABLE)
@@ -41,11 +41,13 @@ enum isgpsstat_t {
/*
* The packet buffers need to be as long than the longest packet we
* expect to see in any protocol, because we have to be able to hold
- * an entire packet for checksumming. Thus, in particular, they need
- * to be as long as a UBX SVINFO packet, up to 200 bytes payload and 6
- * bytes of header/length/checksum/trailer.
+ * an entire packet for checksumming...
+ * First we thought it had to be big enough for a SiRF Measured Tracker
+ * Data packet (188 bytes). Then it had to be big enough for a UBX SVINFO
+ * packet (206 bytes). Now it turns out that a couple of ITALK messages are
+ * over 512 bytes. I know we like verbose output, but this is ridiculous.
*/
-#define MAX_PACKET_LENGTH 206 /* 6 + 8 + 192 */
+#define MAX_PACKET_LENGTH 516 /* 7 + 506 + 3 */
/*
* We used to define the input buffer length as MAX_PACKET_LENGTH*2+1.
@@ -55,7 +57,7 @@ enum isgpsstat_t {
* device to be very big. I sometimes see a read of 250 characters or
* more."
*/
-#define INPUT_BUFFER_LENGTH 1024
+#define INPUT_BUFFER_LENGTH 1536
struct gps_packet_t {
/* packet-getter internals */
@@ -136,7 +138,7 @@ extern void rtcm_output_magnavox(isgps30bits_t *, FILE *);
#ifdef EARTHMATE_ENABLE
#define ZODIAC_ENABLE
#endif
-#if defined(ZODIAC_ENABLE) || defined(SIRF_ENABLE) || defined(GARMIN_ENABLE) || defined(TSIP_ENABLE) || defined(EVERMORE_ENABLE) || defined(ITALK_ENABLE)
+#if defined(ZODIAC_ENABLE) || defined(SIRF_ENABLE) || defined(GARMIN_ENABLE) || defined(TSIP_ENABLE) || defined(EVERMORE_ENABLE) || defined(ITRAX_ENABLE)
#define BINARY_ENABLE
#endif
#if defined(TRIPMATE_ENABLE) || defined(BINARY_ENABLE)
diff --git a/italk.c b/italk.c
index cb5f4640..8c697e29 100644
--- a/italk.c
+++ b/italk.c
@@ -14,8 +14,9 @@
#include "gpsd_config.h"
#include "gpsd.h"
-#if defined(ITALK_ENABLE) && defined(BINARY_ENABLE)
+#if defined(ITRAX_ENABLE) && defined(BINARY_ENABLE)
+#define LITTLE_ENDIAN_PROTOCOL
#include "bits.h"
/*@ +charint -usedef -compdef @*/
@@ -65,12 +66,12 @@ static gps_mask_t italk_parse_input(struct gps_device_t *session)
gps_mask_t st;
if (session->packet.type == ITALK_PACKET){
- st = italk_parse(session, session->outbuffer, session->outbuflen);
+ st = italk_parse(session, session->packet.outbuffer, session->packet.outbuflen);
session->gpsdata.driver_mode = 1; /* binary */
return st;
#ifdef NMEA_ENABLE
- } else if (session->packet_type == NMEA_PACKET) {
- st = nmea_parse((char *)session->outbuffer, session);
+ } else if (session->packet.type == NMEA_PACKET) {
+ st = nmea_parse((char *)session->packet.outbuffer, session);
session->gpsdata.driver_mode = 0; /* NMEA */
return st;
#endif /* NMEA_ENABLE */
@@ -108,7 +109,7 @@ static void italk_mode(struct gps_device_t *session, int mode)
#ifdef ALLOW_RECONFIGURE
static void italk_configurator(struct gps_device_t *session, int seq)
{
- if (seq == 0 && session->packet_type == NMEA_PACKET)
+ if (seq == 0 && session->packet.type == NMEA_PACKET)
(void)italk_set_mode(session, session->gpsdata.baudrate, true);
}
#endif /* ALLOW_RECONFIGURE */
@@ -145,4 +146,4 @@ struct gps_type_t italk_binary =
.wrapup = NULL, /* no close hook */
.cycle = 1, /* updates every second */
};
-#endif /* defined(ITALK_ENABLE) && defined(BINARY_ENABLE) */
+#endif /* defined(ITRAX_ENABLE) && defined(BINARY_ENABLE) */
diff --git a/libgpsd_core.c b/libgpsd_core.c
index 0e8b15d1..16bb7d9e 100644
--- a/libgpsd_core.c
+++ b/libgpsd_core.c
@@ -673,11 +673,11 @@ gps_mask_t gpsd_poll(struct gps_device_t *session)
(void)gpsd_switch_driver(session, "EverMore binary");
break;
#endif /* EVERMORE_ENABLE */
-#ifdef ITALK_ENABLE
+#ifdef ITRAX_ENABLE
case ITALK_PACKET:
(void)gpsd_switch_driver(session, "iTalk binary");
break;
-#endif /* ITALK_ENABLE */
+#endif /* ITRAX_ENABLE */
#ifdef RTCM104_ENABLE
case RTCM_PACKET:
(void)gpsd_switch_driver(session, "RTCM104");
diff --git a/packet_states.h b/packet_states.h
index fb2ea8ef..a0615f18 100644
--- a/packet_states.h
+++ b/packet_states.h
@@ -72,7 +72,7 @@
EVERMORE_RECOGNIZED, /* found end of EverMore packet */
#endif /* EVERMORE_ENABLE */
-#ifdef ITALK_ENABLE
+#ifdef ITRAX_ENABLE
ITALK_LEADER_1, /* saw leading < of iTalk packet */
ITALK_LEADER_2, /* saw leading ! of iTalk packet */
ITALK_LENGTH, /* saw packet length */
@@ -80,7 +80,7 @@
ITALK_DELIVERED, /* seen end of payload */
ITALK_TRAILER, /* saw iTalk trailer byte */
ITALK_RECOGNIZED, /* found end of the iTalk packet */
-#endif /* ITALK_ENABLE */
+#endif /* ITRAX_ENABLE */
#ifdef NAVCOM_ENABLE
NAVCOM_EXPECTED, /* expecting Navcom packet */
diff --git a/regress-builder b/regress-builder
index aa2e5548..eef5f9d7 100755
--- a/regress-builder
+++ b/regress-builder
@@ -21,9 +21,8 @@ driver_names = (
"evermore",
"fv18",
"garmin",
-# "italk",
-# "itrax",
-# "navcom",
+ "itrax",
+ "navcom",
"nmea",
"ntrip",
"rtcm104",
@@ -31,7 +30,7 @@ driver_names = (
# "tnt",
"tripmate",
"tsip",
-# "ubx",
+ "ubx",
}
cyclesize = 2 ** len(driver_names)