NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Multiple Numeric Limit Step - Variables

Hi all,

 

I have a problem concerning TestStand (TS).

 

I'm using LV 8.6 with TS 4.1.1 and would like to gain access to the TestStand (TS) variable used within a Multiple Numeric Limit Test step to hold the limits array measurement name (Step>LimitsTAB>Measurement Name). I have looked in the manual with no avail.

 

I believe I have found the step name variable (the name within Step>Properties TAB>General>Name).

This is: 'NameOf( parameters.step)', this is within our 'SequenceFilePostStepFailure'.

  

Basically we are doing the following:

  

1. Use Sound & Vibration tool kit to acquire frequency response measurement/readings into TestStand's NI_MultipleNumericLimitTest step, 'Step.NumericArray' . We name this particular step '11.2.5 Response'.

 

2. Within the test step we enter hard coded limits (Limits TAB) for each frequency i.e. index 0, Measurement Name = '315Hz', Settings = '>=-35 And <=-8', etc

 

3. On TS running the step, TS steps through our 11 element readings array and evaluates each reading against the associated limits.

 

4. On completion of the step, should TS detect that a reading was out of limits, we have ticked 'Step failure causes sequence failure' for the step, thus a failure is noted.

 

5. As part of finalising the test sequence our step 'SequenceFilePostStepFailure' further down the sequence is evoked.

 

This step contains:

 

UUTFailDetected         FileGlobals.UUTFailed.UUTFailDetected = True

FailedTest                    FileGlobals.UUTFailed.FailedTest = NameOf( Parameters.Step)

FailedSequence            FileGlobals.UUTFailed.FailedSequence = NameOf (RunState.Caller.RunState.Sequence)

 

6. The problem we have is with the FailedTest statement above. Currently it only produces the step name, i.e. '11.2.5 Response' (as mentioned above in 1.). We would like to concatenate to this the first frequency to fail from the multitest step. This would then produce the string '11.2.5 Response 315Hz'. Where '315Hz' is defined as 'Measurement Name' (array element of) by the multistep.

 

Q1. Can anyone provide an example of how we would modify the FailedTest statement above to do this?

 

Q2. There may be a requirement to make this conditional, i.e. If the step name prefix = '11.2.5' then add the frequency string '315Hz'. Can anyone provide an example of how to do this?

 

Q3. Does anyone know where the list of these system variable are kept? i.e. NameOf( Parameters.Step), etc

 

Many thanks in advance to anyone who can help us on this one. Our repair technicians will appreciate this greatly as currently the fault description is somewhat vague!

 

Regards

 

Andy

0 Kudos
Message 1 of 4
(4,376 Views)

I'm a newbie but I have played around with the Result.Measurement "object" in VB.NET. Basically, what I did to get the Measurement name was to get a property object for "Results.Measurement" then to get a property object for the individual Measurement element (called elementPropObj). Then I was able to get the measurement name by simply calling elementPropObj.Name.

 

I haven't tried this, but I assume you can use the same approach from within TestStand using the API.Then you could append it to the FailedTest string.

 

Hope this helps.

 

P.S. I have found the GetXML method of a property object very helpful in seeing what is available and what things are called.

0 Kudos
Message 2 of 4
(4,346 Views)

Hello Andrew,

 

I hope you are well. I would like you to please see the attached sequence file for TestStand 4.1 or greater. It contains a method for searching through the results of the Multi-step test and searching for the first failed frequency. The frequency is then added to the name of the sequence as a string, and displayed for the Operator. I believe this fulfills your original specification.

 

The sequence file is a simplified version of your test, where I have isolated sequence "11.2.5 Response". I have then also created several local variables. 'UKSupportFResponse...' is an array of strings created for testing. I have set it so that "400 Hz" is the failed frequency. You can manually change the values from the 'Variable' window on the right for further testing before you incorporate the steps into your full sequence.

 

There are a few Knowledgebase articles online that can be referenced regarding some of the expressions that I experimented with and ultimately used.

 

Names of TestStand Properties

 

The 'For Each' flow control is used to parses through every element of the Multi Step and pick out the measurement name.  The 'While' flow control is used to ensure that only the first failed frequency is considered, as per your situation.

 

Regards,

George T.
Senior Applications Engineer
National Instruments UK and Ireland
0 Kudos
Message 3 of 4
(4,220 Views)

Hello again,

 

This Sequence File is now attached.

 

Regards,

George T.
Senior Applications Engineer
National Instruments UK and Ireland
0 Kudos
Message 4 of 4
(4,218 Views)