当前有哪些 USB 设备(友好名称)连接到 PC?
我可以获得当前连接到计算机的设备列表吗?
我检查了这个和this 线程,但我似乎找不到实际名称(即 iPod Touch 4 等)有没有办法到找到人类语言的设备名称,这样我就可以向用户显示这个(匹配设备的)列表?
有 PI 获得此信息吗?
更新:我注意到计算机的设备管理能够显示此信息,这意味着它确实存在于某处,我只是不知道访问它的正确位置。
我确实在注册表中找到了此信息,但“Mighty Drive”和“iPod”之间存在一些不一致,我正在寻找可靠的注册表。寻找此信息的关键。
Can I get a list of what devices are currently connected to the computer?
I checked this and this thread, but I can't seem to find the actual names (i.e. iPod Touch 4 etc.) is there a way to find the name of the device in human language, so I can display this list (of matching devices) to the user?
Any PI that gets this info?
Update: I notice that the computer's device management is able to show this info, meaning it does exist somewhere, I just don't know the right place to access it.
I did found this info in the registry, but there is some inconsistency between the "Mighty Drive" and the "iPod", I'm looking for a reliable reg. key to seek for this info.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
设备管理器显示与特定设备关联的第一个“显示名称”属性。您可以使用 < 获取该信息我相信,code>SetupDiGetDeviceRegistryProperty 与
SPDRP_FRIENDLYNAME
属性。Device Manager shows the first "Display Name" property associated with a particular device. You can get that information using
SetupDiGetDeviceRegistryProperty
with, I believe, theSPDRP_FRIENDLYNAME
property.