Opened 9 years ago

Closed 8 years ago

#611 closed enhancement/feature request (fixed)

GPX should log more parameters, including HDOP

Reported by: polarbear_n Owned by: number6
Priority: major Milestone: version 0.2.0
Component: core Version: git master
Severity: Keywords: gpx parameters, hdop
Cc: nick@…

Description

The parameters that can be written to the GPX file are still quite limited.

height, hdop, vdop, sats_visible, sats_used, status

are internally available, so it should be easy to write them to the gpx file.

height is important for height-profiles, hdop is used by JOSM to show circles of estimated accuracy.

Thanks!

Attachments (1)

navit_3490_ticket_611.patch (5.3 KB) - added by mvglasow (2) 9 years ago.
Patch to support logging ele (elevation), hdop and sat (satellites used) to GPX; tested on Windows CE. Patch includes some missing function documentation.

Download all attachments as: .zip

Change History (10)

comment:1 Changed 9 years ago by mvglasow (2)

  • Owner changed from KaZeR to mvglasow (2)
  • Status changed from new to assigned

comment:2 Changed 9 years ago by mvglasow (2)

In progress, need to compile and test:

  • height -> <ele>
  • hdop -> <hdop>
  • sats_used -> <sats>

vdop does not have a corresponding attribute (we would need to introduce that first), same goes for pdop (for the sake of completeness).

sats_visible does not have a GPX counterpart, so I left it out for now. If needed, we'd have to define a navit-specific extension for it.

status is even more complex. GPX defines a <fix> tag with a set of defined values (none, 2d, 3d, dgps, pps). With a NMEA receiver one would have to evaluate the GPGGA and GPGSA messages and examine the status fields returned by both.

NMEA-based vehicle definitions use just the GPGGA status field and report it back internally. The gpsd vehicle definition uses the GPGSA values (minus one) instead, other vehicle definitions have again different semantics. See #610 for a full description.

Unfortunately, the definition of status is too lax to read anything other than "valid fix or no valid fix" from it and is thus insufficient for populating the <fix> tag. At most, we could introduce a navit-specific tag, but I doubt it would be meaningful: when status is zero, nothing gets logged anyway, and the semantics of the nonzero values depend on the vehicle used: a 3D non-differential GPS fix would be reported as 1 on WinCE, as 2 with gpsd and as 3 with gypsy. A DGPS fix would correspond to 2 on WinCE and to 1 on Maemo. Android, iPhone and others do not supply status at all.

comment:3 Changed 9 years ago by mvglasow (2)

about to test; settings need to be enabled in navit.xml (attr_types of the log element):

<log enabled="yes" type="gpx" attr_types="position_time_iso8601,position_direction,position_hdop,position_height,position_speed,profilename,position_radius, position_sats_used" data="/Storage Card/navit/tracks/%Y%m%d-%%i.gpx" flush_size="1000" flush_time="30"/>

comment:4 Changed 9 years ago by mvglasow (2)

correction to the above: it is VERY important to avoid spaces between the attributes to log - in the above example, position_sats_used would not get logged because of the space in front of it. We might want to strip whitespace characters when parsing to avoid such effects...

Changed 9 years ago by mvglasow (2)

Patch to support logging ele (elevation), hdop and sat (satellites used) to GPX; tested on Windows CE. Patch includes some missing function documentation.

comment:5 Changed 9 years ago by mvglasow (2)

  • Owner mvglasow (2) deleted
  • Status changed from assigned to new

comment:6 follow-up: Changed 9 years ago by mvglasow (2)

can someone merge the patch into SVN? After that I suggest we discuss whether we really need any of the remaining attributes (vdop, pdop, status/fix, sats_visible).

Personally, I consider my itches scratched (those being elevation and hdop).

comment:7 in reply to: ↑ 6 Changed 9 years ago by tegzed

I have tested this on Ubuntu Lucid Lynx with gpsd and worked OK.

comment:8 Changed 8 years ago by number6

  • Cc nick@… added
  • Owner set to number6
  • Status changed from new to assigned

Want to create a full patch, with comments and documentation? (Last rev for this file was 3464 and we're currently on r3541)

Please do so I can test and commit for you.

comment:9 Changed 8 years ago by number6

  • Resolution set to fixed
  • Status changed from assigned to closed

Added in Revision 3614

Note: See TracTickets for help on using tickets.