OnLocationChanged is not always called according to setFastestInterval() value. I have set 1 minute for fastestInterval. But OnLocationChanged sometimes called after 2-3 minutes. I have checked this, while i was in moving state with my phone.
Below code & link I have tried, but didn't get any suitable solution. Is there any more suitable solution for this problem?
Please see my code snippet below:-
private var mLocationProvider: FusedLocationProviderApi? = null
mLocationProvider = LocationServices.FusedLocationApi
mLocationRequest = LocationRequest()
mLocationRequest!!.interval = 1000 * 60 * 1 // 1 min
mLocationRequest!!.fastestInterval = 1000 * 60 * 1 // 1 min
mLocationRequest!!.priority = LocationRequest.PRIORITY_HIGH_ACCURACY