LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

visa exclusive lock

I am not having luck opening a com port with the exclusive lock selected in visa.  I am trying to prevent multiple instances of my labview code from accessing the same com port.  I selected exclusive lock when opening the com port visa session then leave thje session open for use in the first application, then I open the same com resource from a second labview session expecting to not be able to open communication since the resource was susposed to be exclusivly locked, but the open visa returns with no errors.  How do I get the exclusive lock to work.  Did I miss something?  Using LV 8.5.1 and the latest visa and Max.

 

 

Paul Falkenstein
Coleman Technologies Inc.
CLA, CPI, AIA-Vision
Labview 4.0- 2013, RT, Vision, FPGA
Message 1 of 5
(4,630 Views)
There is alot of documentation and examples of how to use the exclusive lock feature in the NI VISA Help.
National Instruments
Applications Engineer
Message 2 of 5
(4,605 Views)

I did not really find a good example in the help file.

 

Attached you can find two identical vi's (LV2011), I can run them simultanously without getting an error... What did I do wrong?

Download All
0 Kudos
Message 3 of 5
(4,222 Views)

Didn't you look at the example that comes with LabVIEW (Locking.vi)? Set the Duplicate Session input to True and see if you get an error.

Message 4 of 5
(4,216 Views)

duplicate session = TRUE  , works fine!

 

Thanks!

0 Kudos
Message 5 of 5
(4,197 Views)