Tutorial: Using a Multisim Design VI in LabVIEW

Multisim Help


Edition Date: February 2017
Part Number: 375482B-01
View Product Info

DOWNLOAD (Windows Only)


Multisim 14.0 and 14.0.1 Help
Multisim 14.1 Help
Multisim 14.2 Help

In this tutorial, you will create and run the following VI in LabVIEW:

This tutorial uses the Multisim design file summer that you can create in the Tutorial: Setting Up the LabVIEW Co-simulation Terminals section, shown below. This is an inverting summer.

  Be sure that a supported version of NI LabVIEW and the NI LabVIEW Control Design and Simulation Module and the NI Multisim LabVIEW Co-Simulation Plug-in are installed before proceeding. For supported versions, refer to the Circuit Design Suite Installation Guide.

Complete the following steps:

  1. Open a blank block diagram in LabVIEW.
  2. Save the VI as summer.vi.
  3.   If the LabVIEW VI is not saved prior to selecting a Multisim design, it is not possible to calculate a relative file path. (The relative file path is relative to the VI, and if the VI is not saved, a relative path cannot be created.) In this case only the absolute path will be used.

  4. Place the Control & Simulation Loop:
  5. From the Functions palette select Control Design & Simulation»Simulation»Control & Simulation Loop.

    A ghost image of the Control & Simulation Loop appears on your cursor.

    Drag the Control & Simulation Loop to the desired size and click to place it on the block diagram as shown in the figure below.



  6. Place the Multisim Design:
  7. From the Functions palette select Control Design & Simulation»Simulation»External Models»Multisim»Multisim Design.

    Move the cursor to the center of the Control & Simulation Loop and click to place the Multisim Design.

    The Select a Multisim Design dialog box appears.

    Enter a file path and file name in the Multisim design area of the dialog box.

    Or

    Click and navigate to summer that you created in the Tutorial: Setting Up the LabVIEW Co-simulation Terminals section of the Multisim Help. If you did not create the Multisim design, you can use ...\samples\Multisim LabVIEW Cosim\summer.

      To locate the samples folder select File»Open samples or click the Open samples button .

    Click OK to close the dialog.

    Stretch the icon until in1, in2, in3 and out display as shown in the figure below.



  8. Place two Sine Signal functions from the Simuation»Signal Generation palette as shown in the figure below:


  9. Double-click the bottom Sine Signal function and set the amplitude to 2 and the frequency to 1.

    From the Functions palette select Mathematics»Numeric»DBL Numeric Constant and place it on the workspace below the bottom Sine Signal function.

    Double-click on the DBL Numeric Constant and set its value to 2 as shown in the figure below.



  10. Place a SimTime Waveform function:
  11. From the Functions palette select Control Design & Simulation»Simulation»Graph Utilities»SimTime Waveform and place it on the workspace to the right of the Multisim Design as shown in the figure below.



  12. Wire the block diagram as shown in the figure below:


  13. Double-click on the input node of the Control & Simulation Loop to display the Configure Simulation Parameters dialog box, and select the appropriate ODE Solver and solver step size.
  14.   For more information about configuring the Control & Simulation Loop, refer to the Control Design and Simulation Module topic in the LabVIEW Help.

  15. Save the VI.
  16. Switch to the Front Panel and size and format the Waveform Chart as desired.
  17. Run the VI. Results similar to the following display:


WAS THIS ARTICLE HELPFUL?

Not Helpful