LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Check PID/VID of a USB Pen/Thumb Drive

Rebecca,

>> 2. I know I can detect a NI VISA driver to read the device. However, if it's a USB pen drive, the windows will automatically load the Windows driver for the USB, the PC will bypass the NI driver. So, I can't use the NI Visa driver wizard.
<<

There is a way to assign NI-VISA RAW driver to your Pen device, instead of assigning the Windows default driver. First create an INF file that explicitly contains your VID/PID.  You can machine-generate the INF by using NI-VISA USB driver wizard tool.  Once the INF is generated, place it in the Windows/INF direcoty.  Next open the Control -> System -> Device Manager tab, then go for your USB device node then "Update" the hosting device driver replacing with the generated INF file, which makes NI-VISA RAW driver host your Pen device instead of the Windows default driver. 

This approach allows you to override any class driver that host a class device, swapping to an arbitrary device driver to host, as long as a correct INF file (containing explict VID/PID entry in it) is placed in Windows/INF directory. 

Message 11 of 15
(4,502 Views)

Hi,

I tried to access the thread but it said the Message has been deleted. Could you please advise again? Thanks

0 Kudos
Message 12 of 15
(4,503 Views)
Message 13 of 15
(4,497 Views)

Hi all,

i got my problem solved using the Devcon.exe method. it's very useful, just like the Device Manager. Thanks a lot for the quick help! Thanks!

0 Kudos
Message 14 of 15
(4,531 Views)

Rebecca,

 

    would you send me the VI that read the PID and VID of the USB  Drive without using the NI VISA development wizard?Labview will be automatic detect the windows inf file and install the driver.

 

0 Kudos
Message 15 of 15
(3,126 Views)