Reference Guide

Refer to Google documentation for information on how to request permission https://
developer.android.com/training/permissions/requesting.
Note
The ExtremeLocation Android SDK will not function without this permission and may respond
with an error upon calling the init function().
Initializing the SDK
You need to have an instance of the FootmarksAPI class to interact with the ExtremeLocation SDK. It
is obtained by calling a static method to initialize the SDK.
mFootmarksAPI = FootmarksAPI.init(context, APP_KEY, APP_SECRET, new
FootmarksAPI.InitCallback() {
@Override
public void onError(FootmarksSdkError footmarksSdkError) {
Log.w(TAG, String.format("Error %1$s: %2$s",
footmarksSdkError.getError().toString(), footmarksSdkError.getMessage()));
switch (footmarksSdkError.getError()) {
// You can do different actions depending on error type
case LOCATION_PERMISSION_NOT_ENABLED:
break;
case BLUETOOTH_NOT_ON:
break;
case BLE_NOT_SUPPORTED:
break;
case APPKEY_MISSING:
break;
case APPSECRET_MISSING:
break;
case LOGIN_ERROR:
break;
}
}
@Override
public void onSuccess() {
// API is initialized");
// This is a good place to call startScan
}
});
Note
APP_KEY and APP_SECRET can be obtained from https://manage.extremelocation.com. If
initialization fails, the onError callback will be called with error information and type. If the
call succeeds, onSuccess will be called. The FootmarksAPI instance can then be used to
start and stop scanning and to set callbacks for beacon and location related events.
Scanning
The SDK is ready to scan for beacons, Nfc tags, Geofences, and return experiences after the successful
call to init(). To start scanning, call startScan().
This will display a notiļ¬cation about the application in the system status bar. On latest android versions,
8 and higher, this is the only way to make sure the application can detect beacons in the background.
ExtremeLocation Android SDK
ExtremeLocation Android SDK Reference Guide for version 3.1.0 8