我希望将我的桌面计算机服务器作为 Android 设备的键盘。
根据“Android Open Accessory ”协议(protocol),这应该是可能的:
AOA 2.0 allows the accessory to register one or more USB Human Interface Devices (HID)
with an Android device. This approach reverses the direction of communication for
typical USB HID devices like USB mice and keyboards. Normally, the HID device is a
peripheral connected to a USB host like a personal computer. But in the case of the
AOA protocol, the USB host acts as one or more input devices to a USB peripheral.
我宁愿避免实现 AOA 堆栈,是否有任何现有项目可以在 Windows 操作系统上演示上述用例?
如何“反转通信方向”以便注册虚拟 HID 设备?
最佳答案
我已经弄清楚了,最终会将设备切换到配件模式并发送要使用的 HID 报告,然后您只需将带有注册报告 ID 的 HID 消息发送到设备即可。
工作起来就像一个魅力
关于Android模拟HID键盘,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26574707/