Read VID and PID of a USB Device

A

Thread Starter

Anonymous

I am trying to find a way to read VID and PID of a USB device. Please let me know if you have any idea.
Thanks.
 
R

Robert Scott

This works with some devices. After a device is installed on a Windows computer, go to Settings, Control Panel, System, Hardware, Device Manager. Find the device and click on Properties. Select the "Details" tab and in the drop-down box select Device Instance ID.

Robert Scott
Real-Time Specialties
Embedded Systems Consulting
 
Thanks a lot for your answers. Those give me a good start point. Now I have to write a C++ program to read VID and PID of a USB device on Windows. Do you know how to do this? Or if you have any link that guides me how to do this, please share with me.

Thanks.
 
C

Charlie Harris

Att: PAUL/MICHAEL

On a similiar vein. I need help as below. Can someone help me?

I am having some difficulty in solving the minor problem below. Can you please send me in the right direction, to someone who could advise me?

Basically all I need is to be shown how to find the USB HID table that shows each single device and where their input is going. I can then get Excel to extract details, etc.

I need some advice as to what area I should be looking at to accomplish the following. Are you able to advise me or quote me a suitable answer. I do not need anything more than set out. Don't need packet info, etc. or tool kits for development. All I want to do is place the USB Instance ID beside each reading in Excel. I can then allocate each devices reading to its own table.

I am a model railroad hobbyist and wish to use system below for tracking rolling stock on the layout.

I have been searching for an answer to the situation below. This is a USB device and your advice on how to use would be appreciated.

I have purchased a couple of these devices: (USB Pen Drive for Reading RFID
tags)

http://www.rfidshop.com/index.asp?function=DISPLAYPRODUCT&productid=1120

XP Home 97 Excel
I import info into Excel via the USB RFID reading device (via Human Interface Device).

Using one device works fine and places info in Excel (or any Windows product) at the active cell.
Using two devices both readings go in same column again in the active cell. This is ok - if I can tag each entry in the adjacent column with the USB ID, and then do a macro to tell Excel in which column to transfer each devices' info is to go.

I need to know which reader has read which tag, and how to find this information.

The XP Device Manager gives separate 'Device Instance ID' for each device, e.g.

USB\VID_1241&PID_E000\5&1DC3342F&0&2
USB\VID_1241&PID_E000\5&1E9A0CB1&0&2

How do I get Excel to recognise the different Device ID (2 or more units say up to 20) and tag each each entry at the 'live cell' with the individual Device ID reference?

Thanks,

Charlie Harris
New Zealand
 
M

Michael Griffin

I looked on the web site you mentioned, but there wasn't much technical information about the device. Does it have a unique serial number for each device? Some USB devices do, in which case perhaps you could read the serial number and from that figure out which tag reader you were looking at (this might not be possible for a HID device though).

Without an identifier (serial number) in the device itself, you are trying to determine which particular USB port a USB device is using. This is something that is very difficult to do because USB is designed to try to hide this from you (this was intended to make it more "user friendly", but it makes tasks such as this much more difficult).

If you access the devices using some low level programming, then it may be possible, however I couldn't tell you how to do it for that device with the information I have available.

I did a Google search for information by the way, and saw that you have posted this same question at a number of sites without getting any better replies. Perhaps the actual manufacturer of the device has some suggestions. Also, see the next point below.

As an aside, you mention that you are trying to read this information into MS Excell. I don't why you would be using MS Excell for this, unless you are just trying to use it to test out the functionality of the device. There is software available for controlling model railways. One of the packages is called JMRI (http://jmri.sourceforge.net/). This is free software, which means there are lots of people working on different aspects of it. Someone there might be able to help you in a way which is more directly connected with what you are trying to do.
 
J

Jacek Konczewski

http://www.ftdichip.com/Resources/Utilities/usbview.zip

USBView is a free utility from Microsoft that displays the USB connection tree and shows the USB devices that are connected to it together with their configuration data. This is very useful for debugging USB enumeration errors. USBView runs under Windows 98, ME, 2000 and XP.

It reads VID and PID.

Jacek Konczewski
 
How does USBView do this? I also need to write C++ for viewing VID/PID in my app.
I have tried to find the source code for USBView - or just find any information on this topic.

It seems like ftdichip.com is down as I am not able to load their website.

Any help is greatly appreciated.
 
> How does USBView do this? I also need to write C++ for viewing VID/PID in my app. <

> I have tried to find the source code for USBView - or just find any information on this topic.

oh , I also want to know, can anyone help?
 
J
microsoft provides the source code for the usb view. it is in C. i ported everything from their code to C++.
 
Hey can anyone help me with a C or C++ program to get VID and PID of a USb device connected to a Windows machine.

thanks in advance
 
Top