LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

invalid vi session

Solved!
Go to solution

Hi,

 

I am using PX-1042 system with the power supply NI PXI-4110. I initialize the supply in the start of the program which works fine, but as soon as the cotrol goes into the block where it reads the Voltage and Current continuesly, an error window occurs which says.

 

 

"Error -1074130544 occurred at niDCPower Measure Multiple.v"

 

"Possible reason(s):Invalid VI session."

 

 

In this block, I don't initialize the Power Supply again as I have done it already. I have also attached the whole code here. Any one please give me the solution to get rid of this error code.

 

Regards,

 

Mansoor

0 Kudos
Message 1 of 2
(2,274 Views)
Solution
Accepted by topic author MansoorEE

You are not using the instrument handle that was created when you initialized the instrument.  Instead you are using the VISA resource name.  That is not the same as the handle.  You should be using the purple wire called handle coming from your initialization VI, not the VISA resource constant.

 

There are also a few odd things going on.  Don't use a value property node for measurement when you have the terminal available.  Also, your false constants wired to the while loops means the only way you can stop the VI is by aborting it.  You could also merge your two different event structures into one.

0 Kudos
Message 2 of 2
(2,266 Views)