Android Question Location best way to go

Jose Luis Barajas

Member
Licensed User
Longtime User
Hello Friends

I have reviewed the material relating to the location, only I need the latitude and longitude, I have seen that the GPS library is the best way to go, but I doubt about the battery life.
Other libraries seem confusing to me what I need, and there is a lot of material about the subject, but I have not found the way to go.

Can you help me what is the right way to get the location without much pain?
 

Jose Luis Barajas

Member
Licensed User
Longtime User
Hi Jordi

Thanks for your reply

I was installed the library and test the app.
Also in my android configuration, I get this comment about testing app

Using high battery

This is my concern about this...
 

Attachments

  • Screenshot_2016-06-21-13-49-21.jpg
    Screenshot_2016-06-21-13-49-21.jpg
    320.8 KB · Views: 126
  • Screenshot_2016-06-21-13-49-21.jpg
    Screenshot_2016-06-21-13-49-21.jpg
    320.8 KB · Views: 121
Upvote 0

JordiCP

Expert
Licensed User
Longtime User
Even though I have used it, I am not an expert in this library. Anyway, try to change these lines for something less "aggressive"
B4X:
 LocationRequest1.SetInterval(1000) ' 1000 milliseconds 
LocationRequest1.SetPriority(LocationRequest1.Priority.PRIORITY_HIGH_ACCURACY)
Change the interval and the PRIORITY to a lower level.

Also, if you don't need really high precision, you can also change your Android location settings to "Battery save". It will make use of wifi and phone cells where available to get location
 
Upvote 0
Top