LabVIEW 2012 Control Design and Simulation Module Help
»View Product Info
The previous section provided information about configuring Simulation functions using the configuration dialog box. Instead of using the configuration dialog box, you can improve the interactivity of a simulation by creating front panel controls that configure a Simulation function programmatically. Complete the following steps to configure the Stiffness function programmatically.
- If you are not already viewing the Context Help window, press <Ctrl-H> to display this window.
- Display the block diagram and move the cursor over the Stiffness function. Notice this function has only one input terminal.
- Display the configuration dialog box for the Stiffness function.
- Select Terminal from the Parameter source pull-down menu. This action disables the gain numeric control.
- Click the OK button to save changes and return to the block diagram.
- Move the cursor over the Stiffness function. Notice the Context Help window displays the Gain function with the new gain input terminal.
- Create a control for this input, and label the control Stiffness.
- View the front panel. Notice the new control Stiffness. Enter a value of 100 for this control and run the simulation. Notice the behavior is exactly the same as when you used the configuration dialog box to configure the Stiffness function.