LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

visa read to file

Hi all,
I have a problem when I use VISA Read To File.vi. I have connected visa to com3 (modem).
I send a file from another modem using a telephone line with VISA Write From File.vi, but VISA Read To File.vi doesn't read all of the bytes in the receiving point.
Can anyone help me?
0 Kudos
Message 1 of 4
(2,871 Views)
Are you sure that the termination character options are set properly?

They are available through the VISA property node. Correct setting of these parameters is necessary to handle CR and LF characters properly for your application.
Regards,
André (CLA, CLED)
0 Kudos
Message 2 of 4
(2,866 Views)
Hi!
  It'd be nice if you post your code, there can be many causes to the problem you are reporting: I am thinking of a wrong setting of VISA communication (termination char enable...), but maybe this is not the case, so please, let me know more.

   Have a nice day!

graziano
0 Kudos
Message 3 of 4
(2,865 Views)

I think reading from a serial port is one of the most common questions asked in this forum.  It depends on your application how to implement this function.  I will show an example that continuously monitors the serial port in a standalone thread.  When data is collected from the serial port it holds the data in a string buffer until there is no more data to be read at the serial port.  Since I don't control how fast or when the data will be at the serial port -- I loop the read in 75ms iterations until the serial port is completely empty (no more data is there to be read)

One note is that it is very important to poll the serial port as to how much data it contains for eading and then read that entire amount. See below.  Tom

 



Message Edited by Tom Haggerty on 12-18-2007 07:26 AM

Message Edited by Tom Haggerty on 12-18-2007 07:27 AM

Message Edited by Tom Haggerty on 12-18-2007 07:29 AM
Download All
0 Kudos
Message 4 of 4
(2,864 Views)