GPS是不是在建筑物内部工作 [英] GPS is not working inside the building

查看:155
本文介绍了GPS是不是在建筑物内部工作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

几个小时的房子,外面的测试,当我回到我的房子,我发现GPS已启用,但并没有得到building.Hence内位置修正后的 onLocationChanged 方法不能被调用。

After few hours of testing outside of house, when i came back to my house i found that GPS is enabled but was not getting location fixes inside the building.Hence its onLocationChanged method couldn't get called.

问题:如何知道GPS是没有得到任何位置修复作为设备继续感知尝试模式。通过你的位置,设法模式我的意思是它不来任何情况导致即使在20到30分钟还是它宣布它自身作为启用(在状态栏闪烁)。

Problem: How to know that GPS is not getting any location fixes as device continue to sense your location in "trying mode".By trying mode i mean the situation where it is not coming to any result even after 20 to 30 minutes still it declared it self as enabled (blinking in status bar).

一个人怎么能知道GPS没有得到位置,以便切换到像Network_Provider另一个提供商。

How one could know that the GPS doesn't get location so switch to another provider like Network_Provider.

总之我希望得到我的设备得出结论的东西,GPS可以找到的位置锁定为肯定或者您有通过其他方法采取的位置。

In short i want to get my device to conclude something that GPS can find location fix for sure or you have to take location by another means.

我希望至少有人可以给我关于如何处理这一想法。

I hope at least someone can give me idea about how to deal with that.

推荐答案

下面的链接有一个真棒教程如何从GPS和/或网络位置。

The link below has an awesome tutorial, of how to get the location from GPS and/or Network.

有使用定时器的任务,其中分析是否存在在一个特定的时间周期的GPS位置,假定20秒。如果没有,它将从网络返回的位置作为当前位置。如果存在来自GPS的位置,那么它会比较有更新是新的(最新),并返回。

It uses a timer task, which analyzes if there is a GPS location in a specific period of time, assume 20 seconds. If not, it will return the location from Network as the current location. If there is a location from GPS, then it will compare which update is new (latest), and return that.

<一个href=\"http://stackoverflow.com/questions/3145089/what-is-the-simplest-and-most-robust-way-to-get-the-users-current-location-in-a/3145655#3145655\">What是让Android中用户的当前位置的最简单,最可靠的方法?

这篇关于GPS是不是在建筑物内部工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆