diff options
author | gdt <gdt> | 2009-02-08 15:30:26 +0000 |
---|---|---|
committer | gdt <gdt> | 2009-02-08 15:30:26 +0000 |
commit | 9b74338b3f954542df3446154d3961d6ef5d5d20 (patch) | |
tree | cd59a59c4f71dd9517f59bff46a283fe0d893f82 /geography/gpsbabel/patches/patch-af | |
parent | 19229d7848622dacb4de300a2d6f0424c1f2ea89 (diff) | |
download | pkgsrc-9b74338b3f954542df3446154d3961d6ef5d5d20.tar.gz |
Update to 1.3.6 from 1.3.4. Add two patches from Giles Lean to work
around what is believed to be bugs in Prolific USB convertors. Point
to pkgsrc-hosted distfile because upstream distfile, although
LICENSE=gnu-gpl-v2 is apparently only available via a web form.
Full changes available at
http://www.gpsbabel.org/changes.html
Notable changes in 1.3.6:
Fix writing waypoint names under 6 characters to old serial Garmins.
Notable changes in 1.3.5:
Read waypointsw from jpg/exif.
Add support for osm (openstreetmap) format files.
Set computer's clock from GARMIN.
Diffstat (limited to 'geography/gpsbabel/patches/patch-af')
-rw-r--r-- | geography/gpsbabel/patches/patch-af | 74 |
1 files changed, 74 insertions, 0 deletions
diff --git a/geography/gpsbabel/patches/patch-af b/geography/gpsbabel/patches/patch-af new file mode 100644 index 00000000000..3250b4494fb --- /dev/null +++ b/geography/gpsbabel/patches/patch-af @@ -0,0 +1,74 @@ +$NetBSD: patch-af,v 1.1 2009/02/08 15:30:26 gdt Exp $ + +From Giles Lean, who places it in the public domain. Workarounds for +problems with buggy USB serial adapators. + +--- jeeps/gpsread.c.orig 2006-04-19 22:20:18.000000000 -0400 ++++ jeeps/gpsread.c +@@ -103,6 +103,37 @@ int32 GPS_Serial_Packet_Read(gpsdevh *fd + + if(!len) + { ++ /* ++ * Missed DLE characters have been observed with Geko ++ * 201 and Legend GPSRs with Prolific USB-serial ++ * cables. The following kludge seems to help. ++ * ++ * It has been tested so far with the following ++ * combinations of software and hardware: ++ * ++ * OS X 10.4.x and 10.5.x: ++ * ++ * - a Geko 201 (firmware version 2.70) and a third ++ * party cable using a Prolific USB-serial converter ++ * - a Legend using a serial cable with a non-integral ++ * Prolific USB-serial converter. ++ * ++ * NetBSD-4.0/i386 with the Geko and cable as above. ++ * ++ * REVISIT GFL Should this be a switch in a .ini file? ++ * ++ * + it's a kludge, so leaving it always on is ugly ++ * - if it's harmless to properly working hardware, ++ * then it's a better user experience to leave it on ++ */ ++ if (u == 0x06 || u == 0x15) ++ { ++ (*packet)->dle = DLE; ++ ++len; ++ (void) fprintf(stderr,"GPS_Packet_Read: inserted DLE due to 0x%02x.\n", u); ++ goto dle_missed; ++ } ++ + (*packet)->dle = u; + if(u != DLE) + { +@@ -114,6 +145,7 @@ int32 GPS_Serial_Packet_Read(gpsdevh *fd + continue; + } + ++dle_missed: + if(len==1) + { + (*packet)->type = u; +@@ -212,6 +244,20 @@ int32 GPS_Serial_Get_Ack(gpsdevh *fd, GP + + if(*(*rec)->data != (*tra)->type) + { ++ /* ++ * When used with a buggy Prolific USB-serial converter the ++ * calling sequence GPS_A000() -> GPS_Get_Ack() sometimes ++ * returns data != type causing this routine to fail and the ++ * following error message to be emitted: ++ * ++ * GARMIN:Can't init /dev/cu.usbserial ++ * ++ * Manually retrying usually works, and subsequent ++ * investigation shows that the call that fails is made from ++ * GPS_Init() which in this case is GPS_Serial_Init(). Simply ++ * retrying the call a workaround: see note and retry loop in ++ * gpsapp.c:GPS_Init(). ++ */ + gps_error = FRAMING_ERROR; + return 0; + } |