08-22-2018 08:21 PM
Hello,
I'm new to TestStand (2016 version) and I would like to find out how I may use a vi that reads a UUT's serial number to automatically input that result into TestStand's "Enter UUT Serial Number" pop up dialog box, thereby avoiding manual entry (which could avoid errors), then have it automatically run the test without clicking on "OK".
I searched this topic in the forum but I still cannot figure out how to set up the PreUUT Sequence Callback in order to achieve this. I would still like to have the serial number be written to the report. Thank you.
Sincerely,
Andie
Solved! Go to Solution.
08-22-2018 10:30 PM
The key words you need to google are Override PreUUT Callback. There are hundreds of examples and things out there that show how to do this.
Here is one that ships with 2016:
https://zone.ni.com/reference/en-XX/help/370052R-01/tsexamples/infotopics/callbacks_preuut/
It is CVI example but you can just replace the call to the CVI code with the call to your LabVIEW code.
The key with overriding the PreUUT callback is that you need to set the serial number and the continue testing parameters.
Let me know if you have any specific questions I can help answer.
Cheers,
08-23-2018 05:24 PM
Hi Jigg,
Thank you for the link to the 2016 TestStand example "Overriding the PreUUT Callback.seq". I did a similar thing and the pop up dialog that asks to enter the serial number no longer pops up, which is good! Thanks! But I'm still missing at least 2 things.
1.) In the example, there's a function statement:
Parameters.UUT.SerialNumber = Locals.SerialNumber
I inserted this same statement (in .seq file), but how do I pass the serial number read from my vi to Locals.SerialNumber? The report says the SN is None.
2.) Since it is now overridden, I need to provide a way to stop the test, which in the example, the CVI dll provides a popup. However, I cannot see how things are done inside the dll. (We also don't have CVI.) I thought I could do it with a Message Popup, under Action, but I didn't see a Stop selection or any other way to do it. (I stopped it from TestStand's menu bar.) Can you point me to an example of how to provide a popup that stops the test from TestStand? Or is this something I need to implement in LabVIEW?
Lastly I did a search with the right keywords and saw many, many hits. But most were examples from different versions of TestStand.
Sorry for the basic questions, but I've just started using TestStand. I think if I can get the two items above, especially passing the serial number read from the vi, we can get our tests going. Thanks in advance.
Sincerely,
Andie
08-24-2018 12:25 PM
I threw together a simple example that demonstrates both.
08-24-2018 03:38 PM
Thank you so much Jigg!!! The simple examples are perfect and answered both of my (simple) questions. It was the parameter value of the serial number (in PreUUT) that had confused me the most (from when I was reading other examples). Also you made it clear that I have to handle the stop testing condition myself outside of TestStand.
I'm so excited and thankful that this is clear now. It's too bad the system won't let me give you a million Kudos! Thanks again!
Sincerely,
Andie