How to Use the Calculator |
Use the Calculator step to combine measurements from previous steps to compute new results. The new results can be the outcome of a numeric computation, comparison or logical operation, or a string manipulation.
Calculator Setup Wizard
- Follow the instructions in the Calculator Setup Wizard to select the inputs and outputs you want to use in the calculation.
Main Tab
- In the Step Name control, enter a descriptive name for the step.
- Select numeric, comparison, Boolean, and string operators from the Functions palette and place them on the Calculation diagram. If the Functions palette is not visible, enable Show Functions Palette.
Tip Enable Show Help Window for information about the numeric, comparison, Boolean, and string controls. - Wire the inputs to the outputs using the following technique:
- Use the Wiring tool to move the cursor over an output terminal of a Input Measurement. When you move the Wiring tool over the terminal, the terminal blinks.
- Use the Wiring tool to click the terminal and release the mouse. As you move the cursor across the Calculator diagram, the Calculator step draws a wire between the terminal and the Wiring tool as though the wire were unwinding from a spool.
- Without holding down the mouse button, move the cursor to an input terminal of a numeric, comparison, Boolean, or string control. The second terminal blinks.
- Use the Wiring tool to click the second terminal.
- Wire the output terminal of the numeric, comparison, Boolean, or string control to the input terminal of an Output Result.
- Repeat this process to wire together all of the Input Measurements, controls, and Output Results.
Note Click Edit Inputs/Outputs if you need to change the inputs and outputs that you selected using the Calculator Setup Wizard. Follow the instructions on the tabbed dialog box that appears. Note Broken wires may appear in the diagram, for example when trying to connect an input terminal to an output terminal of a different data type. Click Remove Broken Wires to remove all broken wires in the diagram.
Measurements Tab
- Click Compute Results to compute the results of the diagram and display them in this tab.
Limits Tab
- Enable Step Result Output is True to require the following conditions in order for the inspection to pass:
- The Calculator step finds all of the Input Measurements.
- The result of the computations wired to the Step Result output terminal is True (Pass).
Note By default, the Step Result value is False (Fail) because no wire is connected to the Step Result output.