Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

inconsistent serial write

hello,

I'll be brief. I'm a novice, still trying to get the feel of labview. Somehow there's an inconsistency of the serialwrite.vi in my program. Using a protocol analyzer, I could see that sometimes the serial write doesn't send all the strings in the command text box. (For instance, the value of the command textbox is "send 200", and sometimes the serial write only sends "se"). I followed the guideline for serial communication: initialize (baud = 9600, databits = 8, stopbits = 2, parity = none), flush the buffer before writing to the serial port, send the string to the port, have a serial port break to wait for response, and count the number of bytes on the serial port before reading them. I use R-232, and I also have checked the "updat
e value while typing" on the pop up menu of the command textbox. My program is attached. I will appreciate any help in any way. Thank you!!
0 Kudos
Message 1 of 3
(3,151 Views)
Your VI was not attached. I'll take a look at it uf you want to send it along. Either attach it here on the DE or send it to me direct at rcole@cell-loc.com.

Rob
0 Kudos
Message 2 of 3
(3,151 Views)
Try using VISA instead of serial VIs. VISA is lot better to use in almost everyway. There is a VI on your computer ( that has Labview on it )named, serial communication.vi That VI will help you understand the use of VISA in serial communication. But for some reason if you have to use Serial VIs then attach your VI on this developer exchange and I will try to troubleshoot the problem.
0 Kudos
Message 3 of 3
(3,151 Views)