From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

teststand sequence looping

Hello

 

I have made a sequence with 4 numeric limit teststeps who collect data and 3 step numeric limit steps who do calculations with the data from the 4 previous steps.

 

When one of the calculation steps fail i want to loop the sequence for max 3 times in order to gather new data for the calculations. When on of the data collect steps fail i want to go to the cleanup of the sequence  and do no looping. In both situations the sequence has to fail in order to get the end result of the total test failing.

 

What is the best way to deal with this situation ?

Is it possible to change the looping conditions of the sequence on the fly? (switch looping off) 

 

With kind regards

Tonnie

0 Kudos
Message 1 of 2
(3,313 Views)

Pls check attached sequence.

 

This is one way of doing it.

 

For the data collect numeric limit step - in the post actions i have set "on fail " go to clean up.

 

For the data processing numeric limit step - in the post actions i have set on fail options to go to a "go to" step type.

 

There is a locals.try whose init value is 3.

 

The precondition for the go to step to execute is locals.try>0.

In the pre expression for go to locals.try is decremented by 1.

 

Now when a data collect numeric limit step fails - it directly goes to cleanup.

 

When a data processing step fails - it jumps to go - reduces the try count by 1 and restarts the data collect steps.

Go to - will execute only till locals.try is >0 i.e. 3 attempts.

 

Hope this helps.

0 Kudos
Message 2 of 2
(3,306 Views)