LabVIEW 2010 Simulation Interface Toolkit Help
»View Product Info
Complete the following steps to build a model in The MathWorks, Inc. Simulink� application software that generates a sine wave.
||Note��You can find an example of this model in the labview\examples\Simulation Interface\Sine Wave directory.
- Launch the The MathWorks, Inc. MATLAB� application software on the host computer. The command window displays the following message:
Starting the SIT Server on Port 6011
SIT Server started
This message indicates that the SIT Server is running.
- Enter simulink in the command window to launch the Simulink� Library Browser window.
- Place a Sine Wave block, located in the Math Operations library, in a new model window.
- Place an In1 block, located in the Sources library, in the model window.
- Place a Sum block, located in the Math Operations library, in the model window.
- Place an Out1 block, located in the Sinks library, in the model window.
- Place a SignalProbe block, located in the NI SIT Blocks library, in the model window.
||Note��The LabVIEW Simulation Interface Toolkit uses the SignalProbe block to probe the signals in the model. The SignalProbe block must be on the top level of the model hierarchy. You can have only one SignalProbe block per model file. Do not rename the SignalProbe block. Do not change the name of another model block to SignalProbe. If you installed the MATLAB application software files as read-only, you must modify the matlabrc.m file to see the SignalProbe block in the Simulink Library Browser window.
- Wire the sources, functions, and signals together so the model looks like the diagram in the following figure:
- Save the model as sinewave.mdl to an easily accessible location.
Setting Simulation Options
Complete the following steps to change simulation options in the Simulink application software.
For the MATLAB application software release 13, select Simulation�Simulation parameters to launch the Simulation Parameters dialog box.
For the MATLAB application software release 14 and later, select Simulation�Configuration Parameters to launch the Configuration Parameters dialog box.
- Click the Solver tab.
- Enter inf in the Stop time text box. inf specifies that the simulation runs until you stop the simulation.
- Set the Type option to Fixed-step in the Solver Options section.
- Click the OK button to return to the Simulink application software window.
- Save the model.
The LabVIEW Simulation Interface Toolkit might not be able to probe signals from models that use Signal Storage Reuse or Block Reduction Optimization. Additionally, the Simulation Interface Toolkit might not be able to probe signals that originate from Virtual Blocks. If the model uses any of these options or blocks, you can mark individual signals as test points. Refer to the Simulink documentation for information about these and other simulation options you can set.
||Note��You can see a completed version of sinewave.mdl in the labview\examples\Simulation Interface\Sine Wave\ directory.