2

i've recently created a GPS Location Service which uses FusedLocationProviderAPI from GooglePlayServiceAPI. Everything is working fine except receiving coordinates without an enabled internet connection.

I did a lot of research why this isn't working without an internet connection and i still don't know why. When I am connected to my Wifi it is working fine and the location is being updated perfectly. But when I restart my device and disable wifi and mobile internet it isn't working anymore. When I start the location updates while I am connected to the internet and disable my internet connection the location update is still working. Somehow, it changes then from the internet provider to GPS provider.

Am I doing anything wrong or is it a bug that I am not able to get coordinates without an internet connection.

Aurelius Schnitzler
  • 511
  • 2
  • 8
  • 18
Makky227
  • 91
  • 1
  • 6
  • Maybe the initial connection to Google Play Services fails and is not retried afterwards, hence no location updates. Is my best bet to where the issue might be. – cYrixmorten Jul 05 '15 at 17:20
  • No i have already checked that. it always says connected. And i asked a friend to test my app and it worked for him without mobile internet or wifi. So i guess the problem is my physical device :/ – Makky227 Jul 05 '15 at 17:57
  • Might be, hard to tell. I have noticed that some devices acts strange. For instance a cheap LG that I am testing with does not get Activity Recognition updates when screen is turned of. No matter if moved to service, adding wakelock, etc.. It simply seems to ignore background processes when screen is off – cYrixmorten Jul 05 '15 at 18:01
  • By the way I am happy to use https://github.com/mcharmas/Android-ReactiveLocation, also contributed with activity recognition to the project. It is worth a try and gives you fused location with a few lines of code. – cYrixmorten Jul 05 '15 at 18:04
  • yeah sad but true. I will ask other friends with android devices. Then i will see whether it is working or not. So thank you for your interest and you suggestions ;) [EDIT]: Thanks i will look into it. – Makky227 Jul 05 '15 at 18:06
  • have you found any solution for this – M.Yogeshwaran Mar 22 '17 at 09:46

0 Answers0