NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Change type of UUT serial number

Solved!
Go to solution

Hello,

 

I am a new user of Teststand and I would like change the type of the UUT serial number.

or add condition of the serial number the operator write in the UUT Information dialog box.

 

I want the serial number which just have 20 number and no letters.

if the serial number is different, the dialog box must reappear like at the begining.

 

Hope I have been clear.

 

Thanks

0 Kudos
Message 1 of 8
(5,960 Views)

In your PreUUT callback you will need to set the Parameters.UUT.SerialNumber value to the desired setting. You can use the String functions in TestStand to do checks on your string to make sure it is formatted correctly. If it isn't, you can use logic in your code to display a popup to the user asking for the correct serial number.

CTA, CLA, MTFBWY
0 Kudos
Message 2 of 8
(5,956 Views)
Solution
Accepted by topic author AlexTestStand

You will need to override the PreUUT callback and then build some sort of algorithm to check for the desired serial number.

 

I've attached one example of how to do it.

jigg
CTA, CLA
testeract.com
~Will work for kudos and/or BBQ~
Message 3 of 8
(5,955 Views)

thank you snowpunter and jiggawax,

 

jiggawax, the example you gave me is exactly what I need.

but I don't understand how it works.

because you used just 3 locals variables, SerialNumber, ValidNumber and ValidSerialNumber.

none of them have a number type, SN has a string type, VN and VSN have a boolean type.

How did you do to say the SN must be just a number ?

 


0 Kudos
Message 4 of 8
(5,938 Views)

In the Check Serial Number step there is a function  called Val.  It sets Locals.ValidNumber to true if Locals.SerialNumber is indeed a number.

 

The Len function is validating the length is 20.

 

Hope this helps,

jigg
CTA, CLA
testeract.com
~Will work for kudos and/or BBQ~
0 Kudos
Message 5 of 8
(5,918 Views)

ok I don't have more question about it, everything is clear (for this ^^) !!

 

Thank you so much for your help !!

0 Kudos
Message 6 of 8
(5,916 Views)

Hi jigg,

 

If the seq is running under batch UUT test, how to disable UUT Information, Is it the same way? I have tried to override the PreUUT you posted, but It still displayed on the screen.

 

Cheers.

 

Jimmy

0 Kudos
Message 7 of 8
(5,708 Views)

In the BatchModel.seq, the Serial Number is requested in the PreBatch sequence instead of the PreUUT.  modelsupport2.dll loads and displays the Panel that asks for the Serial Number.  It asks for serial numbers for every socket at once.

0 Kudos
Message 8 of 8
(5,676 Views)