admin管理员组文章数量:1406926
I am developing an utility which needs to match tapped CGEvents to the USB device that originated them (a touchscreen, specifically).
I got to the point where I can get the Service Registry ID from the CGEvent and the Device Registry ID from the USB device. To put this in other words, if i use the hidutil list
command in terminal this are the two entries that i have (cut for brevity):
Services:
VendorID ProductID LocationID UsagePage Usage RegistryID Transport Class Product UserClass Built-In
0x27c6 0x529 0x2111000 1 2 0x100026c93 USB AppleUserHIDEventService TouchScreen AppleUserHIDEventDriver 0
Devices:
VendorID ProductID LocationID UsagePage Usage RegistryID Transport Class Product UserClass Built-In
0x27c6 0x529 0x2111000 65280 255 0x100026c85 USB AppleUserHIDDevice TouchScreen AppleUserUSBHostHIDDevice 0
How can i match this 0x100026c93
to this 0x100026c85
?
本文标签: swiftMatching service registry IDs to device registry IDStack Overflow
版权声明:本文标题:swift - Matching service registry IDs to device registry ID - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744356762a2602342.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论