4
  • Nexus 6 running android 5.0.1
  • Google Play Services version installed on device: 6.7.76
  • Device Settings/Location Mode set to "Device Only"

On the Nexus 6, when using the Fused Location provider with PRIORITY_HIGH_ACCURACY, the Location.getSpeed() usually returns 0. This does not seem to happen with other devices running similar versions of software.

When I switched to LocationManager using the GPS_PROVIDER, speed is now provided on the Nexus 6.

Based on this Q&A It appears that speed is only available through the GPS provider.

  • Can anyone confirm that this is the case (and why)?
  • Is there any way to confirm on the Nexus 6 that the GPS provider is not being used for location in the Fused Location provider and so causing a speed of zero?
  • What is it about the Nexus 6 that causes it to avoid the GPS provider?
  • Considerations for managing Location if speed is important? Should I include logic switching between Google Play Services and LocationManager Location updates?
Community
  • 1
  • 1
Daddyboy
  • 1,412
  • 13
  • 19
  • I am no longer able to reproduce this problem and no idea why. Does GooglePlayServices - Location Services make server side calls? – Daddyboy Mar 17 '15 at 21:48
  • I have no solution, but I have seen this. Returns zero even though there was movement, and 'hasSpeed()' returns true. I have also seen one Android 6.0.1 device that does not return speed at all from the Fused Location provider, while the regular location manager does. But, the Fused Location provider seems to be more accurate and provides more regular updates. So I'm going with the Fused Location provider and calculating my own speeds from the distance and time deltas. – Dave Hubbard Aug 18 '17 at 19:30
  • I think I have a similar problem: https://stackoverflow.com/questions/46661793/fusedlocationproviderclient-requestlocationupdates-not-getting-altitudes – pauminku Oct 10 '17 at 08:18

0 Answers0