Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Lakeshore model340 seriel input

Almost forgot,

Yes, the first thing I did was communicate using hyperterminal.

I have also been able to communicate using the generic seriel VI in labview, but it will give read errors if I try writing and reading several times in a row.

0 Kudos
Message 11 of 14
(1,233 Views)

The purpose of the VISA property node is to set the com parameters, to automatically append a LF with each write, and to terminate each read when the LF is detected. So, there is no constant string of LF's being sent, it is only sent once whenever you do a VISA Write.

I would recomend you not run anything in continuous mode. It is a debug technique that you have to use very carefully. You might be running into a timing limitation of the instrument. If you need to continuously write or read something, make sure you have some sort of delay in the loop (i.e. Wait (msec). The instrument manual should tell you what kind of update rate it supports. You might also need a small delay between a VISA Write and a VISA Read though with the termination character enabled, this is often not necessary.

0 Kudos
Message 12 of 14
(1,231 Views)
Hello once again,
 
I tried putting time delays between my Visa write and Visa read operations.  I used a Time delay running on the error line(pink wire) is this the correct way to put the delay in or am I doing this wrong.
 
I am about to explain something poorly please bear with me.  I have a box(I think it is some kind of modified string) attached to my Visa read which allows me see what the Visa Read is seeing in the buffer.
 
The way the circuit is set up is the following.  I ask the device *IDN? and it should respond with model # and then continue with the operations in Sensor VI to write the command asking the temperature in Celsius (CRDG?A), then a delay, then read the buffer. Next, I write the command asking the temperature in Kelvin (KRDG?A) followed by a delay and a command to read the buffer. Finnaly a write command asking for a sensor reading (SRDG?A) with a delay and then a read buffer command.
 
What is interesting is sometimes when the buffer is being read after the VISA WRITE for CRDG?A  the VISA READ will spit back the model #, even though it correctly initialized.
 
Or when I go to run the VI again sometimes a temperature reading will appear where I should get the model # back.
 
I have included the VISA CLR command into my diagram, but it does not seem to help.
 
Any thoughts?
0 Kudos
Message 13 of 14
(1,210 Views)

Hi Swild,

Can you please post a screenshot of your code?

Thank you,

Simran K
National Instruments
Applications Engineer
0 Kudos
Message 14 of 14
(1,184 Views)