Questions tagged [android-geofence]

Represents a geographical region, also known as a geofence.

Geofences can be monitored by geofencer service. And when the user crosses the boundary of a geofence, an alert will be generated.

As currently implemented, in the Google Play Services API, geofences are circular, defined using coordinates (lat, long) and radius.

Documentation

563 questions
0
votes
3 answers

Android: Trigger an event when the user exits a geofence

Is there a way to define a geofence (center and radius) around the device's current location, and have the system trigger a callback function in my app when the device exits the geofence? I would like to avoid extensive GPS usage, so I would prefer…
Adam Matan
  • 128,757
  • 147
  • 397
  • 562
0
votes
1 answer

create android geofence in background without crashing

I currently have an IntentService that receives gcm messages with lat,lng infos and I would like to register a geofence in the background without a foreground app. I already tried putting the working (in an activity) code into the IntentService but…
user938541
0
votes
2 answers

Android Geofence addGeofences

I have a problem with geofencing in Android. I follow the instructions of https://developer.android.com/training/location/geofencing.html I build the list of geofence, I connect with LocationClient and it works and it returns the connection, I can…
user1852854
  • 199
  • 1
  • 1
  • 11
0
votes
1 answer

Two classes overriding same method

I am trying to detect Geofences, and this requires the onConnected() function in the ConnectionCallBacks interface. However I also use this interface in a fragment (separate class), and override the onConnected() method there as well. Is it possible…
0
votes
2 answers

Algorithm for Creating user Defined Geofences

I've got a latitude & longitude of a point. I want all the readings of latitude & longitude within a radius of 500M with respect to that given point. Is any method for that? Is it possible? Is there any algorithm for it?
0
votes
1 answer

Dynamic geofence and google maps Android app

I am asking advice on the best way to create a geofence application for android application using google maps. I have looked at the sample code given on the android documentation but I am not sure if this satisfys what I wish to do. Basically I wish…
Natalie Carr
  • 3,707
  • 3
  • 34
  • 68
0
votes
1 answer

Google GeofenceDetection example crashing

I am trying to run the code (GeofenceDetection.zip) at: The app keeps crashing in the emulator and also a real phone (Galaxy S3). All I am doing is - downloading the code, adding google play services as Library and then building it with Android…
user1406716
  • 9,565
  • 22
  • 96
  • 151
0
votes
1 answer

Can a phone have its own geofence

I understand a place (like a business) can set up a geofence through which phones pass. My question is, can a PHONE have its own geofence (always moving, geographically, as the phone moves, with the phone at the center of the geofence area) through…
0
votes
2 answers

Sending and receiving broadcast from the same receiver

Hello I was trying to implement a custom Broadcast receiver for my Geofence app. I just went through the solution given here But I found that he is sending the broadcast from the receiver class which receives the same broadcast. can someone please…
Droidme
  • 1,223
  • 6
  • 25
  • 45
0
votes
2 answers

Geofence on current user location

I am currently studying a possible project on Android and iPhone. I need to know if geofences could help me, or if another method should be used. I think the geofence are not used in this way but I ask anyway. Is it possible to place a geofence on…
user1106464
  • 111
  • 11
0
votes
1 answer

Removing and adding geofences in android after having a location update in PendingIntent

I am developing an android application that makes use of new android geofencing API and I want to register more than 100 Geofences. I'm having an update to my location in the background every 1 minute, and onHandleIntent method in the IntentService…
HEH
  • 305
  • 6
  • 15
0
votes
1 answer

Do I need to register my android app in API console to use Geofences?

I've tried setting up both my app and an Android sample app to use Google Play Services SDK, and I get NoClassDefFoundErrors when I run the apps on a device. I've done and re-done the proper steps to add the SDK as a library. The only thing my…
ageektrapped
  • 14,482
  • 7
  • 57
  • 72
0
votes
1 answer

when handleGeofenceTransition() gets called in geofence example?

I am developing android geofence app which released this year in google I/O.I am passing users current location lat-lon to geofence with diffrent radius like 2,5,10,50..etc but I am not able to get notification.I don't know what is the problem but…
0
votes
3 answers

What is the most battery-efficient way of monitoring proximity to a number of locations in Android?

I have an app which will take some (internet) action every time the user approaches any one of a set of locations (for example, let's say it notifies a server whenever I am near a Starbucks shop, so my coffee habits can be analysed). What's the most…
Richard Russell
  • 1,105
  • 1
  • 10
  • 19
-1
votes
1 answer

How to add title on GeoFence circle in google maps?

I am working on Geofence in the android google map. I am able to add GeoFence in Map. I need to add a title of Geofence within the circle or bottom of the circle. I don't want to add a title on Marker. map.addCircle(CircleOptions() …
Amit kumar
  • 149
  • 14