[
https://issues.apache.org/jira/browse/CB-5760?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
VinceRafale updated CB-5760:
----------------------------
Description:
Even after following steps here
http://docs.phonegap.com/en/3.1.0/cordova_geolocation_geolocation.md.html#Geolocation,
I never get a GPS fix (Error Code 3, Position retrieval timed out).
# cordova plugin add org.apache.cordova.geolocation
# cordova plugin ls
[ 'org.apache.cordova.geolocation' ]
in AndroidManifest.xml
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission
android:name="android.permission.ACCESS_LOCATION_EXTRA_COMMANDS" />
in app/res/xml/config.xml
<feature name="Geolocation">
<param name="android-package"
value="org.apache.cordova.geolocation.GeoBroker" />
</feature>
It seems that downgrading to 2.9 does the trick.
Please note that with cordova 3.1 and higher geolocation works in genymotion
(when gps enabled) but not on a real device.
So fake positions are correctly interpreted.
Keeping the same html/js code, if the geolocation plugin is removed from the
project (cordova plugin rm org.apache.cordova.geolocation), then the app uses
the webview integrated geolocation.... and then geolocation works as expected.
As a reference... other people also complain of similar issues
http://stackoverflow.com/questions/19567798/cordova-3-1-and-phone-gap-geolocation-fails-with-position-retrieval-timed-out
http://software.techassistbox.com/cordova-android-geolocation-timeout_11.html
http://108.166.42.55/resources/forums/icenium-graphite-/gps-issues-on-phonegap%28ver-=3-00%29-in-android-
http://stackoverflow.com/questions/19521487/phonegap-android-geolocation-is-not-accurate
was:
Even after following steps here
http://docs.phonegap.com/en/3.1.0/cordova_geolocation_geolocation.md.html#Geolocation,
I never get a GPS fix (Error Code 3, Position retrieval timed out).
# cordova plugin add org.apache.cordova.geolocation
# cordova plugin ls
[ 'org.apache.cordova.geolocation' ]
in AndroidManifest.xml
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission
android:name="android.permission.ACCESS_LOCATION_EXTRA_COMMANDS" />
in app/res/xml/config.xml
<feature name="Geolocation">
<param name="android-package"
value="org.apache.cordova.geolocation.GeoBroker" />
</feature>
It seems that downgrading to 2.9 does the trick.
Please note that with cordova 3.1 and higher geolocation works in genymotion
(when gps enabled) but not on a real device.
So fake positions are correctly interpreted.
Keeping the same html/js code, if the geolocation plugin is removed from the
project (cordova plugin rm org.apache.cordova.geolocation), then the app uses
the webview integrated geolocation.... and then geolocation works as expected.
As a reference... other people also complain of similar issues
http://stackoverflow.com/questions/19567798/cordova-3-1-and-phone-gap-geolocation-fails-with-position-retrieval-timed-out
http://software.techassistbox.com/cordova-android-geolocation-timeout_11.html
http://108.166.42.55/resources/forums/icenium-graphite-/gps-issues-on-phonegap%28ver-=3-00%29-in-android-
> Cordova 3.1 or greater Geolocation fails with "Position retrieval timed out"
> ----------------------------------------------------------------------------
>
> Key: CB-5760
> URL: https://issues.apache.org/jira/browse/CB-5760
> Project: Apache Cordova
> Issue Type: Bug
> Components: Android, Plugin Geolocation
> Affects Versions: 3.1.0, 3.2.0, 3.3.0
> Environment: Android
> Reporter: VinceRafale
> Labels: features, geolocation, plugin
>
> Even after following steps here
> http://docs.phonegap.com/en/3.1.0/cordova_geolocation_geolocation.md.html#Geolocation,
> I never get a GPS fix (Error Code 3, Position retrieval timed out).
> # cordova plugin add org.apache.cordova.geolocation
> # cordova plugin ls
> [ 'org.apache.cordova.geolocation' ]
> in AndroidManifest.xml
> <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
> <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
> <uses-permission
> android:name="android.permission.ACCESS_LOCATION_EXTRA_COMMANDS" />
> in app/res/xml/config.xml
> <feature name="Geolocation">
> <param name="android-package"
> value="org.apache.cordova.geolocation.GeoBroker" />
> </feature>
> It seems that downgrading to 2.9 does the trick.
> Please note that with cordova 3.1 and higher geolocation works in genymotion
> (when gps enabled) but not on a real device.
> So fake positions are correctly interpreted.
> Keeping the same html/js code, if the geolocation plugin is removed from the
> project (cordova plugin rm org.apache.cordova.geolocation), then the app uses
> the webview integrated geolocation.... and then geolocation works as expected.
> As a reference... other people also complain of similar issues
> http://stackoverflow.com/questions/19567798/cordova-3-1-and-phone-gap-geolocation-fails-with-position-retrieval-timed-out
> http://software.techassistbox.com/cordova-android-geolocation-timeout_11.html
> http://108.166.42.55/resources/forums/icenium-graphite-/gps-issues-on-phonegap%28ver-=3-00%29-in-android-
> http://stackoverflow.com/questions/19521487/phonegap-android-geolocation-is-not-accurate
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)