如何获取附加到串行端口的设备制造商名称
我想知道 Win32 中获取串行端口附带的设备制造商名称的方法。
我已经尝试过使用 SPDRP_MFG 的 SetupDiGetDeviceRegistryProperty API 选项,但获取驱动程序提到的制造商名称。我想要与设备而不是驱动程序关联的制造商名称。
我的设备是一个 USB 设备,在设备管理器中显示为 USB 串行端口 (COM4)。
谢谢
I want to know a method in Win32 to get the device manufacturer name attached with the serial port.
I have already tried the SetupDiGetDeviceRegistryProperty API with the SPDRP_MFG
option but getting manufacturer name which is mentioned by the driver. What I want manufacturer name associated with the device not with the driver.
My Device is a USB device and appearing as a USB Serial Port(COM4) in the device manager.
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
串行设备不会将此类元数据发送到计算机。没有像 USB 连接那样进行握手,设备可以识别自己。使用串行设备,计算机只需开始发送或接收数据。
A serial device does not send this type of meta data to the computer. There is no hand-shaking done like in a USB connection where the device identifies itself. With a serial device, the computer just starts sending or receiving data.
运行 WDK 附带的 USBView 示例,获取 USB 设备的制造商名称和其他信息。
Run the USBView sample which comes with the WDK to get the manufacturer name and other information about the USB devices.