【发布时间】:2018-10-11 01:51:05
【问题描述】:
我正在尝试检测我拥有的自行车功率计。我使用应用程序 LightBlue 来确定功率计的服务 UUID,即 E9410100-B434-446B-B5CC-36592FC4C724。
但是当我使用 CBCentralManager 发现具有此 UUID 的设备时,什么都没有发现:
manager?.scanForPeripherals(withServices: [CBUUID(string: "E9410100-B434-446B-B5CC-36592FC4C724")], options: nil)
我应该使用这个 UUID 的缩短版本吗?
【问题讨论】:
-
您能否也展示您的 LightBlue 屏幕截图和您实现的
CBCentralManagerDelegate?它可以扫描其他设备吗?如果您使用withServices: nil,它可以扫描您的骑行功率计吗?
标签: ios swift bluetooth-lowenergy