Skip to content

BLEHeartRateDevice

A Bluetooth Low Energy (BLE) device which implements a GATT Heart Rate service (https://www.bluetooth.com/specifications/gatt/services/).

A connected device providing CarpDataTypes.HEART_RATE, CarpDataTypes.INTERBEAT_INTERVAL and CarpDataTypes.SENSOR_SKIN_CONTACT data. Optional by default. Registered with a MACAddressDeviceRegistration.

Inheritance
Annotations

Constructors

BLEHeartRateDevice.fromJson

BLEHeartRateDevice.fromJson(
  1. Map<String, dynamic> json
)

BLEHeartRateDevice

BLEHeartRateDevice({
  1. required String roleName,
  2. bool? isOptional = true,
})

Properties

dataTypeSamplingSchemes

DataTypeSamplingSchemeMap? get dataTypeSamplingSchemes
override

Sampling schemes for all the sensors available on this device.

Implementations of DeviceConfiguration should return a map of all supported sampling schemes here. Null in this base class.

fromJsonFunction

Function get fromJsonFunction
override

The function which can convert a JSON string to an object of this type.

Methods

createRegistration

MACAddressDeviceRegistration createRegistration({
  1. String? deviceId,
  2. String? deviceDisplayName,
  3. DateTime? registrationCreatedOn,
  4. String? address,
})
override

Create a DeviceRegistration which can be used to configure this device for deployment.

Override this method to configure device-specific registration options, if any.

toJson

Map<String, dynamic> toJson()
override

Return a JSON encoding of this object.