Package com.polar.sdk.api
Class PolarBleApiCallback
-
- All Implemented Interfaces:
-
com.polar.sdk.api.PolarBleApiCallbackProvider
public abstract class PolarBleApiCallback implements PolarBleApiCallbackProvider
Contains the callbacks of the API.
-
-
Constructor Summary
Constructors Constructor Description PolarBleApiCallback()
-
Method Summary
Modifier and Type Method Description Unit
blePowerStateChanged(Boolean powered)
Bluetooth power state of the device where this SDK is running Unit
deviceConnected(PolarDeviceInfo polarDeviceInfo)
Device is now connected Unit
deviceConnecting(PolarDeviceInfo polarDeviceInfo)
Connecting to device Unit
deviceDisconnected(PolarDeviceInfo polarDeviceInfo)
Device is now disconnected Unit
bleSdkFeatureReady(String identifier, PolarBleApi.PolarBleSdkFeature feature)
Called when the feature in connected device is available and it is ready. Unit
disInformationReceived(String identifier, UUID uuid, String value)
DIS information received. Unit
batteryLevelReceived(String identifier, Integer level)
Battery level received. Unit
)>batteryChargingStatusReceived(String identifier, <Error class: unknown class> chargingStatus)
Battery charging status received. Unit
hrNotificationReceived(String identifier, PolarHrData.PolarHrSample data)
HR notification data received from device. -
-
Method Detail
-
blePowerStateChanged
Unit blePowerStateChanged(Boolean powered)
Bluetooth power state of the device where this SDK is running
- Parameters:
powered
- true = Bluetooth power on, false = Bluetooth power off
-
deviceConnected
Unit deviceConnected(PolarDeviceInfo polarDeviceInfo)
Device is now connected
- Parameters:
polarDeviceInfo
- Polar device information
-
deviceConnecting
Unit deviceConnecting(PolarDeviceInfo polarDeviceInfo)
Connecting to device
- Parameters:
polarDeviceInfo
- Polar device information
-
deviceDisconnected
Unit deviceDisconnected(PolarDeviceInfo polarDeviceInfo)
Device is now disconnected
- Parameters:
polarDeviceInfo
- Polar device information
-
bleSdkFeatureReady
Unit bleSdkFeatureReady(String identifier, PolarBleApi.PolarBleSdkFeature feature)
Called when the feature in connected device is available and it is ready. Called only for the features which are specified by PolarBleApi instantiation.
- Parameters:
identifier
- Polar device idfeature
- feature is ready
-
disInformationReceived
Unit disInformationReceived(String identifier, UUID uuid, String value)
DIS information received. Requires feature PolarBleApi.PolarBleSdkFeature.FEATURE_DEVICE_INFO
- Parameters:
identifier
- Polar device id or bt addressuuid
- uuid of dis valuevalue
- dis value for uuid
-
batteryLevelReceived
Unit batteryLevelReceived(String identifier, Integer level)
Battery level received. Requires feature PolarBleApi.PolarBleSdkFeature.FEATURE_BATTERY_INFO
- Parameters:
identifier
- Polar device id or bt addresslevel
- battery level (value between 0-100%)
-
batteryChargingStatusReceived
Unit )>batteryChargingStatusReceived(String identifier, <Error class: unknown class> chargingStatus)
Battery charging status received. Requires feature PolarBleApi.PolarBleSdkFeature.FEATURE_BATTERY_INFO
- Parameters:
identifier
- Polar device id or bt addresschargingStatus
- Charging status ChargeState
-
hrNotificationReceived
Unit hrNotificationReceived(String identifier, PolarHrData.PolarHrSample data)
HR notification data received from device. Notice when using OH1 and PPI measurement is started hr received from this callback is 0.
- Parameters:
identifier
- Polar device id or bt addressdata
- @see polar.com.sdk.api.model.PolarHrData.
-
-
-
-