This widget could not be displayed.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

VISA to read/write COM1

Dear all,

 

This is a simple example to test VISA to read/write my COM1, I have Labview 8.6 and even downloaded and installed the VISA441 again.

But it doesn’t read anything from COM1.

 

The error message is “timeout expired before operation completed.”

 

I appreciate for your help.

 

Raymond

 

0 Kudos
Message 1 of 4
(2,907 Views)

What are you communicating with?  Are you sure you have the right kind of cable between the two.  Between 2 PC's, you would need null modem cable.  Between a PC and another device, you might need a straight through or null modem cable, you would have to check the manual for the device.  Are you sure you have the correct communication settings?  Usually you would need a small delay between the write command and the read command to give time for the other device to read the command and turn around and send back a response.

 

Do you know what the return message is supposed to look like?  Does it need a termination character such as a line feed or CR/LF?  How are you running this VI?  It is set up as a one shot VI.  Are you using the Run Continuously button to run it?  I hope not.

 

You should really look at the examples in the Example Finder such as Basic Serial  Write and Read.

0 Kudos
Message 2 of 4
(2,897 Views)
May be the "byte count" have a wrong value or the "VISA Read Timeout Property" is too small.
0 Kudos
Message 3 of 4
(2,896 Views)
Ravens Fan is right. Check out the shipping example found in example finder called "Basic Serial Write and Read.vi". This is a simple serial VI that shows the delay needed for some communication. Give it a try and let us know what you find out. Good Luck!! Thanks Ravens Fan!!
Message 4 of 4
(2,849 Views)