NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

TestStand play just few sequences

Hello,

In my .seq I have lots of subsequences.
In the first subsequence, I ask something in a popup message, the operator can just answered by Yes or No.
If he choose No, I would like finish my sequence without playing others subsequences but I would like also have a end test report
It is possible or not ?

I wanted to call the Process Model sequence to have the popup "Testing terminated for current UUT", but the call sequence function don't permit to call it.

 

Thank you

0 Kudos
Message 1 of 11
(3,563 Views)

You can create a custom post action on the messagepopup step that checks which button was hit (using the step property which indicates that) and if the No button was hit the custom post action can either be set to goto cleanup or terminate, whichever you prefer. Goto cleanup ends the sequence in a normal way, but without executing any more of the steps in the main step group. Terminate, is more for an abnormal termination of the sequence and will give the sequence a terminated status (which might be what you want, though I'm not entirely sure).

 

Hope this helps,

-Doug

Message 2 of 11
(3,560 Views)

Thanks Doug,

 

(I apologise, I couldn't answer earlier because of my web connection)

 

You are wright, I prefer go to cleanup ^^

 

I tried to do a custom post action in my popup settings but I don't understand

how you can do a if in it !!

To check which button was hit I wrote step.result.buttonhit == 3

and I don't know how set the post custom to go to cleanup.

(I am a recent teststand user)

 

So I tried something else.

I used a if condition, then the goto function but it doesn't work.

(It is better for me to try with that because if the no button was hit I wanted go to some function

before go to cleanup)

Then I tried to put a statement instead of the goto function. I wrote the expression:

RunState.Sequence.Cleanup

but without mange to do what I want 😞

 

 

0 Kudos
Message 3 of 11
(3,546 Views)

Just out of curiousity:

 

Isn't the execution entry point "Test UUTs" supplying the requested feature to end the test with the serial number entry dialog?

If not, what are the required differences?

 

Norbert 

Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 4 of 11
(3,539 Views)

ok,

I found the solution.

 

I used a if condition with that condition: RunState.Sequence.Main["Mess Pop"].Result.ButHit == X

then at the end of my if condition I used a statement with that expression: RunState.Execution.Terminate().

 

I don't know if it is the best solution but it works ^^.

 

Thanks Doug and Norbert

0 Kudos
Message 5 of 11
(3,527 Views)

I'm not sure why you couldn't get the Post Action to work. It should work fine. Just check the "Use Custom Condition" checkbox, set the expression to your expression checking the button index, and set the "On Condition True" combobox to goto step and set the target for the goto to <Cleanup>.

 

-Doug

0 Kudos
Message 6 of 11
(3,520 Views)

So I think I am doing something wrong,

I checked in use custom condition if the button I want activate the cleanup have been hit

If it is true => Goto Step condition on condition true.

 

I don't think there are something more to do !! 😞

 

I joined a screenshot of my step settings of my message popup.

 

Alex

0 Kudos
Message 7 of 11
(3,515 Views)

That's mostly correct, but get rid of the Evaluate call, it should be like you have it in the commented out part instead. It worked for me in a sequence I just tried it in. Perhaps you are checking for the wrong button index.

 

I've attached an example TestStand 2010 sequence file which illustrates this is working. If you press the first button the second step is skiped because it goes to cleanup, if you press the second button then it does not.

 

-Doug

0 Kudos
Message 8 of 11
(3,509 Views)

I don't understand why because I have exactly the same settings.

But yours work fine, thank you 😉

 

I gonna to do some search before create a new topic about message popup response ^^

 

Thanks.

 

Alex

 

0 Kudos
Message 9 of 11
(3,499 Views)

There must be some subtle difference in what you are doing. Try setting a breakpoint and making sure that the button index you are expecting is the one that is actually getting set.

 

-Doug

0 Kudos
Message 10 of 11
(3,493 Views)