Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect manufacturer reported in Windows 10 #65

Open
sparta-developers opened this issue May 31, 2019 · 1 comment
Open

Incorrect manufacturer reported in Windows 10 #65

sparta-developers opened this issue May 31, 2019 · 1 comment

Comments

@sparta-developers
Copy link

Setup

  • Version: 1.3.1
  • OS: Windows

Expected Behavior

We're running into an issue where on OSX, our USB devices show up in Circuits.UART.enumerate() with the actual device manufacturers, with serial numbers. We would expect the same behavior in Windows.

Actual Behavior

In Windows, the manufacturer key is coming up as (we think) the manufacturer of the device driver. For example, for one type of device, in Windows the manufacturer is "Microsoft," whereas the other device appears as "FTDi". When we look at the COM ports in usbview.exe, we see the correct manufacturer values listed under the iManufacturer key, with the serial number listed as iSerialNumber.

It looks as if the values provided by the <setupapi.h> header may be specific to the device driver, rather than the usb device information. In <usbspec.h> we see definitions for the values provided by USB.

The source code for usbview.exe shows an example for how to retrieve this information from USB.

Since UART is not just USB-specific, we weren't sure if making the change to get this info from the USB bus would be something that should or should not be added to this library. We spent a bit of time trying to get this data using more recent (Vista+) functions available from setupapi, but haven't yet found a way to do so. If you know how to do so and are ok with this change, we're happy to submit a pull request.

Thanks!

@fhunleth
Copy link
Contributor

fhunleth commented Jun 1, 2019

Hmm. It has been so long since I've used Windows regularly that I'm really not sure with doing some digging.

There might be hints in Node Serialport - https://github.com/serialport/node-serialport/blob/master/packages/bindings/src/serialport_win.cpp#L782 or Qt - https://code.qt.io/cgit/qt/qtserialport.git/tree/src/serialport/qserialportinfo_win.cpp#n323.

I only very briefly skimmed them since I can't look at this now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants