LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

COM port assigned to a defined hardware device

Hello,

I am developing a test rig and I would like to know which COM Port was assigned to a certain hardware device.

Background:

Until now I have used a ".init" file to assign manually the COM Port to a desired device. This works until someone unplug the tester and plug it in a different PC. Then I need to update the ".init" file and only then the tester can be used. I want to avoid this process and improve my tester.

Hardware used:

I need a TTL-USB converter, for this purpose I am using a FTDI device, specifically the TTL-232RG. This converter works with the integrated circuit FT232R.

Software used:

I work with a Windows 7 OS. The FTDI drivers installed are the  version 2.8.30.0 .Labview version is 2013

What I have done:

Until know I can read the COM Ports and the Serial number of the devices but nothing else (See attachment).

I also have tried the DLL approach but FTDI only provides some examples for Labview7 (See attachment), and I still cannot read the COM Port from the DLL ( and I serouosly doubt that this is possible).

I would be very grateful if someone could tell me how can I relate the Serial number with the COM Ports?. I am starting to feel that I need to develop my own USB-hub to solve my problem because it seems that part of the problem is the software plattform used (in this case Microsoft Windows) and probably I need to go down at the physical layer of the communication to achieve my goal.

 

P.S. I already have read the following documents:

http://www.ftdichip.com/Support/Documents/AppNotes/AN_107_AdvancedDriverOptions_AN_000073.pdf

http://www.ftdichip.com/Support/Documents/AppNotes/AN232R-02_FT232RChipID.pdf

http://www.ftdichip.com/Support/SoftwareExamples/CodeExamples/LabVIEW.htm

 

 

 

 

Download All
0 Kudos
Message 1 of 2
(2,794 Views)
The VISA Find Resources or the System functions can return a list of com ports. You just have to take the array and try to communicate to your instrument for each port. This avoids the whole dependency on specific registry entries and vendors.
0 Kudos
Message 2 of 2
(2,786 Views)