LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Ports are sometimes "COM" and sometimes "ASRL"

Solved!
Go to solution
Highlighted

I have a chunk of code that looks for active COM ports, tests them for a connection, then uses that port.  The problem I'm running into is I am using this code on several laptops with Windows7 and for some reason some laptops list the ports as COM1, COM3, etc while others list them as ASRL1, ASRL3, ASRL5, etc.

 

I haven't been able yet to figure out why some are using different nomenclature, but it throws off my COM port program.  I don't want the operators to have to use a pull down menu and select the port as this test needs to be fully automated.

 

Any ideas on how to fix this?

********************************************
Amateur programmer for over 10 years!
********************************************
0 Kudos
Message 1 of 3
(1,245 Views)
Highlighted
Solution
Accepted by topic author spaceman_spif
The com references are aliases. The asrl references are the canonical names. You can filter the VISA Find Resources to return either. I'd that what you are using to get your list?
Message 2 of 3
(1,241 Views)
Highlighted

That did the trick!  Many thanks, DK!

********************************************
Amateur programmer for over 10 years!
********************************************
0 Kudos
Message 3 of 3
(1,235 Views)