Hi everybody,
I’m having some issues with beacons on Android 6 and 7.
On Android 6, when I start ranging beacons, method onBeaconsDiscovered returns me always an empty list.
On Android 7 instead, when I start ranging beacons, method onBeaconsDiscovered is not even triggered.
I checked every permission in my Activity, every permission is granted.
int permissionCheck1 = ContextCompat.checkSelfPermission(this,
Manifest.permission.ACCESS_COARSE_LOCATION);
int permissionCheck2 = ContextCompat.checkSelfPermission(this,
Manifest.permission.ACCESS_FINE_LOCATION);
int permissionCheck3 = ContextCompat.checkSelfPermission(this,
Manifest.permission.BLUETOOTH);
int permissionCheck4 = ContextCompat.checkSelfPermission(this,
Manifest.permission.BLUETOOTH_ADMIN);
I’m even using
SystemRequirementsChecker.checkWithDefaultDialogs(this);
to check every permissions with Estimote SDK, it returns me always true.
Estimote’s logs are the following:
I/EstimoteSDK: BeaconService.onCreate:79 Creating beacon service for android version 23
D/EstimoteSDK: BeaconService.setForegroundScanPeriod:151 Setting foreground scan period: ScanPeriodData{scanPeriodMillis=3000, waitTimeMillis=1000}
D/EstimoteSDK: BeaconService.setBackgroundScanPeriod:156 Setting background scan period: ScanPeriodData{scanPeriodMillis=3000, waitTimeMillis=1000}
I/EstimoteSDK: BeaconService.onCreate:79 Creating beacon service for android version 22
D/EstimoteSDK: BeaconService.setForegroundScanPeriod:151 Setting foreground scan period: ScanPeriodData{scanPeriodMillis=3000, waitTimeMillis=1000}
D/EstimoteSDK: BeaconService.setBackgroundScanPeriod:156 Setting background scan period: ScanPeriodData{scanPeriodMillis=3000, waitTimeMillis=1000}
On Android < 6, it works fine.
I’m using version
compile 'com.estimote:sdk:1.1.0'
Thanks,
Giulio.