I was developing androidProgramWhen calling GPS, they all use functions directly.
Public void Requestlocationupdates (Long mintime, float mindistance, Criteria, pendingintent intent)
However, the customer recently said that the GPS of the mobile phone is not accurate enough, so he learned about the two parameters in the function signature from the Google developer website. If there is any inaccuracy, please correct them as follows ):
- Mintime: the shortest time for the application to receive GPS updates (that is, only when this time limit is exceeded can the system notify our program to say "GPS"-unit: milliseconds
- Mindistance: the shortest distance for the application to receive GPS updates (that is, the system can only notify our program to update GPS data)-In meters
Note 1: When both conditions are set (neither is 0), the application must be notified only when both conditions are met. . NOTE 2: Since the GPS module consumes a lot of power for a long time, we recommend that you set mintime to a longer value (especially the background thread) for all Android devices within the permitted range)
See the original article:
Http://developer.android.com/reference/android/location/LocationManager.html#requestLocationUpdates (long, float, Android. Location. Criteria, Android. App. pendingintent)