【问题标题】:Emulate a Bluetooth keyboard on Mac在 Mac 上模拟蓝牙键盘
【发布时间】:2022-01-08 06:05:38
【问题描述】:

我正在尝试为 mac 构建一个可以将 mac 模拟到蓝牙键盘的应用程序。 在阅读了《HID over GATT Profile 1.0》 和其他Bluetooth document 之后,我尝试使用Apple 的Core Bluetooth 框架来做到这一点。但打电话后 myPeripheralManager.add(hid_service)我收到一条错误消息:

Error Domain=CBErrorDomain Code=8 "The specified UUID is not allowed for this operation." UserInfo={NSLocalizedDescription=The specified UUID is not allowed for this operation.}

服务的 UUID 是:

  • 隐藏服务:0x1812
  • 设备信息服务:0x180A
  • 电池服务:0x180F

Apple 似乎确实阻止 HID 服务在作为外围设备的 Mac 上运行。

但是像 Key Pad 这样的一些应用实际上可以在 mac 上做到这一点。

有什么办法可以绕过苹果的限制?

【问题讨论】:

    标签: macos keyboard bluetooth-lowenergy core-bluetooth hid


    【解决方案1】:

    KeyPad 模拟的是传统蓝牙 HID 设备,而不是 BLE。 Apple 不允许在 Mac/iPhone 上使用 BLE HID。

    【讨论】:

      猜你喜欢
      • 2011-12-17
      • 2017-05-09
      • 2016-12-06
      • 2020-07-25
      • 1970-01-01
      • 2023-02-13
      • 1970-01-01
      • 2012-10-14
      • 1970-01-01
      相关资源
      最近更新 更多