NI TestStand Idea Exchange

About NI TestStand Idea Exchange

Do you have a feature idea for how to improve NI TestStand? Submit and vote on ideas now!

  1. Browse by label or search in the TestStand Idea Exchange to see if your idea has previously been submitted. If your idea exists sure to vote for the idea by giving it kudos to indicate your approval!
  2. If your idea has not been submitted click Post New Idea to submit a product idea. Be sure to submit a separate post for each idea. Note: the TestStand Idea Exchange is not the appropriate forum to submit technical support questions.
  3. Watch as the community gives your idea kudos and adds their input.
  4. As NI R&D considers the idea, they will change the idea status.
  5. Give kudos to other ideas that you would like to see implemented!

The TestStand R&D team is committed to reviewing every idea submitted via the TestStand Idea Exchange. However, we cannot guarantee the implementation of any TestStand Idea Exchange submission until further documented.

Top Authors
cancel
Showing results for 
Search instead for 
Did you mean: 
vrv

Pre/Post-Execution substep

Status: Declined

I'm declining this idea due to lack of community support.

Hello

 

Execution of a single step is a process executing a lot of steps depending on looping and synchronization. Needing the option to call a PreExecuting and PostExecuting step before taking Looping, PreConditions and Synchronization options in consideration and after all other steps are executed. This is intended to custom step types for use with external customers.

StepExecution.png

StepType-SubSteps.png

 

Thanks Vagn

5 Comments
dug9000
Trusted Enthusiast

Please explain your particular use case if possible and why the existing mechanisms are not sufficient.

Thanks,

-Doug

vrv
Member
Member

Sorry for my late reply.

 

Running tests using batch model I would like to measure analog voltages/currents in parallel with NI-DAQ measuring device. NI-DAQ measuring devices cannot handle measuring multiple tasks at the same device in parallel.

SimpleBatchExecution.png 

 

Instead measuring all data in a single task is the procedure.

The problem is which test socket should measure and which test sockets should just fetch data? The obvious answer is: first socket should measure and the rest should fetch.

Next question: How do I know which test socket is the first one? Answer: Use "Batch Synchronization - Serial (one thread at a time)". Answer is not adequate as I don't know which one is the first test socket running the specific step. Below is a couple of things to take in consideration:

1. Lowest test socket runs first.

2. Precondition might disable lowest test socket.

3. Test sockets has finished execution caused test failure (test stops at first failure in our test sequences).

4. "PostResultListEntry" callback is called multiple times if looping (action 23 and 34) in same step

5. "PostResults" callback is called multiple times (action 24 and 35)

6. The step might be in a subsequence called a lot of times why "unique step ID" is not unique.

7. In the test step I can get all Thread Ids in Batch Threads but this information is given at a time before precondition is evaluated.

 

Bottom line - it is difficult to figure out for sure which socket needs to measure.

 

The solution is using 2 steps:

Solution 1:

1. Measuring step with no evaluation (first test socket only including preconditions and ....).

2. Fetch step for all test sockets evaluating measurement.

 

Solution 2:

1. Figuring out which socket is the first socket

2. Measuring and evaluation of measuring.

 

With the proposal of pre/post execution step it would be easy to configure a trigger telling which socket should measure and evaluate, and which sockets who should fetch and evaluate.

dug9000
Trusted Enthusiast

I'm not completely clear on why batch synchronization doesn't solve this problem for you, nor on how pre/post execution substeps would. Perhaps more details would help.

 

One thing you might not be aware of is that you can cancel calling the main code module of a step from a presubstep, thus you might already be able to get a behavior similar to what you are asking for. See the API help for Step.CancelCurrentModuleExecution and Step.CancelCurrentExecution for more details.

 

-Doug

vrv
Member
Member

The Pre/Post-Execution substep will give the opportunity to set/initialize a boolean flag to tell the function if current entry into step execution is new (make DAQ) or remaining testsockets running needing to fetch data.

WireWeaver
Active Participant
Status changed to: Declined

I'm declining this idea due to lack of community support.

https://www.linkedin.com/in/trentweaver