【发布时间】:2019-04-04 16:03:48
【问题描述】:
我正在尝试从 C++ 代码搜索并连接到广告低功耗蓝牙设备。 我想要一段代码来使用笔记本电脑的无线芯片来发现并连接到 BLE 设备,而不管它们的 GATT 服务如何。 我希望正常使用 GATT 属性(服务、特征、描述符、通知)。
以编程方式
我有来自 Windows API 的 BluetoothLEAdvertisementWatcher Class 文档。
我试图让this example 工作,但没有好的结果。
我也试过this example,但没有成功。
手动
我想通了使用 Windows 10 操作中心,并使用手动配对来连接设备(因为 Windows 会看到并连接我的设备)。
然后我可以直接使用Windows.Devices.Bluetooth.GenericAttributeProfile Namespace
有没有办法自动实现?
【问题讨论】:
标签: c++ windows-10 bluetooth-lowenergy