Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

How to get a COM port identifier?

 


@popol21 wrote:

Hello,

 

I have a problem I thought would be easily solved. But finally I can't find the solution myself.

 

Under Windows (XP), if I go into the Device Manager, I can see the list of my hardware, including the COM ports. I can see there an "identifier" of the port. For example, if I plug an USB to RS-232 converter (FTDI), I can see its name.

 

How can I have access to this identifier under LabVIEW?

 

Thank you in advance for your answer.


 

You see the (FTDI) name in the device manager because of the FTDI driver....

To access these informations I would call  the FTDI dll functions with labview  (like KC said)

But first would digg into the VISA properties,but I think you already looked into it .... (sorry currently no FTDI serial device nearby...)

 

 

Greetings from Germany
Henrik

LV since v3.1

“ground” is a convenient fantasy

'˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'


0 Kudos
Message 11 of 15
(1,763 Views)

Ok, thank you KC and Henrik. I will follow your suggestion.

0 Kudos
Message 12 of 15
(1,754 Views)

Have you tried to query the name using a VISA Property Node? Try the Interface Information->Interface Description property and see if it gives you what you are looking for.

 

-Jason S.

0 Kudos
Message 13 of 15
(1,723 Views)

@ popol21: Have you successfully tried it with the dll? You can find LabVIEW examples at FTDI's.

The workflow would be:

1. get a full list of FTDI devices (dll)

2. search it for your desired device description (LV)

1&2: If you can ensure there's only one such device: Open it by description (dll) (FT_Open_Device_By_Description.vi)

3. get the COM port number of the device with that description (dll) (FT_Get_COM_Port_Number.vi)

4. get the ASRL... identifier according to the COM port number (VISA/LV)

4. open the COM port with a string ("COM " + number) as the resource (VISA) (you will see a coercion dot!)

5. do your regular communication with the VISA resource out (of VISAopen)

 

I hope this helps everyone using FTDIs! Smiley Happy

Message 14 of 15
(1,587 Views)

Yes, I achieved to do it. Anyway, thank you for your answer. Indeed, if people are looking for FTDI identifier, follow the above instructions.

 

Thank you again.

0 Kudos
Message 15 of 15
(1,577 Views)