GPS data integration

From SpinetiX Support Wiki

(Redirected from GPS receivers)
Jump to: navigation, search

This page is related to the Interactivity via RS232 page.

Introduction

Icon GPS widgets.png

The Global Positioning System (GPS) is a global satellite-based radionavigation system that provides geolocation and time information to a GPS receiver anywhere on or near the Earth where there is an unobstructed line of sight to four or more GPS satellites. The United States government created the system, maintains it, and makes it freely accessible to anyone with a GPS receiver.

The GPS concept is based on time and the known position of GPS specialized satellites. The satellites carry very stable atomic clocks that are synchronized with one another and with the ground clocks. Any drift from true time maintained on the ground is corrected daily. In the same manner, the satellite locations are known with great precision. GPS receivers have clocks as well, but they are less stable and less precise.

GPS satellites continuously transmit data about their current time and position. A GPS receiver monitors multiple satellites and solves equations to determine the precise position of the receiver and its deviation from true time. At a minimum, four satellites must be in view of the receiver for it to compute four unknown quantities (three position coordinates and clock deviation from satellite time).

The HMP natively supports the NMEA-0183 standard for GPS communication, through the built-in "[sys] nmea-gps" serial port protocol file. The supported messages are GGA for position related information and VTG for course and speed (over ground) information.

Compatible GPS receivers

The list below is not exhaustive and you are invited to share your experiences with devices you have successfully tested, so it remains up-to-date. Special thanks to all our partners reporting compatible devices!

Manufacturer Model Added on Tested by Notes
Evermore SA320 2015-04-27 Sanel (BE)
GlobalSat BR-355 2012-09-04 Mediatec Solutions (SE) A DE-9 male-female null modem adapter (or cable) should be used between the SpinetiX serial cable and the serial cable of the device. Also a custom power supply via PS2 cable is needed.
Navman GPS3260 2010-12-22 SpinetiX


Note Notes:
  • If your GPS device is not using the NMEA-0183 protocol, but is able to communicate via RS232, it can still be used with the HMP, but you will probably need to write another fsm protocol file according to that device documentation.
  • If your GPS device is communicating via USB, then it must conform to the HID standard to be used with the HMP. In this case, you don't need to use a serial protocol file.

NMEA-0183 protocol file

The player built-in "[sys] nmea-gps" serial port protocol file (available also for download on the right) must be activated to be able to access the GPS data. The protocol parser works only for two GP sentences (the prefix for GPS receivers): GGA (for position related information) and VTG messages (for course and speed information); other sentences being ignored.

The messages are parsed and the results (in CSV format) are automatically pushed onto two Shared Variables: gps_gga and gps_vtg, which can be used as data source within the existing data feed widgets.


Note Notes:
  • Some fields may be empty, if no information is available.
  • The checksum field is always reported as the last column. It is empty if not present. The checksum is the 8 bit exclusive OR of all characters in the sentence. The characters in the sentence are obtained by joining all the columns representing present fields in the table with commas. The checksum column, as well as any non-present fields (e.g., VTG mode), are left out.
  • The protocol parser does not use the checksums to verify the validity of the received data - for protection against transmission errors, this must be done afterwards, when processing the Shared Variables. Nevertheless, malformed messages are ignored and do not update the Shared Variables.

GGA data

The gps_gga message contains all position related information. The following fields are returned by the built-in protocol file:

  • talker : Device category, set to "GP".
  • type : Data type, set to "GGA" (Global Positioning System Fix Data).
  • time_h, time_m, time_s : UTC time as hours, minutes and seconds.
  • lat_d, lat_m, lat_ns : Latitude coordinate in degrees, minutes and north-south position.
  • long_d, long_m, long_ew : Longitude coordinate in degrees, minutes and east-west position.
  • fix : Fix quality, detailed below.
  • nr_sats : Number of satellites being tracked.
  • hdop : Horizontal dilution of position.
  • alt : Altitude above mean sea level.
  • alt_unit : M (meters).
  • geoid_sep : Height of geoid (mean sea level) above WGS84 ellipsoid.
  • geoid_sep_unit : M (meters).
  • dgps_age : Time in seconds since last DGPS update.
  • dgps_ref_id : DGPS station ID number.
  • mode : The FAA mode field might be present on some on NMEA 2.3 equipment, and may be empty if present; its meaning is as indicated below.
  • mode_present : The presence of the mode field (0 = absent, 1 = present).
  • csum : Checksum data.

The meaning of the fix field is:

   0 - fix not available
   1 - GPS fix
   2 - Differential GPS fix (values greater than 2 are 2.3 features)
   3 - PPS fix
   4 - Real Time Kinematic (RTK)
   5 - Float RTK
   6 - estimated (dead reckoning) (2.3 feature)
   7 - manual input mode
   8 - simulation mode

The meaning of the mode field is:

   A - autonomous mode
   D - differential mode
   E - estimated (dead-reckoning) mode
   M - manual input mode
   S - simulated mode
   N - data not valid

VTG data

The gps_vtg message contains course and speed (over ground) information. The following fields are returned by the built-in protocol file:

  • talker : Device category, set to "GP".
  • type : Data type, set to "VTG" (Track made good and ground speed).
  • true_course : True course / track made good (degrees).
  • true_course_ref : T (true).
  • mag_course : Magnetic course / track made good (degrees).
  • mag_course_ref : M (magnetic).
  • speed_knots : Ground speed, knots.
  • speed_knots_unit : N (knots).
  • speed_kph : Ground speed, Kilometers per hour.
  • speed_kph_unit : K (kilometers per hour).
  • mode : Same as above.
  • mode_present : The presence of the mode field (0 = absent, 1 = present).
  • csum : Checksum data.


Note Notes:
  • Course refers to the horizontal direction in which a vessel is to be steered or is being steered; the direction of travel through the air or water. Expressed as angular distance from reference North (either true, magnetic, compass, or grid), usually 000° (north), clockwise through 360°. Strictly, the term applies to direction through the air or water, not the direction intended to be made good over the ground. Differs from heading.
  • Course Made Good (CMG) refers to the single resultant direction from a given point of departure to a subsequent position; the direction of the net movement from one point to the other. This often varies from the track caused by inaccuracies in steering, currents, cross-winds, etc. This term is often considered to be synonymous with Track Made Good.

GPS widgets

Icon GPS widgets.png

These widgets can be used to display the GGA or VTG data; they are based on data feed widgets, configured to use the gps_gga and gps_vtg Shared Variables as data source. To use then, simply download the widget and drag & drop the 7-zip file into your Elementi project.

GGA data widget

The GGA data widget displays the following information received from the GPS receiver:

  • Time - UTC time as hours, minutes and seconds (hh:mm:ss)
  • Latitude - as coordinate in degrees, minutes and north-south position
  • Longitude - as coordinate in degrees, minutes and east-west position
  • Altitude - as meters above mean sea level.
  • Satellites - number of satellites being tracked.

VTG data widget

The VTG data widget displays the following information received from the GPS receiver:

  • True course - angular distance (degrees) from true North
  • Magnetic course - angular distance (degrees) from magnetic North
  • Speed - ground speed, both in kilometers per hour and knots

See also

This page was last modified on 4 July 2018, at 18:16.