LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Problem to talk to an instrument using rs232

Hello,

We are trying to communicate to a ROD-4 (instrument) by using an rs232 link. We have a program from rod-4 on pc and this communicates with the instrument(--> rs232link is OK I suppose) but we can't program everything we want. Therefore we will use Labview to communicate with the instrument(Rod-4). We have made a VI to communicate with the ROD-4 but it doesn't work. Do you want to check the VI I have made to communicate by rs232. Check also the rod-4 maual.pdf on pg 8 and 9, there is standing which program language the rod-4 knows (ascii protocol). The machine(rod-4) answers in the string read with:'' ?\n\r ''what dus this means?
(Using win98se with Labview 5.1)

Thanks.
0 Kudos
Message 1 of 11
(3,916 Views)
One problem is that you're not sending the stx control character (hex 02). You're sending the text "s", "t", "x". I've attached a picture of a modified VI that should work. Note that I replaced the serial functions that you're using and used VISA commands instead. I'm also curious about something. You said you're using LabVIEW 5.1 but the VI you posted is version 6.1.
0 Kudos
Message 2 of 11
(3,906 Views)
Thank you Mr. Denis Knuston, you solve my problem. I had a similar problem trying to communicate with the serial port in LV. The only thing I have is set the \ codes display in the parameter of the string control. I will remember this one.
0 Kudos
Message 3 of 11
(3,891 Views)
Hello, I have worked in labview with GPIB, and now, I need control my instrument with rs-232. My instrument is a tesslameter, could I control my instrument since Labview with your example?? I have labview 6i.
0 Kudos
Message 4 of 11
(3,873 Views)
Hello,

We have tried to build the VI that you send in the jpg file, but it doesn't work. Have we made an error or something because it won't work. The VI we have made is in the attach.

Thnx.
0 Kudos
Message 5 of 11
(3,849 Views)
Hello

Thank you we have found a solution.
It works well !!!
Thanks to all !

Greetz
0 Kudos
Message 6 of 11
(3,839 Views)
What was the solution?
0 Kudos
Message 7 of 11
(3,837 Views)
Hello,

A problem was like you said 02hex (ascii),but unless we changed it and your program doesn't work!
And the I found this VI on the internet en this works !
Check it out in the attach !

Thanks a lot !
Greetz.

Message Edited by Spielberg on 02-25-2005 12:00 PM

0 Kudos
Message 8 of 11
(3,823 Views)
Open up your block diagram and right click on your string constant that contains the text \0201SFD50.5\r, then select '\' Codes Display. You will notice that your string will change to \\0201SFD50.5\\r. If you are not trying to send the ASCII character '\' remove the additional slashes. This is the difference between an ASCII character display and ASCII code display.


This maybe work also with your program, I am going to try it monday and I let you know something !
0 Kudos
Message 9 of 11
(3,816 Views)
My VI don´t work with this jpg file,I have labview 6i,Can you show me your design in jpg file??
0 Kudos
Message 10 of 11
(3,467 Views)