Does Android ProximityAlert or Geofence increase battery life when the phone is closer to a controlled location?

If I use Android ProximityAlert with a given radius (say, 100 m), and my phone is regularly near (or in) in this place, will there be more battery leakage than if I rarely were near this place? Is there a distance at which battery consumption increases?

What about Geofences instead?

Ideally, I would like to understand the impact of the battery life of the following scenarios:

R = radius of proximity or geofence D = distance of the phone from a location in proximity

  • D <R (the phone is definitely in the proximity alert area)
  • D → R (the phone is separate from the location of the proximity alert)
  • D ~ = R (phone near the border of the proximity warning location)

Is there any specific location (i.e. D or DR value) where the phone will automatically change the location provider to a more expensive option to improve accuracy?

+7
source share
2 answers

When you get close to geofence, GPS turns on more often to check FINE_LOCATION users, and when you are not close to a controlled location, the phone uses COARSE_LOCATION, which uses cell phone towers and 3G / 4g networks to get the current location of the phones. FINE_LOCATION (GPS required) will drain more battery than COARSE_LOCATION.

this is why we need to set both COARSE_LOCATION and FINE_LOCATIONS in the Android manifest.

0
source

The proximity alert launches gps if it is turned off every 4 minutes to update your location. you may not be aware of this, but add something to your tests, add a broadcast receiver to constantly monitor the status of gps, and then check it for a 4-minute period

-one
source

All Articles