Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Auto Detect device COM port

I was wondering if it's possible to detect the com port of the device with no built-in intelligence i.e, no specific command for an unique device identification. eg: devices with command for serial no.

 

I have used the VISA find resource to find the list of ports based on the baud rate eg: 19200 in my case. How can I further filter it to the correct device, especially when more than one are connected?

 

I'm using a crude way of doing it (see attached sample vi for reference). It has some pro's 7 cons but any suggestions to make it better are welcome.

 

Thanks & Regards,

 

Sri

0 Kudos
Message 1 of 2
(3,315 Views)

The only way to know that a device is actually connected to a com port is to write something to the device that tells it to return data and then you have to do a read and verify the data is correct. What you have inside the while loop does not do much more than what the VISA Find Resources is alreay doing.

0 Kudos
Message 2 of 2
(3,303 Views)