I have this code:
private void setupProximity() {
Intent intent = new Intent(this, PlacesProximityHandlerService.class);
intent.setAction("PlacesProximityHandlerService");
intent.putExtra("lat", objPlace.getLat());
intent.putExtra("lon", objPlace.getLon());
intent.putExtra("error_m", objPlace.getError()+ALERT_RANGE_IN_METERS);
PendingIntent sender=PendingIntent.getBroadcast(this, 0, intent, 0);
LocationUtils.addProximity(this, objPlace.getLat(), objPlace.getLon(),objPlace.getError()+ALERT_RANGE_IN_METERS, -1, sender);
}
public static void addProximity(Context ctx,double lat, double lon, float rad,long exp, PendingIntent pintent) {
LocationManager lm = (LocationManager) ctx.getSystemService(Context.LOCATION_SERVICE);
lm.addProximityAlert(lat, lon, rad, exp, pintent);
}
Why I don't get the class to fire up? I am in the range of the zone