Select to view content in your preferred language

GeoCoordinateWatcher vs. LocationDisplay

3894
4
Jump to solution
01-19-2016 12:23 PM
JimFiddes
Regular Contributor

Hi Everyone

Two questions here. I'm just wiring up our runtime map to display a gps location and I'm wondering if there are benefits to using either of these items. Yes I know one immediate benefit to LocationDisplay is the direct link to the map and very little work required. When I look at the .Net Watcher, it has some properties of interest (DesiredAccuracy and MovementThreshold). I would assume ESRI would piggy back off this seeing it takes a .net LocationProvider; however there properties are not accessible.

Second question is in regards to the device itself and being connected to a GPS hardware (external modem...). When using either of these objects above, can someone help educate me on how to make the device aware it is connected to a GPS source and is location aware? For internal testing I use a Garmin puck (with USB) and Franson GpsGate to get a virtual com port. Our older ArcEngine map used a 3rd party software to listen to a specified com port with a defined baud rate to understand the incoming signal and fire off a position changed event.

If these questions seem to simple or obvious, my appologies, the Runtime world still feels new as I've lived in ArcGIS Engine for 10 years.

Cheers,

Jim

Tags (2)
0 Kudos
1 Solution

Accepted Solutions
AnttiKajanus1
Deactivated User

We have some demos that we have done using external devices like this one but this question should be targeted to the companies that provides the devices and tools to use them.

https://github.com/Esri/arcgis-runtime-demos-dotnet/tree/master/src/ExternalNmeaGPS 

View solution in original post

0 Kudos
4 Replies
AnttiKajanus1
Deactivated User

Hi,

LocationDisplay is designed to control the view where LocationProviders are used to encapsulate the usage of the GPS. We provide default implementation called SystemLocationProvider and, as you are saying, it seems that we don't expose those properties to the user. We default to PositionAccuracy.High, MovementThreshold = 0 and ReportInterval = 1000. I have put note to myself to check if we can expose properties to control the settings in the future.

That said, location provider implements ILocationProvider interface that is responsible to provide location and updates to the LocationDisplay and it is very easy to write your own. This is the recommended way to provide location tracking for the runtime applications (when default provider is not enough). If you haven't looked yet LocationDisplay sample, that shows how to implement one.​ From LocationDisplays point of view, it doesn't really care where the location actually comes from so when you implement custom ILocationProvider, you can use 3rd party libraries to communicate with the device if you aren't keen to write that part yourself. 

Hope this helps.

0 Kudos
JimFiddes
Regular Contributor

I've been searching the net and can't find any clear topics on how to make a laptop location aware from an external GPS puck (software). If I take a Garmin USB puck (as an example) and hook it to my laptop, is there any documentation on how to make the operating system aware that location data is available and to consume it?

0 Kudos
AnttiKajanus1
Deactivated User

We have some demos that we have done using external devices like this one but this question should be targeted to the companies that provides the devices and tools to use them.

https://github.com/Esri/arcgis-runtime-demos-dotnet/tree/master/src/ExternalNmeaGPS 

0 Kudos
JimFiddes
Regular Contributor

Thanks, I believe I know what I need to do. Continue to use my 3rd party GPS dll and create a custom ILocationProvider.

Thanks

Jim

0 Kudos