Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

VISA read loses connection

Solved!
Go to solution

I am new to Labview, kindly help me solve this error. I am writing a code for 3 axis system. The VISA resource read file in the code loses its (serial) connection and re establishes after sometime. I am using an RS232 cable. I couldn't understand what is the problem. Please help 

0 Kudos
Message 1 of 6
(2,472 Views)

You might be confusing the device since you are writing and reading in multiple loops.  At the very least, make a VI that will write and optionally read from your device and use that VI for all of your communications.  The VI will act as a Semaphore (lock) to ensure that the write-read process cannot be interrupted.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 2 of 6
(2,429 Views)

Yeah I will write a vi with write and read and try using it in my program. I hope it works. Thank you.

0 Kudos
Message 3 of 6
(2,386 Views)

I do not know how to make an optional read. Can you kindly help ?

0 Kudos
Message 4 of 6
(2,375 Views)
Solution
Accepted by KarthikMurali

@KarthikMurali wrote:

I do not know how to make an optional read. Can you kindly help ?


Boolean input and a Case Structure.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 5 of 6
(2,359 Views)

I am still experiencing a problem even after I optionally read it. I checked the VISA interactive control and it said that the "resource is valid and the visa cannot access it" . How can I rectify this ?

0 Kudos
Message 6 of 6
(2,320 Views)