Access NMEA from an on-board GNSS receiver

80
0
a month ago
Esri Regular Contributor
1 0 80

Sometimes it's not enough to get just the longitude and latitude of a location displayed in your app, and you need to additionally record metadata about the location value. For example, you may also need to record errors in longitude and latitude values, differential age, and the number of satellites in use when the location was captured. To do this you must receive NMEA sentences from your location sensor into your app. When using an external GNSS receiver, this is a given – it’s the only way to work with an external receiver – but when your high precision GNSS receiver is built into your device, you need to specifically connect to those NMEA messages, to get this information. 

I recently tested with the DT Research DT301X-TR, a rugged windows tablet to get this working, but the principle described here would apply to any Windows or Android tablet that has an on-board GNSS receiver that can output NMEA sentences. 

The following discussion is also relevant to all apps built with AppStudio  I may reference Survey123 and QuickCapture, but any app you build with AppStudio can access NMEA from on-board GNSS receivers too. 

On all hardware that is compatible with these apps, you can read location information via the device's integrated location provider. Each operating system uses a similar concept, providing location coordinates and some level of accuracy information to any app that is running on the device. In our apps, this is the default location connection. The provider list typically looks like this by default. 

When you connect this way, you generally receive data for: latitude, longitude, altitude, horizontal and vertical accuracies, speed and direction. 

Even in the case of external GNSS receivers, some manufacturers have provided ways for you to receive location information from their hardware through the integrated location provider. Typically, you install the manufacturers own app on your device, that app performs calculations to improve accuracy, and then the corrected latitude and longitudes are passed on to all other apps on the device. If you don’t need to record the additional metadata in your app of choice, then this may be all you need. 

Additional data that can be collected directly from NMEA messages include: magnetic variation, geoid separation, latitude and longitude errors, HDOP, VDOP, PDOP, differential age, reference station id’s, and the number of satellites visible and in use. For a full list of metadata that can be used in an app see the Position component in the API Reference. 

If you need to record additional information that is provided by an on-board GNSS receiver via NMEA sentences, you must make a serial connection to that receiver. Windows and Android can present GNSS hardware as COM ports – if the manufacturer provides access to these ports for the GNSS receiver, you can connect directly to the receiver in your ArcGIS app. 

To add a serial connection, choose to add a location provider of type USB. From the list, choose the correct COM port, and see the connection in the app. 

Figuring out which COM port to choose, can be tricky, and trial and error is a common tactic.  With built in receivers, the port number should be fixed and be provided by the hardware manufacturer. On Windows, you can attach and detach USB devices readily, so you may have many more COM ports listed. Viewing the list of Ports in Control Panel > Device Manager may list an identifiable name against each port number. Alternatively, ports that are occupied by Bluetooth devices can be identified in the More Bluetooth Options dialog in the Bluetooth Settings page, for elimination. 

Once connected, all available data will be displayed in the app, and depending on the functionality of the app, can be saved to records that you capture in the app. 

For more information on working with GNSS receivers in different apps @@@see