ThinkMeta.Devices.Bluetooth.HeartRate
0.1.0
dotnet add package ThinkMeta.Devices.Bluetooth.HeartRate --version 0.1.0
NuGet\Install-Package ThinkMeta.Devices.Bluetooth.HeartRate -Version 0.1.0
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="ThinkMeta.Devices.Bluetooth.HeartRate" Version="0.1.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="ThinkMeta.Devices.Bluetooth.HeartRate" Version="0.1.0" />
<PackageReference Include="ThinkMeta.Devices.Bluetooth.HeartRate" />
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add ThinkMeta.Devices.Bluetooth.HeartRate --version 0.1.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: ThinkMeta.Devices.Bluetooth.HeartRate, 0.1.0"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package ThinkMeta.Devices.Bluetooth.HeartRate@0.1.0
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=ThinkMeta.Devices.Bluetooth.HeartRate&version=0.1.0
#tool nuget:?package=ThinkMeta.Devices.Bluetooth.HeartRate&version=0.1.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
ThinkMeta.Devices.Bluetooth
ThinkMeta.Devices.Bluetooth is a .NET library for discovering, connecting to, and interacting with Bluetooth fitness and heart rate devices. It provides high-level APIs for scanning, connecting, and controlling devices such as treadmills (FTMS) and heart rate monitors.
Features
- Scan for Bluetooth FTMS fitness machines (e.g., treadmills)
- Scan for Bluetooth heart rate monitors
- Connect to discovered devices
- Receive real-time data (e.g., speed, distance, heart rate)
- Control supported fitness machines (e.g., set treadmill speed)
Getting Started
Add the library to your .NET project and use the provided device scanner and device classes to interact with Bluetooth devices.
Example: Scan and Control a Treadmill (FTMS)
var scanner = new FitnessDeviceScanner();
var discoveredDevices = new List<FitnessMachineAdvertisementInfo>();
scanner.DeviceDiscovered += deviceObj => {
if (deviceObj is FitnessMachineAdvertisementInfo device) {
// Add device to list and display info
}
};
scanner.StartScanning();
// Wait for user input, then stop scanning
scanner.StopScanning();
// Connect to a selected device
var treadmill = await FitnessDevice.ConnectAsync(selectedDevice.BluetoothAddress);
treadmill.TreadmillDataChanged += (sender, data) => {
// Handle treadmill data (speed, distance, etc.)
};
await treadmill.RequestControlAsync();
await treadmill.SetTargetSpeedAsync(1000); // Set speed to 10.00 km/h
Example: Scan and Connect to a Heart Rate Monitor
var scanner = new HeartRateMonitorDeviceScanner();
var discoveredDevices = new List<AdvertisementInfo>();
scanner.DeviceDiscovered += device => {
// Add device to list and display info
};
scanner.StartScanning();
// Wait for user input, then stop scanning
scanner.StopScanning();
// Connect to a selected device
var monitor = await HeartRateMonitorDevice.ConnectAsync(selectedDevice.BluetoothAddress);
monitor.HeartRateMeasurementReceived += hr => Console.WriteLine($"Heart Rate: {hr} bpm");
Requirements
- .NET 10 or later
- Bluetooth adapter supported by your platform
License
See LICENSE for details.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0-windows10.0.19041 is compatible. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net10.0-windows10.0.19041
- ThinkMeta.Devices.Bluetooth.Core (>= 0.1.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.1.0 | 79 | 1/15/2026 |
Initial release of the Bluetooth heart rate monitor library.