Saturday, July 28, 2007

TestStand, how it works (Sequences) part 1

Yesterday, I wrote about my vague, rumored history of TestStand...it put me to sleep, too. But I slept really well!

Today, I just wanted to talk a little about how to get started in TestStand. The New User Data sheet gives a 30,000 foot view of TestStand, the basics of it's structure. My favorite way of getting started on anything is to try it. If you make an account on ni.com and then go this TestStand Download link you can download a 30 day evaluation copy. I believe there is a getting started tutorial that gets you past the basics.

Baically, with TestStand you build test sequences (.seq). That's the start of all things TestStand. A test sequence is a list of steps that do actions, tests, checks, and control. Each step can call and run other programs, run functions in .dlls, diddle (technical term) TestStand variables. make ActiveX calls, call LabVIEW vi's, call other TestStand test sequences, call .Net objects, and probably do a few other things that I haven't tried.

NI took a page from Microsoft ole, their products integrate well together. But one thing NI did much better than Microsoft is integrate with other products. Like I noted above, once you have to specified what type of call you are making with a drop down box at the top of TestStand, you can call almost anything. If you have old code, it can be reused in the sequences.

To use a function, say a dll function, first a step is created. To do this right-click and select add a step. A step is created based on the drop down box at the top of the screen. Then a sequence step is highlighted and you hit m (or right-click on Specify Module...) , a Specify module panel pops up. If you're specifying a .dll, either generically made or made using LabWindows, the .dll, functions can be called from a sequence step. One think I really like about TestStand steps is that once you call out a .dll, all the functions defined with the standard dll declspec can be seen from the panel, you don't have to know what functions.

Bonus Note: Actually this can be handy when you have any .dll you can find out what kinds of calls are available. This is good for looking at just about any .dll, playing around with it, figuring out how it works.

Like I indicated, .dlls are just one way to set up a sequence step but, like may parts of TestStand, they can be very useful.

I'll talk more about sequence steps later, give my opinion on the "Panel" programming paradigm.

No comments: