You will need to have NI TestStand and TestStand Semiconductor Module installed on your system in order to complete any of the steps.
1. Launch NI TestStand.
2. Select Semiconductor Module » Edit Pin Map File... to launch the Pin Map Editor.
3. Don't edit the pin map file. Click Save button to save the pin map file.

4. Select Semiconductor Module » Edit Bin Definition File... to launch the Bin Definition Editor.
5. Click Add Bin (+) to add a new hardware bin on the Hardware Bins tab.
- Set Number to 4
- Set Name to SpecificErrorOccurs
- Set Type to Fail
6. Click Add Bin (+) to add a new software bin on the Software Bins tab.
- Set Number to 4
- Set Name to SpecificErrorOccurs
- Set Hardware Bin to SpecificErrorOccurs
- Set Type to Fail
7. Click Save button to save the bin definition file.
8. Insert a Statement step to MainSequence.
- Type in Create a Specific Error in the Name text box on the Properties tab
- Type in Step.Result.Error.Code = 1234, Step.Result.Error.Occurred = True, Step.Result.Error.Msg = "A specific error occurs" in the Expression text box on the Expression tab
9. Insert an If step to MainSequence.
- Type in RunState.Sequence.Main["Create a Specific Error"].Result.Status == "Error" in the Conditional Expression text box on the If Condition tab
10. Insert a Set and Lock Bin step from Semiconductor Module Step Types to MainSequence.
- Select 4 - SpecificErrorOccurs from the Bin Expression dropdown menu on the Set and Lock Bin tab
11. Select Edit » Sequence File Callbacks... to launch the Sequence File Callbacks Dialog Box.
12. Select SequenceFilePostStepRuntimeError engine callback and click Add. Now, you can see the SequenceFilePostStepRuntimeError callback show up in the Sequences pane.


13. Insert a Statement step to SequenceFilePostStepRuntimeError.
- Type in Clear the Specific Error in the Name text box on the Properties tab
- Type in #NoValidation(Parameters.Step.Result.Error.Occurred) = #NoValidation(Parameters.Step.Result.Error.Code) == 1234 ? False : #NoValidation(Parameters.Step.Result.Error.Occurred),
#NoValidation(Parameters.Step.Result.Error.Msg) = #NoValidation(Parameters.Step.Result.Error.Code) == 1234 ? "" : #NoValidation(Parameters.Step.Result.Error.Msg),
#NoValidation(Parameters.Step.Result.Error.Code) = #NoValidation(Parameters.Step.Result.Error.Code) == 1234 ? 0 : #NoValidation(Parameters.Step.Result.Error.Code) in the Expression text box on the Expression tab

14. Insert a Statement step to SequenceFilePostStepRuntimeError.
- Type in Set MainSequence to Fail in the Name text box on the Properties tab
- Type in RunState.Caller.RunState.SequenceFailed = True in the Expression text box on the Expression tab
15. Once you complete all the above steps, MainSequnece and SequenceFilePostStepRuntimeError will look like this.


16. Select Semiconductor Module » Show Lot Statistics Viewer to launch the Lot Statistics Viewer window.
17. Click Single Test button to start a lot and test a single DUT.