-
public interface CyclingSpeedAndCadenceMeasurementCallback
-
-
Method Summary
Modifier and Type Method Description abstract voidonWheelMeasurementReceived(@NonNull() BluetoothDevice device, @IntRange(from = 0, to = 4294967295L) long wheelRevolutions, @IntRange(from = 0, to = 65535) int lastWheelEventTime)Method called when the data received had wheel revolution data present. abstract voidonCrankMeasurementReceived(@NonNull() BluetoothDevice device, @IntRange(from = 0, to = 65535) int crankRevolutions, @IntRange(from = 0, to = 65535) int lastCrankEventTime)Method called when the data received had crank revolution data present. -
-
Method Detail
-
onWheelMeasurementReceived
abstract void onWheelMeasurementReceived(@NonNull() BluetoothDevice device, @IntRange(from = 0, to = 4294967295L) long wheelRevolutions, @IntRange(from = 0, to = 65535) int lastWheelEventTime)
Method called when the data received had wheel revolution data present.The default implementation calculates the total distance, distance since connection andcurrent speed and calls onDistanceChanged.
- Parameters:
device- the target device.wheelRevolutions- cumulative wheel revolutions since the CSC device was reset (UINT32).lastWheelEventTime- the last wheel event time in 1/1024 s (UINT16).
-
onCrankMeasurementReceived
abstract void onCrankMeasurementReceived(@NonNull() BluetoothDevice device, @IntRange(from = 0, to = 65535) int crankRevolutions, @IntRange(from = 0, to = 65535) int lastCrankEventTime)
Method called when the data received had crank revolution data present.The default implementation calculates the crank cadence and gear ratio andcalls onCrankDataChanged
- Parameters:
device- the target device.crankRevolutions- cumulative crank revolutions since the CSC device was reset (UINT16).lastCrankEventTime- the last crank event time in 1/1024 s (UINT16).
-
-
-
-