NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

looping of a profile in single pass

Hi all,
 
In the C# OI customization, i have to execute single pass either through looping or only once based on the user choice. How can this be achieved?
 
To perform single pass only once i have used the following connection:

SequenceFileViewMgr.GetCommand(

CommandKinds.CommandKind_ExecutionEntryPoints_Set, 1).Execute(true);

How to modify this to perform looping of single pass for a profile?

Hope the query is clear.

Thanks and Regards,
MadhuSri
0 Kudos
Message 1 of 5
(3,561 Views)
Hey MadHuSri,

Usually the way this is implemented is through the execution entry points of your process model.  For example in the sequential process model provided by TestStand there is a single pass execution entry point and there is a test UUTs execution entry point.  The Test UUTs entry point essentially loops over the single pass.  I believe this would be the easiest solution.  Is there a particular reason you were not using the Test UUTs entry point?  You can execute the Test UUTs entry point by using the code I posted below.  This is assuming you are using the default sequential model.

SequenceFileViewMgr.GetCommand(CommandKinds.CommandKind_ExecutionEntryPoints_Set, 0).Execute(true);

Pat P.
Software Engineer
National Instruments
0 Kudos
Message 2 of 5
(3,542 Views)

Hi Patrick,

I do not want to use Test UUTs entry point because it displays a pop-up for the looping concept. The loop continues until we stop it manually. But my requirement is i have the loop count defined and i want the profile to iterate for so many number of time continuosly. Every time the iteration is done the UUT serial number is the same and there's no change in it. So i would not need the serial number pop-up window also.

Thanks and Regards,

MadhuSri

0 Kudos
Message 3 of 5
(3,528 Views)

Hi,

The only way you are going to run the same sequencefile several times in succession is,

a) have a modified process model that enables this facility.

b) a modified Operator Interface that allows this.

The only other way would be to utilities the Interactive mode eg "Loop on Selected Step using" .

Regards

Ray Farmer

Regards
Ray Farmer
0 Kudos
Message 4 of 5
(3,525 Views)
Hey MadHuSri,

Ray is completely correct in the different methods to implement this.  To expand a little on one of the methods Ray mentioned, I believe it would be fairly easy to modify your process model to take out the dialogs for the serial number.  The dialog for the serial numbers can be removed by overriding or modifying the Pre UUT callback.  I believe you could also place code within your own Pre UUT callback to determine how many loops you would like to execute.  There is a variable called ContinueTesting that determines whether the test stops or tests another UUT.  You could add some logic to keep track of the total number of UUTs tested and stop the test after the desired number of loops. 

Also, if you want to remove the dialog window telling you whether a test passed or failed, you can override the Post UUT callback.
Pat P.
Software Engineer
National Instruments
0 Kudos
Message 5 of 5
(3,511 Views)