Reputation: 14658
I tried the Location.getSpeed() method and I tried calculating speed using distance/time. I am using GPS (high accuracy) so I started driving around. The calculated one was way more accurate than the getSpeed one. I am talking driving at 30 Km/hr, the calculated would be like 28 but the getSpeed would be like 8
Is this normal? I thought getSpeed is more accurate but apparently not.
Let me know if I am missing something please
Upvotes: 1
Views: 1050
Reputation: 20410
Location.getSpeed()
returns meters/second, not km/h.
8 m/s is 28.8 km/h, which matches your speed.
http://developer.android.com/reference/android/location/Location.html#getSpeed%28%29
Upvotes: 5