NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Different number of testsockets - How to change with expression?

Solved!
Go to solution

Hello,

i have two sequence files which are using two models. The models are set in:

Edit -> SequenceFileProperties -> Advanced

 

Now i need to run the first sequence with only 1 socket and the other sequence with 2 sockets.

But it seems that Configure + ModelOptions is a global setting which is valid for all models.

 

Question is:

How can i do it that model1 is always executing with one socket and the other model with two sockets?

 

Can i add here simply a step into the SequenceFileLoad of the model(s)?

If yes - what is the expression to change the sockets?

 

Thanks

0 Kudos
Message 1 of 8
(1,038 Views)

You can specify Sequence File specific Model options by overriding the ModelOptions callback and set the value of ModelOptions.NumTestSockets

 

santo_13_0-1633614129613.png

 

Santhosh
Soliton Technologies

New to the forum? Please read community guidelines and how to ask smart questions

Only two ways to appreciate someone who spent their free time to reply/answer your question - give them Kudos or mark their reply as the answer/solution.

Finding it hard to source NI hardware? Try NI Trading Post
Message 2 of 8
(1,036 Views)
Solution
Accepted by topic author OnlyOne

Thanks.

How can i do this change directly in the model sequence?

So the one model should ALWAYS run with one socket and the other model always with two sockets

 

Currently in the model the Parameters in "ModelOptions" displays NumTestSockets = 4

 

Thanks

0 Kudos
Message 3 of 8
(1,031 Views)

Could you share how you made it?

0 Kudos
Message 4 of 8
(42 Views)

Not solved yet.
Still changing it manually each time the model changes.

0 Kudos
Message 5 of 8
(30 Views)

santo_13 has described how to do it using the client sequence file.

If you feel confident enough to modify the process model, this should have given you a hint on how to achieve this in the model file directly.

0 Kudos
Message 6 of 8
(26 Views)

The example of santo_13 is not working.

When i add this Callback to a sequence with NumTestSockets = 4 then it still executes only 1 socket as it is defined in the menu -> Configure -> ModelOptions -> Number of Test Sockets

0 Kudos
Message 7 of 8
(13 Views)

I confirmed that it does work:

  • Set Model to batch
  • Change Model Options to 1 Socket in Configure > ModelOptions > Number of Test Sockets
  • Add ModelOptions callback to the client sequence
  • Edit the ModelOptions sequence and add a single Statement Step
  • In the Statement step, set expression to "Parameters.ModelOptions.NumTestSockets = 3"
  • Run sequence and see that 3 socket executions are started and prompt shows 3 sockets

 

0 Kudos
Message 8 of 8
(5 Views)