04-20-2006 05:50 PM
04-21-2006 02:33 PM
Hi gnange,
You have a couple of options here. With both options that I am going to mention, you would need to override the PreUUT callback. Also, since you are going to be keeping track of a global serial number, I would suggest creating a fileglobal variable to constantly poll and update that represents your serial number. Since the implementations of the serial number are of type string, anytime you increment this value, you first need to change this value to a numeric, then add one, and then change it back to a string.
First off, by default the serial number GUI that popups is caused by the modelsupport2 dll found in the C:\Program Files\National Instruments\TestStand 3.5\Components\User\Models\TestStandModels (if you have copied over your models folder which I stronlgy recommend). This dll was built using LabWindows/CVI. If you have CVI installed, you could edit that CVI project so it grabs the fileglobal variable, populates the serial box entry with that variable that has been incremented, and then go on from there. Once you have edited the code, rebuild the dll.
The other option is to create your own dialog box with LabVIEW. This maybe an easier option for you if you are familiar with LabVIEW. Just make sure that you pass in your sequence context to your VI so you can access that fileglobal to autopopulate the serial box entry. If you do decide to go this route, make sure to update the Parameters.ContinueTesting variable.
Hope this gives you ideas on your options.
Best Regards
04-21-2006 03:17 PM
FileGlobals.UUTSerial = Str(Val(FileGlobals.UUTSerial) + 1)
Hope this helps!
Best Regards,
04-23-2006 08:00 PM
Thanks Jonathan. Your phone support last week really helped me get kick started.
I actually ended up doing a pure LabVIEW solution for this. I'll post it to this forum message once I get caught up on my client's project. Essentially, you need to Override the PreUUT callback, pass in the sequence context, create a FileGlobal, and increment it in your LabVIEW callback. It took me a while to understand what I assumed to be a simple mechanism. My experience with the old Test Executive toolkit came in handy here, but I must say that the new TestStand API is quite daunting, but I am quickly coming up to speed. Thanks Again!
01-17-2007 07:43 AM
Hi,
I'm new to TestStand and is performing an to-buy-or-not evaluation.
My need is similar to this thread owner - it can be described as follows:
1) Serial number is picked from a database where serialNumber is defined as unique and autoinc.
2) When the test sequence is started it shall pick first free serial number and "feed" Teststand with it. This is described in this thread.
3) The testing of an UUT can start. When finished, test result and data is stored to database. After that we can start all over with 1) again
The questions:
- Is Teststand using the same variable for serial number (Fileglobal.serial... something) through all situations like teststeps, report, logging etc.
- Do I need Labview /CVI to redefine to default behaviour with the prompt for serial number?
I want to prompt, but with my own serial number displayed. Optionally I want to use an barcode scanner to read the serial number, then check with database if the number is unique. If ok, we can continue.
Regards
Magnus
01-17-2007 03:17 PM
Hi,
Yes
Seeing as you are going to use a barcode scanner to obtain the serial, you could use the MessagePopup step to display and prompt the user, you can you the database steps to do your querying, so there's a good chance you dont need to use LabVIEW/ CVI/ C++/ VB/ C# ..
Regards
Ray Farmer
01-18-2007 07:43 AM