This example demonstrates a test program that uses four sites and three shared instruments, as shown in the following figure. The test program shares the DMM1 instrument across all four sites and shares the DMM2 and DMM3 instruments across two sites each. All three instruments contain only one channel routed to each site using a switch (MUX).

Note Run-time site order is not guaranteed to be in any particular order. Site order depends on the arrival order at the executing step.


Example File Location <TestStand Public> \Examples\NI_SemiconductorModule\Switching\LabVIEW\Switching.seq
Highlighted Features
  • Pin map
  • Multisite
  • Switching
Major API
  • TSM Code Module API
  • Switch Executive API
Prerequisites
  • You must have the LabVIEW Development System installed, and you must configure the LabVIEW Adapter to use the LabVIEW Development System.
  • You must have NI-Switch 15.0 or later installed.
  • You must have Switch Executive 2015 or later installed.
  • This example uses the Batch process model.

You must also configure the switch instruments and route in Measurement & Automation Explorer (MAX) to be available through Switch Executive Virtual Devices. This example includes the SwitchingConfiguration.nce NI Configuration Export File to import an example configuration into MAX. To import the file, open MAX, select File » Import, and browse to the SwitchingConfiguration.nce file in the resulting dialog box.

Complete the following steps to use this example.

  1. Complete the following steps to review the pin map file associated with the test program.
    1. Select Semiconductor Module » Edit Pin Map File, click the Edit Pin Map File button on the TSM toolbar, or launch the Test Program Editor and click the Open file for edit button located to the right of the Pin Map File Path display on the Pin Map panel to open the <TestStand Public>\Examples\NI_SemiconductorModule\Switching\LabVIEW\Switching.pinmap file in the Pin Map Editor. The pin map file defines the following information:
      • Two DUT pins named A and B, respectively.
      • Three multiplexer switch instruments named Mux1, Mux2, and Mux3, each with a multiplexerTypeId attribute value of NISimulatedMultiplexer.
      • Three DMM instruments named DMM1, DMM2, and DMM3, each with one channel.
      • Four sites on the tester.
      • A set of multiplexed connections, in which each connection specifies an instrument and instrument channel and contains a list of connection pin routes. Each route specifies a site, route name, multiplexer, and pin to which it is connected.
  2. Select each step in the MainSequence sequence and click the Tests tab on the Step Settings pane to review the tests each step performs.

    The Semiconductor Multi Test step type uses the information in the pin map to determine which sites, instruments, and instrument channels to use for a particular test. The first step uses DMM1, which is shared across all four sites, to test pin A on each site. The second step uses DMM2 and DMM3, which are each shared across two sites, to test pin B on each site.

  3. Click the Options tab on the Step Settings pane to review the DUT pins specified for each step and the multisite execution that the step uses.

    The first step specifies only DUT pin A. The step uses the pin map to determine that only one instrument is connected to pin A for each site and that a switch routes the channel to each site. With this information, the step determines that all four sites must run in a single thread and only one instance of the code module executes, as shown in the Multisite Execution Diagram.

    The second step specifies only DUT pin B. The step uses the pin map to determine that two instruments are available and each connects to DUT pin B on independent sites. With this information, the step determines that it is able to run the code module in two independent threads, as shown in the Multisite Execution Diagram.

  4. On the Sequences pane, select the ProcessSetup sequence. The steps in this sequence initialize the custom instruments and switches.
  5. On the Sequences pane, select the ProcessCleanup sequence. The steps in this sequence close instrument and switch sessions.
  6. Open <TestStand Public>\Examples\NI_SemiconductorModule\Switching\LabVIEW\Switching.lvproj to review the code modules the test program uses. The Example Test Code VI demonstrates a test code module that uses multiplexed routes. In the VI, each iteration of the For Loop tests one site. The tests for each site execute serially in a For Loop because the tests share an instrument. Do not enable loop iteration parallelism in the For Loop.
    Note The For Loop must also close each reference in the array of Semiconductor Module contexts because the references were generated in LabVIEW instead of in TestStand and will not be closed automatically.
  7. Click the Start Lot button on the TSM toolbar to run the test program.