Heart Rate Class
The HeartRate class provides full support for ANT+ heart rate monitors. This profile is specified in the document
ANT+ Managed Network Document – ANT+ Heart Rate Device Profile, Rev 2.5, © 2006-2022 Garmin Canada Inc. All Rights Reserved.
Definition
Namespace: SmallEarthTech.AntPlus.DeviceProfiles
Assembly: SmallEarthTech.AntPlus (in SmallEarthTech.AntPlus.dll) Version: 6.0.4+3bc433b476ad11fc6896cfd0bd783d60504dc315
Assembly: SmallEarthTech.AntPlus (in SmallEarthTech.AntPlus.dll) Version: 6.0.4+3bc433b476ad11fc6896cfd0bd783d60504dc315
C#
public class HeartRate : AntDeviceVB
Public Class HeartRate
Inherits AntDeviceC++
public ref class HeartRate : public AntDeviceF#
type HeartRate =
class
inherit AntDevice
end- Inheritance
- ObservableObject AntDevice HeartRate
Remarks
Due to the ubiquity of heart rate monitors and manufacturers, several problems present themselves with regard to this specification.
This primarily relates to group workout environments (clubs). These issues do not exist for individual workout environments (homes).
Because of the limitations posed by the channel ID it is a distinct possibility that different HRM's will have the same channel ID.
1. There is no guarantee the channel ID is unique to a specific device.
2. There is no guarantee the background page sent is unique to a specific device.
3. RequestCapabilities will be broadcast to all devices with the same channel ID. You may receive multiple contradictory replies.
4. SetSportMode will be broadcast to all devices with the same channel ID. This is not an issue if the invocation is local to the group involved.
Keep these caveats in mind when designing your application. Applications designed for group environments may choose to only attach
to the manufacturer event and ignore other background pages.
Constructors
| HeartRate(ChannelId, IAntChannel, ILoggerHeartRate, TimeoutOptions) | Initializes a new instance of the HeartRate class. |
| HeartRate(ChannelId, IAntChannel, ILoggerHeartRate, Int32) | Initializes a new instance of the HeartRate class. |
Properties
| BatteryStatus | Gets the battery status. |
| Capabilities | Gets the heart rate monitor capabilities. |
| ChannelCount | This is a multiple of the base transmission frequency. All derived classes must implement this property.
See the master Channel Period specified in the specific ANT device specification for the count value. (Overrides AntDeviceChannelCount) |
| ChannelId | Gets the channel identifier. (Inherited from AntDevice) |
| CumulativeOperatingTime | Gets the cumulative operating time. |
| DeviceImageStream | Gets the device image stream from the embedded resource image associated with the derived device class. (Overrides AntDeviceDeviceImageStream) |
| EventType | Gets the type of the heart beat event. |
| HeartRateData | Gets the heart rate data. |
| ManufacturerInfo | Gets the manufacturer information. |
| ManufacturerSpecific | Gets the manufacturer specific data. |
| Offline | Gets a value indicating whether this AntDevice is offline. (Inherited from AntDevice) |
| PreviousHeartBeat | Gets the previous heart beat data. |
| ProductInfo | Gets the product information. |
| SwimInterval | Gets the swim interval data. |
Methods
| Dispose |
Releases the resources used by the current instance of the class.
(Inherited from AntDevice) |
| Parse | Parses the specified data page. (Overrides AntDeviceParse(Byte)) |
| RequestDataPageT | Requests the data page. (Inherited from AntDevice) |
| SendExtAcknowledgedMessage | Sends an acknowledged message to the ANT device. (Inherited from AntDevice) |
| SetHRFeature | Updates the heart rate sensor feature. The HR Feature command page is sent from a display to a heart rate monitor when the display wants to update the enabled status of a HR feature. |
| SetSportMode | Sets the sport mode. |
| ToString |
Returns a string representation of the current derived AntDevice.
(Inherited from AntDevice) |
Events
| DeviceWentOffline | Occurs when no messages have been received from the device within the specified timeout duration. (Inherited from AntDevice) |
Fields
| _logger | The logger for derived classes to use. (Inherited from AntDevice) |
| DeviceClass | The device type value transmitted in the channel ID. |