如何从注册表中找到蓝牙低功耗HID设备的唯一ID? [英] How to find unique ID of a Bluetooth Low Energy HID device from e.g the registry?

查看:530
本文介绍了如何从注册表中找到蓝牙低功耗HID设备的唯一ID?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

将蓝牙低功耗鼠标与我的Windows 8.1笔记本电脑配对时,我希望能够读出该鼠标的唯一标识符(编写用于在BLE鼠标上测试硬件的应用程序)。 


由于我们的测试框架是在Qt中构建的,我想我可以读取一些注册表元素来获取硬件ID或其他东西,但我似乎无法找到任何不会改变的数据在每个与同一设备配对之间。 


HKEY_LOCAL_MACHINE \SYSTEM\CurrentControlSet \ Enum \ BTHLE 下我能看到鼠标已经配对并且给出了例如BTHLE \Dev_f385b7b4df8的hardwareID。如果我从蓝牙设置中删除设备并再次配对,则ID会将
增加一个:  BTHLE \Dev_f385b7b4df 9


我可以在注册表中找到对我的设备而言真正独特的内容吗?

解决方案


总线驱动程序可以将唯一ID可靠地散列为全局唯一标识符,您可以参考以下链接:


http://msdn.microsoft.com/en-us/library/windows/hardware/ff540089(ⅴ = vs.85).aspx


http://msdn.microsoft.com/en-us/library/windows/hardware/ff540101(v = vs.85).aspx


问候,


When pairing a Bluetooth Low Energy mouse to my Windows 8.1 laptop, I want to be able to read out a unique identifier for this mouse (writing an application for testing hardware on a BLE mouse). 

Since our test framework is buildt in Qt, I figured I could just read some registry element to fetch an hardware ID or something, but I can't seem to find any data which doesn't change between each pairing with the same device. 

Under HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\BTHLE I am able to see that a mouse has been paired and given a hardwareID of e.g BTHLE\Dev_f385b7b4df8. If I remove the device from my bluetooth settings and pair it again, the ID has increased by one: BTHLE\Dev_f385b7b4df9.

Where in the registry can I find something that is actually unique for my device? 

解决方案

Hi ,

The bus driver can reliably hash the unique ID into a globally unique identifier ,you could refer the following links below:

http://msdn.microsoft.com/en-us/library/windows/hardware/ff540089(v=vs.85).aspx

http://msdn.microsoft.com/en-us/library/windows/hardware/ff540101(v=vs.85).aspx

Regards,


这篇关于如何从注册表中找到蓝牙低功耗HID设备的唯一ID?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆