wrong instance id for usb device

HI,

I have an usb device which works fine, until I found I can’t insert 2 or more instance into the usb port of my pc, One device would just disappear from device manager after more devices are inserted.

I found something strange, device instance id: usb\vid_xxxx&pid_xxxx\000000000001,
while I noticed instance id of other valid device, (like a optic mouse), is usb\vid_xxxx&pid_xxxx\MI_00\7&1127f114&0&0000. From search, I am guessing “7&1127f114&0&0000” this may be instance id of the parent device node.

I am suspecting that “UniqueID” of IRP_MN_QUERY_CAPABILITIES is set by usb bus driver for my device. I set it to FALSE in my device FDO driver, I re-install the driver again, but still the same. I tried to delete all the device related info in registry table, but I failed to do so due to errors.

I also insert the device to a system in which my FDO driver is not installed. it also gives the wrong instance id, “usb\vid_xxxx&pid_xxxx\000000000001”.

Thanks for suggestions/helps!

Br, Gang

You’ve just discovered (some of) the implications of defining a serial
number in your USB device. If you have one, no two serial numbers must
ever be the same for your combination of VID/PID.

Remove the serial number string, i.e. set iSerialNumber=0 in your device
descriptor, and you’ll be fine.

Hi,

yes, you are right, although I haven’t try that out. I planned to use a
chip with unique id, but I changed to a chip without that unique id and I
forgot to change iSerialNumber.
Thanks for your help! It is amazing it is solved so quickly!

Br, Chen Gang

2013/7/10 Wilhelm N?ker

> You’ve just discovered (some of) the implications of defining a serial
> number in your USB device. If you have one, no two serial numbers must ever
> be the same for your combination of VID/PID.
>
> Remove the serial number string, i.e. set iSerialNumber=0 in your device
> descriptor, and you’ll be fine.
>
>
> —
> NTDEV is sponsored by OSR
>
> Visit the list at: http://www.osronline.com/ showlists.cfm?list=ntdevhttp:
>
> OSR is HIRING!! See http://www.osr.com/careers
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.
cfm?name=ListServerhttp:
></http:></http:>

Wilhelm Nöker wrote:

You’ve just discovered (some of) the implications of defining a serial
number in your USB device. If you have one, no two serial numbers must
ever be the same for your combination of VID/PID.

Remove the serial number string, i.e. set iSerialNumber=0 in your device
descriptor, and you’ll be fine.

Or, more usefully, assign unique serial numbers to your devices.


Tim Roberts, xxxxx@probo.com
Providenza & Boekelheide, Inc.