Questions tagged [android-fusedlocation]

Synonym for Android Fused Location Provider which intelligently manages the underlying location technology and gives you the best location according to your needs.

Fused location provider:

The Fused Location Provider intelligently manages the underlying location technology and gives you the best location according to your needs.

  • Simple APIs: Lets you specify high-level needs like "high accuracy" or "low power", instead of having to worry about location providers. Immediately available: Gives your apps immediate access to the best, most recent location.

  • Power-efficiency: Minimizes your app's use of power. Based on all incoming location requests and available sensors, fused location provider chooses the most efficient way to meet those needs.

  • Versatility: Meets a wide range of needs, from foreground uses that need highly accurate location to background uses that need periodic location updates with negligible power impact.

Tutorials:

328 questions
1
vote
3 answers

'FusedLocationApi' is deprecated

How to fix deprecation warning exactly for requestLocationUpdates. Android LocationServices.FusedLocationApi deprecated has the answers for it. But I can't understand how to fix it @Override public void onConnected(@Nullable Bundle bundle) { …
shayanmalinda
  • 1,925
  • 3
  • 12
  • 23
1
vote
1 answer

onLocationCallback is not called on Lollipop Emulator with FusedLocationProviderClient

With FusedLocationProviderClient,locationCallback does not get called on Lollipop Emulator. The emulator does not contain GOOGLE Play Services.The POP UP to enable location services pops up and the startLocationUpdates() method is called but the…
1
vote
0 answers

FusedLocationProviderClient sometimes doesn't return the location

I want to make an app in Android Studio which returns the location of the user. This is the code I am using: protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); …
1
vote
1 answer

Not Able To Upgrade Gps settings to high Accuracy using FusedLocationProvider In some devices

I am using SettingsApi and FusedLocationProvider to upgrade Gps settings and getting location updates, I want High accuracy location updates for that I am showing Turn on gps dialog using SettingsApi to upgrade GPS settings to High Accuracy but in…
1
vote
1 answer

FusedLocationProviderClient not returning location

I am using FusedLocationProviderClient to get latitude and longitude on a button click. But when I click the button it shows nothing. Just the app keeps loading for eternity. Can any show me where I am doing wrong in the code? This is the…
Rick
  • 55
  • 1
  • 7
1
vote
3 answers

Getting user current location using fused location provider

I am using google play service location api (fused location provider) to get user current location. In some cases it takes too much time to return the results and sometimes it takes quite less time to return the reslts for the same device. In both…
Shadman Sakib
  • 219
  • 2
  • 10
1
vote
0 answers

FusedLocationAPI Noisy Data cancellation

Need your valuable suggestion for removing noisy locations provided by FusedLocation API using Kalman Filter as per some comment some other which says that GPS itself filter new location with Kalman filter. but there are also some other articles…
1
vote
2 answers

Guarantee that android keeps on retrieving sensor data

I'm developing an app that tracks trips. After searching about this matter, I concluded that the best way to achieve this (continuously track the user's location) is to use a foreground service. In some cases is working quite well, but in some other…
1
vote
1 answer

FusedLocationProvider return null

I used fusedlocation provider client for get device location.But if location setting off my phone and open location setting with locationServices. getSettingsClient fused location provider return null final Task locationTask =…
Ayse Adanç
  • 11
  • 1
  • 3
1
vote
1 answer

Why fusedLocationProviderClient.getLastLocation never call OnSuccessListener?

On kitkat, when i do fusedLocationProviderClient.getLastLocation() .addOnSuccessListener(new OnSuccessListener() { @Override public void onSuccess(Location location) { if (location == null) { Log.w(TAG,…
1
vote
1 answer

how to check if we already call fusedLocationProviderClient.requestLocationUpdates(locationRequest, pendingIndent);

how to check if we already call fusedLocationProviderClient.requestLocationUpdates(locationRequest, pendingIndent); ? because if we call it again then any previously registered requests that have the same PendingIntent (as defined by equals(Object))…
zeus
  • 12,173
  • 9
  • 63
  • 184
1
vote
0 answers

multiple requestLocationUpdates are running

I use fusedLocation API to request location updates. For some reason I start requestLocationUpdates within a background service. As I know there is just one instance of any android service in a system. But every time I call this service using…
Ali Sheikhpour
  • 10,475
  • 5
  • 41
  • 82
1
vote
0 answers

FusedLocationProviderClient and GpsStatus suddenly stopped working

I am using FusedLocationproviderClient to get my current location and GpsStatus.Listener to get the Gps Status using this code: @Override public void onGpsStatusChanged(int i) { switch (i){ case GpsStatus.GPS_EVENT_SATELLITE_STATUS: …
1
vote
0 answers

FusedLocationProviderClient api exception while requisition for location updates coordinates

I am requesting location updates from the FusedLocationApi after granting run time permissions. So when checking for location setting in mSettingsClient?.checkLocationSettings(mLocationSettingsRequest) it always fails and goes to…
1
vote
1 answer

Location updates not working on allowing runtime permission

I've written code for app that shows phone's latitude and longitude and displays it on the screen, but after granting location permission it doesn't show anything, only when I reopen the app. This is the code for the MainActivity: import…
Domin
  • 1,075
  • 1
  • 11
  • 28