LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Creating a Test Program

I have a lot of subvis created to test a large number of test boards and would like to create a master test program where I could select from a list of tests to run on each board. I am looking for suggestions or examples for how to implement this. Ideally, the program will have a checklist of all the tests and I would be able to go through and click to activate just the tests that I want to run for each specific board.

0 Kudos
Message 1 of 11
(3,761 Views)

Architecturally this could be a lot better but the snippet below allows you add additional test relatively easily without changing the form of the program (simply add another Boolean and a case in the consumer loop to handle it).  Somebody'll be along shortly to suggest a different architecture (or maybe TestStand), I'm sure.

 

Biggest issues with what I'm supplying:

  1. the way it is coded, all of the test-related Booleans need to be labeled "test N".  The captions could be used to show more user-friendly test names.
  2. Once you hit "run tests" there is no mechanism for stopping the tests and the parent front panel will be unresponsive (although the individual subVI FPs will work if they are visible).
  3. the program will exit as soon as the selected tests complete.  To select different test you'll need to run the program again.

test_server.png

 

0 Kudos
Message 2 of 11
(3,732 Views)

This an easier and more scalable way to implement it.

imagen.pngTests Manager.png

I hope it helps.

 

Kudos and Solved Accepted LOL.

Greetings everyone!!!

Roger Garcia, Certified LabVIEW Developer

HTML tutorial

There are two ways to tell somebody thanks: Kudos and Marked Solutions
0 Kudos
Message 3 of 11
(3,696 Views)

Is  "Tests Manager" only in the newer Labview versions or is it a program you have to download separately? (I only have Labview 2011) And with this program, are you able to run through all the tests at once or is it just one test at a time?

0 Kudos
Message 4 of 11
(3,670 Views)

Hi I'm adding the VIs for your LV version consider that Test1 and Test2 needs to be substituted by your actual subVIs. You also have to modify the Tests Multycolumn Listbox to match your actual test information. In this case you only execute one Test at the time according to your request in the first comment. You can add as many tests as you have to the Test control and to the Case Structure.

 

Greetings!!

Roger Garcia, Certified LabVIEW Developer

HTML tutorial

There are two ways to tell somebody thanks: Kudos and Marked Solutions
0 Kudos
Message 5 of 11
(3,661 Views)

 

Assuming all you individual tests have their own sub-vi, I would use a "Queued State Machine" architecture. Each test would have its own "state" in the state machine

 

You would have a "select tests" state where you select the tests you want to run (or are selected automatically by selecting the bard type) and these test are loaded into the Queue and ran.

 

Here is an example: This program is for testing inverters...

In my "Nominal Operation" state I can select "line mode" or "Inverter mode"  tests to run

 q1Capture.PNGQ2Capture.PNG

The selection loads teh queue with the test sequence I want to run.

 

Q3Capture.PNG

This where I initialize the queue when the program starts, and shows the queued state machine control

 

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 6 of 11
(3,643 Views)

Queued State Machine is a more robust architecture but also requires more time developing it. My first proposal keeps it simple but scalable solution.

 

Greetings!!!

Roger Garcia, Certified LabVIEW Developer

HTML tutorial

There are two ways to tell somebody thanks: Kudos and Marked Solutions
0 Kudos
Message 7 of 11
(3,630 Views)

@RTSLVU wrote:

 

Assuming all you individual tests have their own sub-vi, I would use a "Queued State Machine" architecture. Each test would have its own "state" in the state machine


In a similar vein, there is also the JKI State Machine, which many here will swear by.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 8 of 11
(3,592 Views)

I'v seen you have created another threat related to the same program

https://forums.ni.com/t5/LabVIEW/Writing-Data-to-Excel-File-without-Report-Generation-Toolkit/td-p/3...

So as the other have said you should better use a state machine where you can manage both functions, runing your tests and manage the files reports you want to save.

 

Greetings

Roger Garcia, Certified LabVIEW Developer

HTML tutorial

There are two ways to tell somebody thanks: Kudos and Marked Solutions
0 Kudos
Message 9 of 11
(3,587 Views)

Okay, state machine is what I figured. I was just wondering if there was something similar to Teststand that I did not know about since I am still fairly new to Labview. Thanks for the suggestions everyone.

0 Kudos
Message 10 of 11
(3,552 Views)