Patrik Thalin
2010-02-19 10:10:11 UTC
Hi all,
I am looking for a solution to identify the physical USB ports used by a
device. I have looked at devcon in WDK to find the DeviceID eg.
USB\VID_xxxx&PID_yyyy\6&6B42B9C&0&4. This seem to be a unique for the
port used. I have successfully duplicated this to my application. By
calling SetupDiGetDeviceRegistryProperty and SetupDiGetDeviceInstanceId.
But I can't find a way to associate this to the driver handle. Can this
be done?
Any other suggestion on how identify the port is also welcome! Note that
I can not use a serial number in the device it has to be unique for the
USB port on the computer. Also note that I have several indentical units
connected.
Thanks in advance!
Regards,
Patrik Thalin
I am looking for a solution to identify the physical USB ports used by a
device. I have looked at devcon in WDK to find the DeviceID eg.
USB\VID_xxxx&PID_yyyy\6&6B42B9C&0&4. This seem to be a unique for the
port used. I have successfully duplicated this to my application. By
calling SetupDiGetDeviceRegistryProperty and SetupDiGetDeviceInstanceId.
But I can't find a way to associate this to the driver handle. Can this
be done?
Any other suggestion on how identify the port is also welcome! Note that
I can not use a serial number in the device it has to be unique for the
USB port on the computer. Also note that I have several indentical units
connected.
Thanks in advance!
Regards,
Patrik Thalin