I want to find beacon name which detect in telemetry method. But in telemetry or proximity, no any parameter which use for identify beacon major or name.
beaconManager.setLocationListener(new BeaconManager.LocationListener() {
@Override
public void onLocationsFound(List<EstimoteLocation> beacons) {
}
});
and
beaconManager.setTelemetryListener(new BeaconManager.TelemetryListener() {
@Override
public void onTelemetriesFound(List<EstimoteTelemetry> telemetries) {
for (EstimoteTelemetry tlm : telemetries) {
}
}
});
Device name that is configured in the cloud is not advertised by beacon. Telemetry packet is does not contain major/minor but it has unique device ID. Why do you need major/minor from telemetry? Does device ID is not enough to identify device?
We encourage to use new Proximity SDK. This SDK allows you to create JSON style attachments in Cloud and when user enters region you will get that attachment returned. You can store various information there including beacon name. It is using device ID, so you will need to start telemetry scanning and you can match both informations together. Here is a code snippet how to start telemetry scanning in Proximity SDK:
BluetoothScanner bluetoothScanner = new EstimoteBluetoothScannerFactory(context).getSimpleScanner();
scanHandler = bluetoothScanner.estimoteTelemetryFullScan()
.withOnPacketFoundAction(new Function1<EstimoteTelemetryFull, Unit>() {
@Override
public Unit invoke(EstimoteTelemetryFull estimoteTelemetryFull) {
String deviceID= estimoteTelemetryFull.getIdentifier();
return null;
}
})
.withBalancedPowerMode()
.start();
Note: This SDK is in alpha stage, so some things might get changed.
I would avoid using both SDKs for scanning.