LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Visa open, write, close

Thanks for the info! I would have assumed that trying to read a branched/closed VISA session would have resulted in an "invalid reference" error. Your explanation makes sense- thank you for typing it out.

0 Kudos
Message 11 of 12
(462 Views)

VISA open vs close

 

There is an option to automatically close VISA session on exit that implies they stay open.

 

Sea G-Story time!

 

Spoiler

 

I was handed an application that used multiple instruments that were all VISA based, a Temp Chamber that used VISA to talk Modbus which were all used to calibrate instruments that were themselves serial based.

 

Between the "automatic discovery" of DUTs to calibrate and new instruments being added to the game, there were times when an instruments was discovered but then found not to be a DUT... Or Windows deciding a port was idle too long and had to be closed to save the planet...

 

I ended up having to add  logic to detect if there was a VISA write error (Writing to a serial port has to be one of the safest operations if thing don't mess with closing ports) and if so re-open the port.

 

I did not develop the original code and I passed it off to a rookie as quickly as I could!

 

 

 

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 12 of 12
(450 Views)