NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Get ALL Steps name using TestStand API

Solved!
Go to solution

Hi All,

 

I am trying to read all the steps in a TS Sequence using the TS API. I have successfully been able to get the steps in the MainSequence, but I am looking for a solution to get ALL the steps, even the ones in a sequence call.

 

Can you give me some pointers.

 

TIA.

Download All
0 Kudos
Message 1 of 11
(785 Views)

can you explain more please ?  what output you need ? 

CLA
0 Kudos
Message 2 of 11
(775 Views)

I need the step names & the Unique Step ID of all the steps in the Sequence, including the subsequences.

0 Kudos
Message 3 of 11
(766 Views)

write this in any pop msg or expression you get step name

RunState.Sequence.Main["Step5"].name

CLA
0 Kudos
Message 4 of 11
(762 Views)

I need to get all the sequence names using the TestStand API and loop through them all to get their step names (Is my guess), I also need to do this in LV. The VI I attached is where I have managed to get the step names in the mainsequence, but I am stuck as to how to do this for all subsequences.

0 Kudos
Message 5 of 11
(752 Views)

ok make like that : for loop with 9 loops and local.stepnum as incrementer 

Ahmed99_0-1722580224488.png

Ahmed99_1-1722580265075.png

and so on 

CLA
0 Kudos
Message 6 of 11
(739 Views)

I might not be explaining this correctly, but I need the solution in LabVIEW. The TestStand Seq is just to test the code out.

0 Kudos
Message 7 of 11
(734 Views)

ok you just need to make the ID and name arrays as output in connector pane then they appear in module load you can put them in local variables and use them

Ahmed99_0-1722584111651.pngAhmed99_1-1722584131003.png

 

CLA
0 Kudos
Message 8 of 11
(723 Views)

If you notice, inside that last sequence call there is another step, I need that step name as well, the current VI I posted, gets upto this point. I need the step name inside the sequence call.

0 Kudos
Message 9 of 11
(714 Views)

From what I understand, you need a possiblity to analyze the steps in the subsequencess being called as well.

 

So, from in your toplevel sequence, you need to analyze all the test steps, if any is a SequenceCall (Step.StepType.Name == "SequenceCall").

 

If so, you will find the information about the sequence being called in the Step.SData container

 

you need to cover three cases:

 

- UseCurrentFile (Step.TS.SData.UseCurFile == True)

- "regular calls" to arbitrary sequences in sequence files (Step.TS.SData.SFPath, Step.TS.SData.SeqName)

and

- Calls Specified by Expression (Step.TS.SData.SpecifyByExpr == True)

 

though tis last one is not neccessarily analysable during develkopment.

 

If you are wondering, where this Step.SData is coming from:

 

Oli_Wachno_0-1722573764316.png

 

But you have to make the following setting first

 

Oli_Wachno_1-1722573809723.png

 

0 Kudos
Message 10 of 11
(699 Views)