NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

how to set UUT serial number

Dear all,
 
How to set UUT serial number programmatically. i know TestStand storing the serial number in some variable. Please give the path of the this variable.
 
Also in multi UUT (batch) how to set each UUT serial number of each UUT thru coding.
 
Thanks and Regards,
Srini 
0 Kudos
Message 1 of 7
(5,902 Views)

Hi Srini,

Try this example on this link

http://forums.ni.com/ni/board/message?board.id=330&message.id=7873&query.id=21677#M7873

Regards

Ray Farmer

Regards
Ray Farmer
Message 2 of 7
(5,900 Views)
Dear RAY,
 
I have tried out the following codes in PostUUT callback of a sequence file but it is not assigning the serial number. please help.
I have created a Local varibale in postuut sequence SN1 which which will hold the serial number.
 

Parameters.UUT.SerialNumber = Locals.SN1

and

Parameters.ModelData.TestSockets[0].UUT.SerialNumber = Locals.SN1

The above code we tried out using function step in test stand. even we tried out to set SN thru programatically by using the following code

//Sets the Serial Number for the socketId of the current execution

execution.GetThread(0).GetSequenceContext(0,

out frameId).Parameters.SetValString("UUT.SerialNumber", 0, CommonGuiClass.multiBmuSerialNo[socketId]);

Thanks in advance

Srini

0 Kudos
Message 3 of 7
(5,878 Views)

Dear Ray,

Thanks for ur response.

 The following code sets the serial number in case of batch execution in the ApplicationManager.StatrtExecution event:

//Sets the Serial Number for the socketId of the current execution

e.exec.GetThread(0).GetSequenceContext(0, out frameId).Parameters.SetValString("TestSocket.UUT.SerialNumber", 0, CommonGuiClass.multiBmuSerialNo[socketId]);

The serial number is getting reflected in the report. But i am not able to fetch the serial number from 'CaptionSource_UUTSerialNumber'. Where should this serial number be assigned alyernatively to retrieve it using 'CaptionSource_UUTSerialNumber'

Thanks and Regards,

MadhuSri

0 Kudos
Message 4 of 7
(5,871 Views)

Dear Ray

I set the serial number using preUUT callback by the following expression

Parameters.UUT.SerialNumber = FileGlobals.SerialNumber[Parameters.UUT.TestSocketIndex]

where in file globals i have create string  array which holds all the UUTs serial numbers( FileGlobals.SerialNumber[])

This works perfectly for TestUUT but when i use single pass it doesn't show me the serial number in the combo box (Execution Change combo box in batch uut). Please tell me the difference between TestUUT - Test Socket Entry Point and TestUUT sequence in Batchmodel. also i have seen the single pass sequence doesn't call the preUUT callback why it is?

Thanks and Regards,

Srini

 

0 Kudos
Message 5 of 7
(5,852 Views)

Hi,

The Single Pass does call the PreUUT, but there is nothing to stop you added this a your own copy of the ProcessModel sequence file which you would place in the User folder.

Regards

Ray Farmer

Regards
Ray Farmer
0 Kudos
Message 6 of 7
(5,848 Views)

Hello,

 

I want to restart this topic.

 

I tried to change the serial number in the header of the xml report. It doesn't work.

 

I'm using TestStand 2012 f1.

 

Thank you for help

 

Sven

0 Kudos
Message 7 of 7
(4,852 Views)