Different GPS Location Reading Of Same Physical Location on Windows Phone GeoCoordinateWatcher

末鹿安然 提交于 2019-12-06 20:47:46

This shows a really bad GPS device. You get a jump of 570m, this should never be the case for GPS signals. Make sure that the location was got only from GPS (on android and ios if you do not care, positions may also come from cell Tower of wifi location service). Check also the timestamp of the first location, and compare it with system time, just to make sure it is not an old location which was cached.

It is normal for GPS when you are standing that coordinates move up to 30m. Therfore some smartphone manufacteres enables a "stand still" filter. It seems that you have to write your own "stand still" filter.

Simplest is to read the location.getSpeed(): if it is more then 5km/h take the position, otherwise ignore it. (This works well for vehicles but not for walking)

And also important, sittzing on your desk near a window you have the worst possible Gps signals. better go out for test.

Pete Stensønes

I think your Threshold setting is a "Red Herring". Your threshold of 2 means "don't report to me unless I move more than 2m from the previous reading." That is what you are seeing. The Threshold setting is not the issue or solution.

As AlexWien suggests you may not be getting location based just on GPS, to ensure GPS only you need to set the DesiredAccuracy property of your GeoCoordinateWatcher to High.

If the issue still persists (and it will but hopefully to a lesser extent) then I would suggest it is about the quality of the GPS fix. Perhaps you should check the HorizontalAccuracy and VerticalAccuracy values of the GeoCoordinate in the PostionChanged EventArgs.

A high value for these indicates a "poor" GPS fix (10 for example indicates the coordinate is +/-10m from the given value). Perhaps the phone can only see 3 satellites or the ones it sees are all in a similar patch of the sky. All these things degrade fix accuracy. If you want to track with high accuracy you should consider rejecting values with insufficent accuracy for your needs.

I Just captured logs from one of my GPS aware WP8 apps (in glorious Hull) and got this raw data:

time 05/02/2014 18:38:05 +00:00 spd 0.75 coords 53.7589650973678, -0.365797486156225 [err 21, 48]
time 05/02/2014 18:38:07 +00:00 spd 0.25 coords 53.7589640915394, -0.36607475951314 [err 10, 24]
time 05/02/2014 18:38:08 +00:00 spd 0 coords 53.7589303962886, -0.366103509441018 [err 10, 24]
time 05/02/2014 18:38:09 +00:00 spd 0 coords 53.7589660193771, -0.365918939933181 [err 11, 24]
time 05/02/2014 18:38:10 +00:00 spd 0 coords 53.7590100243688, -0.365963699296117 [err 16, 32]

As you can see whilst stationary I get accuracies in the 10-30m range and speeds in the 0-0.75mps range. Use this to filter out position updates that are just GPS noise.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!