Quantcast

Re: gpsbabel automatically adds waypoint cmt and desc tags; can this be prevented?

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: gpsbabel automatically adds waypoint cmt and desc tags; can this be prevented?

Tom Grundy
[copy of the stackoverflow question at http://stackoverflow.com/questions/39951404; answer either here or there, I will clean it up and make sure the answer gets to both places, thanks]



It seems that gpsbabel always adds cmt and desc tags for waypoint objects during import and export for Garmin USB mode, and for GPX concatenate.

For example, exporting this GPX file (no desc tag; empty cmt tag) from the computer to Garmin 60CSx using Garmin USB mode:

<wpt lat=\"39.450957671005\" lon=\"-120.55621584319\">\r\n    <name>a</name>\r\n    <cmt/>\r\n  </wpt>\r\n  <wpt lat=\"39.458578968034\" lon=\"-120.57449777984\">\r\n    <name>b</name>\r\n    <cmt/>\r\n  </wpt>\r\n  <wpt lat=\"39.440153881536\" lon=\"-120.5755277481\">\r\n    <name>c</name>\r\n    <cmt/>\r\n  </wpt>\r\n

results in the "Note" field on the 60CSx (not sure if that corresponds to cmt or desc) with the same value as the waypoint name.

Importing back to the computer results in this gpx, with automatically generated cmt and desc tags:

<wpt lat=\"39.450957671\" lon=\"-120.556215843\">\r\r\n    <name>a</name>\r\r\n    <cmt>a</cmt>\r\r\n    <desc>a</desc>\r\r\n  </wpt>\r\r\n  <wpt lat=\"39.458578968\" lon=\"-120.574497780\">\r\r\n    <name>b</name>\r\r\n    <cmt>b</cmt>\r\r\n    <desc>b</desc>\r\r\n  </wpt>\r\r\n  <wpt lat=\"39.440153882\" lon=\"-120.575527748\">\r\r\n    <name>c</name>\r\r\n    <cmt>c</cmt>\r\r\n    <desc>c</desc>\r\r\n  </wpt>\r\r\n

The same behavior is seen when using gpsbabel to concatenate gpx files.

I believe gpsbabel is adding these tags, and not the GPS unit, because using Garmin Mass Storage Mode (i.e. copying the file as to/from a thumb drive) to perform the import/export to a Garmin 62 or 64 does not result in any Note text on the 62 or 64, and the file on the mounted 62 or 64 drive does not contain any cmt or desc tags, but, the output of gpsbabel concatenation of these files does contain automatically generated cmt and desc tags as above.

Is there a way to disable this behavior?



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Gpsbabel-misc mailing list http://www.gpsbabel.org
[hidden email]
To unsubscribe, change list options, or see archives, visit:
https://lists.sourceforge.net/lists/listinfo/gpsbabel-misc
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: gpsbabel automatically adds waypoint cmt and desc tags; can this be prevented?

Robert Lipe-4
When writing GPX, we aggressively fill empty fields.  Because different programs display name/cmt/desc by default (or singly) we "upfill" empty fields.  For example, if you have a GPS that supplies only name but are using a program that displays only cmt, this lets the name be seen where if we didn't upfill, you'd see nothing.  It's kind of a problem where we have zero or more of three inputs and three outputs and don't know which will be read.

There's no switch to disable this. It can, of course, be changed by modifying gpx.cc and rebuilding.

On Sun, Oct 9, 2016 at 9:48 PM, Tom Grundy <[hidden email]> wrote:
[copy of the stackoverflow question at http://stackoverflow.com/questions/39951404; answer either here or there, I will clean it up and make sure the answer gets to both places, thanks]



It seems that gpsbabel always adds cmt and desc tags for waypoint objects during import and export for Garmin USB mode, and for GPX concatenate.

For example, exporting this GPX file (no desc tag; empty cmt tag) from the computer to Garmin 60CSx using Garmin USB mode:

<wpt lat=\"39.450957671005\" lon=\"-120.55621584319\">\r\n    <name>a</name>\r\n    <cmt/>\r\n  </wpt>\r\n  <wpt lat=\"39.458578968034\" lon=\"-120.57449777984\">\r\n    <name>b</name>\r\n    <cmt/>\r\n  </wpt>\r\n  <wpt lat=\"39.440153881536\" lon=\"-120.5755277481\">\r\n    <name>c</name>\r\n    <cmt/>\r\n  </wpt>\r\n

results in the "Note" field on the 60CSx (not sure if that corresponds to cmt or desc) with the same value as the waypoint name.

Importing back to the computer results in this gpx, with automatically generated cmt and desc tags:

<wpt lat=\"39.450957671\" lon=\"-120.556215843\">\r\r\n    <name>a</name>\r\r\n    <cmt>a</cmt>\r\r\n    <desc>a</desc>\r\r\n  </wpt>\r\r\n  <wpt lat=\"39.458578968\" lon=\"-120.574497780\">\r\r\n    <name>b</name>\r\r\n    <cmt>b</cmt>\r\r\n    <desc>b</desc>\r\r\n  </wpt>\r\r\n  <wpt lat=\"39.440153882\" lon=\"-120.575527748\">\r\r\n    <name>c</name>\r\r\n    <cmt>c</cmt>\r\r\n    <desc>c</desc>\r\r\n  </wpt>\r\r\n

The same behavior is seen when using gpsbabel to concatenate gpx files.

I believe gpsbabel is adding these tags, and not the GPS unit, because using Garmin Mass Storage Mode (i.e. copying the file as to/from a thumb drive) to perform the import/export to a Garmin 62 or 64 does not result in any Note text on the 62 or 64, and the file on the mounted 62 or 64 drive does not contain any cmt or desc tags, but, the output of gpsbabel concatenation of these files does contain automatically generated cmt and desc tags as above.

Is there a way to disable this behavior?



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Gpsbabel-misc mailing list http://www.gpsbabel.org
[hidden email]
To unsubscribe, change list options, or see archives, visit:
https://lists.sourceforge.net/lists/listinfo/gpsbabel-misc



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Gpsbabel-misc mailing list http://www.gpsbabel.org
[hidden email]
To unsubscribe, change list options, or see archives, visit:
https://lists.sourceforge.net/lists/listinfo/gpsbabel-misc
SRE
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: gpsbabel automatically adds waypoint cmt and desc tags; can this be prevented?

SRE
At 10:01 AM 10/11/2016, Robert Lipe wrote:
>When writing GPX, we aggressively fill empty fields.

That can cause problems. I had to write a hack to ditch CMT when DESC
exists because having them both there can result in duplicate displays.
I don't remember right now where that came up, but... why not have a
"copy field" switch or setting that controls the duplication (both for
source and destination) instead of bloating the GPX output with info
the user may not want/need? Default could be "populate all" as now.

My old Garmin dashboard unit would not display any sort of comment
field ever under any circumstances period. But if it saw a garmin
format street address tag it would show that right where you'd
expect the comment to be... so I wrote a hack that transformed the
comment into a street address. Silly, it seems, but useful at the time.
For my current Nuvi I append the comment field onto the waypoint name
for proximity alerts, which will otherwise show only the short name.
Those are two examples of the sort of field-copying mechanism I'm
asking about, but I haven't spent any time fleshing out how it could
work in general because I'm not sure anyone will like the idea.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Gpsbabel-misc mailing list http://www.gpsbabel.org
[hidden email]
To unsubscribe, change list options, or see archives, visit:
https://lists.sourceforge.net/lists/listinfo/gpsbabel-misc
Loading...