android中的GPS_PROVIDER或NETWORK_PROVIDER的位置不一致 [英] Location from GPS_PROVIDER or NETWORK_PROVIDER in android is not consistent
问题描述
使用
服务
,以便只要应用程序正在运行位置
可以被检索 我面临的问题
- 即使我在相同的位置很长时间,每次
纬度,
经度
不同的准确性
等级 - 因此,即使用户没有更改他的位置,如果我正在绘制
GoogleMap
中的Location
,它使得我的缩放级别变得非常接近18.0f
-
mGoogleMap.animateCamera(CameraUpdateFactory.newLatLngZoom (currentLatLon,18.0f));
我尝试了 stackove rflow Link One 和计算器链接两个
但即使我坐在相同的位置,并定期检索位置,纬度和经度差异是这样的, 在每次经过结束时查看突出显示的值:
纬度:12.8379 283 长:经度:77.6647 266
纬度:12.8379 233 长:经度:77.6647 368
纬度:12.8379 285 长:经度:77.6647 506 纬度:12.8379 245 长:经度:77.6647 546 但仍然每次 GPS的精确度并不是绝对的,所以即使是静态设备也会在连续读数中显示不同位置。请尝试以下操作: What I am trying to do Problem I am facing I have tried approaches mentioned in stackoverflow Link One and stackoverflow Link Two Latitude: 12.8379283 Long: Longitude: 77.6647266 Latitude: 12.8379233 Long: Longitude: 77.6647368 Latitude: 12.8379285 Long: Longitude: 77.6647506 Latitude: 12.8379245 Long: Longitude: 77.6647546 but still every time the The accuracy of the GPS is not absolute, so even a static device will show different locations in successive readings. Try the following:
这篇关于android中的GPS_PROVIDER或NETWORK_PROVIDER的位置不一致的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
精度
不同,Lat Lon略有变化。
由于我的代码试验与链接中提到的完全相同,我不只是在这里复制粘贴。这将得到解决
Service
so that as long as application is running Location
can be retrieved
Latitude
, Longitude
changes with different Accuracy
levelsLocation
in GoogleMap
it makes jump to very near by places being my zoom level 18.0f
mGoogleMap.animateCamera(CameraUpdateFactory.newLatLngZoom(currentLatLon, 18.0f));
But even though I am sitting in the same location and retrieving location in regular interval, the Lat and Lon differs like this , see the highlighted values at end of every lat lon:
Accuracy
differs and Lat Lon slightly changes.
As my code trials are exactly same as mentioned in link's I am not just copy pasting here. How can this be resolved