NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

how to write teststand Process model in proper order

Hi all,

This is my first post on NI Discussion forum,and I hope you people help me come out this problem.

Firstly It will be better to tell you about my experience in LabVIEW and TestStand so that you can understand my frame of mind.

 I have around 18 months of development experience that states that I am good in LabVIEW .In TestStand I have completed Course manual 1 & 2 thorouhly . But I am still confused about how to fullfill our requirements.

 

My system requirement are as follows-

 

We need to perform Series of test say Test1 ,Test2 ,Test3, .......

 

Each test are responisble to communicate with diiferent Instruments. The Difference among the tests are only that tests has only some parts which are different from other. e.g lets Test1 has following flow..

 

Test1: Instrumrnt A

           Instrument B

           Instrument C

           Instrument D

           Instrument FR

           Instrument RG

 

Test2: Instrumrnt A

           Instrument B

           Instrument C

           Instrument D

           Instrument FR

           Instrument RG

Test3: Instrumrnt A

           Instrument B

           Instrument C

           Instrument D

           Instrument FR

           Instrument RG

Only different colors interactions are different .

What I decided that I will make the call back of all the sequences and keep them into the process model and code which will be differ will only be use as a override callback in a testspecific client sequence file.

 

Now the problem is that we can override the callback of processmodell in clients sequence file(Say Test1)only if procees model knows that there is a client sequnce file ,which is intended to override its own callback .

 

Normally when we run the sequence than process model detects that there are modified callbacks in the client sequence file so when execution pointer reaches callback sequnce in Process model it executes the sequence of client sequncefile version.

 

So please tell me the way how can differnt testFile continuously run using single teststand model.

 

 

Regards:

 

Vaibhav Kanchan

Regards:

Vaibhav Kanchan
Sr. Engineer
NI Certified LabVIEW Developer(CLD)
NI Certified TestStand Developer(CTD}
0 Kudos
Message 1 of 9
(4,358 Views)
I'm really confused about what you are doing. The process model typically has no idea what tests are or are not in a test sequence file and imho, should not know or care. I would not recomend placing custom callbacks in the process model. If Test 1, Test 2, etc. are different sequence files, then each sequence file would have the appropriate tests calls to internal or external subsequences. You can also make a single client sequence and control which tests are run or not run or what values are passed or not passed with preconditions and a few simple Statements.
Message 2 of 9
(4,349 Views)

Vaibha,

 

I'm not sure I fully understand your requirements either, but in general, tests directly related to your UUT should go in the client sequence. Process-related operations would go in the Process Model. You don't need to override any Process Model callbacks to do this.

 

The process model usually contains operations that happen before and after the client sequence (UUT Test) is executed. Here's an example

 

-- Process Model --- Pretest

Init database

Barcode the UUT

 

-- Client Sequence ---

set switch

power on

RAM test

ROM test

Noise test

power down

reset switch

 

-- Process Model --- Postest

Display Pass-Fail Banner

Save Report file

Log data to database

 

This is just the most general case and of course you can make any type of customization you desire.

 

Why not just put all your tests, TEst1, Test2, Test3 etc. in one, main client sequence file, just like the example Computer Motherboard Test? I am guessing you are making it too complicated. 🙂

 

I would definitely not put your Tests in the Process Model, though a common customization is to put an instrument initialization (or instrument check) test in the Process Model.

 

cc

 

0 Kudos
Message 3 of 9
(4,323 Views)

 

Hi


OK I will try to explain the requirements again..
Each Test is doing communcation with instruments in fixed order, I am thinking of putting all such instrument specific communication and its order in Process model as it is common accross all the tests.
Now, i am also willing to give user the flexibility to change the order of the communication and also wanted to give the user felixibilty to change the steps for communication for each instrument (The requirement above, will not be so frequently used but i want to give user the chance of upgrading the system without making any changes to the Process model). now taking an example again from my previous post.
What i can do is..

 main sequence->> Subsequence in Process Model ->> this callback will contain the sequence of calling instruments as follows
  {
   Instrument A ->> Subsequence for instrument A which will be made callback.
   Instrument B ->> Subsequence for instrument B which will be made callback.
   Instrument C ->> Subsequence for instrument C which will be made callback.
   Instrument D ->> Subsequence for instrument D which will be made callback.
   Instrument FR->> Subsequence for instrument FR called Dynamically from a Test Specific Client Sequence File.
   Instrument RG->> Subsequence for instrument RG called Dynamically from a Test Specific Client Sequence File.
  }

So if User wants to change the Sequence of Instruments call then, for a specific Test (not all) user can just call a main sequence callback in the executing sequence file and make his custom flow i.e. overide the process model flow.
or if user wants to change the steps within the Instrument A sequence then he can directly only use the callback of Instrument A in his sequnce file.

Maybe you are right that i am making the things complicated (can be wrong also) but kindly suggest if there is any other simpler way.

 

Regards-

Vaibhav

Regards:

Vaibhav Kanchan
Sr. Engineer
NI Certified LabVIEW Developer(CLD)
NI Certified TestStand Developer(CTD}
0 Kudos
Message 4 of 9
(4,308 Views)
I understood the requirements the first time but what I still don't understand is why you want to place the tests in the process model instead of a test sequence. You can accomplish the same thing and keep the process separate from the tests. One sequence file and subsequences with the tests in the default order can be called. Or, it another programmer wants to call the tests out of order, the specific subsequence can be called.
0 Kudos
Message 5 of 9
(4,297 Views)

It is true that in general one should look at what is the same across all different products and tests and consider moving that in to the Process Model. However an "overriding" concept is that process goes in the Process Model and UUT-specific test goes in the client sequence. The Process Model contains things that happen before the test, and things that happen after the test, not the test itself.

 

One problem with your solution is, you will not be able to change the order of the subsequences in the process model from the client. You can only override them from the client, you can't repeat them or execute them out of order. The execution flow of the model callbacks is defined in the process model, not in the client. Where are you going to put the subseqeunces in the Process Model, right before the main sequence call? You know the results are collected into Locals.ResultsList[0] in the execution entry point of the Process Model. That's not going to work either if you put those subseqeunces in Test UUTs sequence.

 

I guess you could copy all your subseqeunces iinto the Process Model  .seq file, but you should call them with the seq call step from your client sequence, there would be no overriding.

 

 

I mentioned before the case of putting instrument init model callbacks in the Process Model. The client can suppress them when selected instruments are not present, or replace them for different instruments. I thought of another case. I had a Process Model that controlled the test environment for design verification testing. This Process Model would set temperature, UUT power level, and noise on the power line, and then call main sequence. It was a looping Process Model so the same main sequence could be run repeatedly while sweeping different conditions. But still,even though the Process Model was talkiing to instrumentation, it wasn't for the purpose of running the test on the UUT. Hope this helps get an idea of how to use the Process Model.

 

ps Hi Dennis.

0 Kudos
Message 6 of 9
(4,288 Views)

Actualy I am not keeping different tests into process model .I am keeping sequences as a callback into a "Mainsequence", a callback of process model.
So if user want to change the flow of instument than he can override "Main Sequence" in client sequence file.otherwise he can override testspecific sequence only.Regarding result collection, common sequence callback's are for Test setup so there is no need of result collection.Test specific sequence which are going to override process model callback are only responsible for result collection.

e.g. main sequence Callback->>we can override it and can change the flow of execution(It consist following calbacks)
  
   Instrument A callback ->>It will configure the instrument A.
   Instrument B callback ->>It will configure the instrument B.
   Instrument C callback ->>It will configure the instrument C.
   Instrument D callback ->>It will configure the instrument D.
        

                                                                                    above calabacks will be used to make initial test setup 


   Instrument callback FR->> This callback sequence is test specific which causes result so we can override accordingly.
   Instrument Callback RG->> This callback sequence is test specific which causes result so we can override accordingly.


So if we are performing Test1 , application will configure the instruments A,B,C and D by using corresponding callback and than peform test by dedicated overided FR,RG callbacks.

 

I am atttaching an example code which will help you to understand my approach.....
Please find it in the attachment


Please tell me wheather this approach is right or wrong.Is it contradicting with the traditional approch of process model development,means Is it a hard and fast rule that the Process Model should contains things that happen before the test, and things that happen after the test

 

I am waiting for your expert comments...
  
Thanks in advance

Regards:

Vaibhav Kanchan
Sr. Engineer
NI Certified LabVIEW Developer(CLD)
NI Certified TestStand Developer(CTD}
0 Kudos
Message 7 of 9
(4,246 Views)
Still waiting for reply.
Regards:

Vaibhav Kanchan
Sr. Engineer
NI Certified LabVIEW Developer(CLD)
NI Certified TestStand Developer(CTD}
0 Kudos
Message 8 of 9
(4,222 Views)

Hi,

 

I guess you can put all of them in the process model.

 

For the first 4 tests you need not even make them callbacks as you are not making any modifications in them at all. The other two need to be callbacks. And there is no problem in your technique/method.

.......^___________________^
....../ '---_BOT ____________ ]
...../_==O;;;;;;;;_______.:/
.....),---.(_(____)/.....
....// (..) ),----/....
...//____//......
..//____//......
.//____//......
..-------
0 Kudos
Message 9 of 9
(4,194 Views)