NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Labview call in TestStand does not return to TestStand after execution

Hi,
 
Sometimes (I would say every 50 calls), some VI calls from TestStand does not return back to TestStand. When I trace in Labview, everything is executing normally, but then the TestStand execution does not continue... I have to kill Labview, and then I have the standard error (An error occurred accessing the LabVIEW ActiveX automation server) that occurs when the Automation Server is shutdown during an execution. I have read some post stating this problem using TestStand 2.0 and Labview 6, but I am far from this (using Labview 8.5 and TestStand 4.01f1 Development environment).
 
Regards,
Alexandre Boyer
0 Kudos
Message 1 of 16
(5,476 Views)

Hi Alex,

I have a few questions:

Is this with the Sequence Editor or the User Interface?

Has the Editor or User Interface been modified, is so have you tried the default editor or User Interface?

Is this with a particular VI?

Does the VI take a long time to execute?

Do you have any parallel executions or threads running?

Is the TestStand engine showing any signs of terminating, but you are not seeing it in you VI?

Have you tried switching on some of the Debug Options found in the Station Options | Preferences and Press the Debug Options button.

Regards

Ray Farmer

Regards
Ray Farmer
0 Kudos
Message 2 of 16
(5,474 Views)

Hi,

Thanks for the quick answer. Here are the precisions:

Hi Alex,

I have a few questions:

Is this with the Sequence Editor or the User Interface?

With the sequence Editior (we don't have a UI now)

Has the Editor or User Interface been modified, is so have you tried the default editor or User Interface?

No

Is this with a particular VI?

It happens on different VIs. It really seems random. 

Does the VI take a long time to execute?

It depends on the VI. Most of the time between 0.1 and 30 seconds. Some other VIs are waiting for user intervention. So they may take a longer time if the user is sleeping somwhere)

Do you have any parallel executions or threads running?

No, single execution with the SequentialProcessModel

Is the TestStand engine showing any signs of terminating, but you are not seeing it in you VI?

Not that I know. Looks like TestStand is really waiting the VI call to terminate, but this one is not able...

Have you tried switching on some of the Debug Options found in the Station Options | Preferences and Press the Debug Options button.

No. We can try this. We will also try to run with the Labview run-time engine instead of Labview Development.

Regards

Ray Farmer

Thanks!

Alexandre

0 Kudos
Message 3 of 16
(5,472 Views)

Hi Alex,

Ok lets see if enabling the Debug options give some help in pin pointing the problem

Regards

Ray

Regards
Ray Farmer
0 Kudos
Message 4 of 16
(5,468 Views)

Hey Alexandre,

 

Were you ever able to resolve this? Did enabling Debug options reveal the cause?  Feel free to respond if you are still seeing this behavior.

Jessica
National Instruments
Product Support Engineer
0 Kudos
Message 5 of 16
(5,341 Views)

I have a similar problem with TestStand 4.0 and LabView 8.5. The TestStand scripts have approximately 200 VI calls and I am getting the error on random VIs quite frequently.

Alex - were you able to resolve the issue? I would appreciate your tips/comments on this issue.

 

Anyone else who has seen this problem - any suggestions would be appreciated.

Thanks!!!!

Mim

0 Kudos
Message 6 of 16
(5,210 Views)

Hi Mim,

 

Finally, I changed my VI call for an asynchronous call. It may sounds weird, but it was ok in my application. And at the end of my sequence, I wait for all my thread to be killed by the operator.

 

Alex

0 Kudos
Message 7 of 16
(5,166 Views)

Hi Alex:

Thanks for the prompt response.

How can I make my call Asynchronous? I am seeing the failure too often and absolutely need to resolve the problem.

BTW, my TS script has 200 plus calls and they are all LabView actions.

 

Thanks once again.

Mim

0 Kudos
Message 8 of 16
(5,148 Views)

Hi Alex or Mim,

 

Can either of you provide an example that demonstrates this behavior?  I would like to reproduce it on my end to help understand the cause of this behavior.  Thanks.

 

 

Jessica
National Instruments
Product Support Engineer
0 Kudos
Message 9 of 16
(5,139 Views)

Hi,

 

To run a VI asynchronously, you a a new step from Insert Step-Labview Utility-Run VI asynchronously. Note that the VI will be launch in a different thread. So it is not necessarily suitable for all kind of applications, even if you can keep your thread reference in a local variable (Locals.ThreadRef) and wait for its end of execution after each call  (Locals.ThreadRef.AsThread.WaitForEnd).

 

Now, I never had this problem when I do not show the front panel. Can it be a confusion between "Show VI Front Panel" in TestStand and VI "Show Front Panel when call" in Labview? Also, the VIs it was happening with where toggling on a button event (to leave the VI). Can it be something related to this? I don't remember exactly since now, every VI called from TestStand with user intervention (so the Front Panel is shown) is called asynchronously... And I don't have the problem anymore.

 

Regrads,

Alex

0 Kudos
Message 10 of 16
(5,104 Views)