Academic Company Events NI Developer Zone Support Solutions Products & Services Contact NI MyNI

Input Signals From NI DAQ Device To Drive Your SPICE Based Circuit

8 ratings | 4.12 out of 5
Print

Overview

This example program is part of a series of LabVIEW based virtual instruments that can be used from inside Multisim.  All instruments are based on the virtual instruments templates you can find in your Multisim’s sample folder. There are two main categories of instruments:

  • Input Instrument; takes simulation data from your schematic and processes them in the virtual instrument (e.g. custom display, specific analysis, output to real world).
  • Output Instrument; inputs signals to a Multisim schematic to drive a simulation (e.g. acquire data from real world I/O, custom and arbitrary waveforms).

 

Notes for using real world I/Os with SPICE circuits

Due to the nature of SPICE, all real world data that will be used to drive a circuit need to be acquired before a simulation is started. Data output to a real world device can be done while simulation is running, however continuous updates can’t happen in real-time, as SPICE simulations don’t have a real-time timebase.

 

Purpose Of This Instrument

A key element in the process of integration of design and test is to improve simulation quality by applying real-world data to a SPICE based circuit. There are several ways a Multisim user can use real-world data to drive a circuit. National Instruments dataacquisition devices offer hardware designers a broad range of powerful yet easy to use application options. The LabVIEW based instrument DAQ Source allows you to connect to any dataacquisition device supported by the NI DAQmx driver, including Multifunction IO boards, USB devices and highly specialized series of modular instruments. in order to drive your circuit with real world data. Driving your simulation with real world data will give you a better understanding of your circuit’s behavior.

 

Installation Instruction

Unpack the archive to the Multisim installation directory. The table illustrates the files that will be copied to your harddrive.

 

Type

Name

Location

Application

Instrument

DAQ_Source.llb

..\lvinstruments

Multisim

Example

Test DAQ Source.ms10

..\ samples\LabVIEW Instruments\DAQ

Multisim

Project

DAQ Source.lvproj

..\ samples\LabVIEW Instruments\DAQ

LabVIEW

Source

DAQ Source.llb

..\ samples\LabVIEW Instruments\DAQ

LabVIEW

 

Instrument Features

The DAQ Source features tip strips for all controls. Hover with your mouse cursor over any of the controls and specific information will be displayed.

The following describes the function of the various controls

  • DAQ Channel(s) specifies the names of the physical channels from a particular DAQ device. Select channels from the drop down list (press STRG to select multiple entries) or enter channel string manually (e.g. Dev1/ai0:3).
  • Min. Value and Max. Value specify the minimum and the maximum value you expect to measure. Setting this value correct, will improve measurement accuracy, when measuring signals with a small amplitude.
  • Sample Rate (Hz) specifies the sampling rate in samples per channel per second.
  • Recording Duration (s) specifies the amount of time a DAQ operation will read input data
    • #Data point = Recording Duration(s) * Sample Rate (Hz)
  • Repeat Data? specifies if Multisim automatically repeats your acquired data. If you use periodic signals, it is recommended to only sample one period and check the Repeat Data? checkbox.
  • Acquire Data will update the graph with a new set of input data.


[+] Enlarge Image

 

How To Use This Instrument

If you are familiar with Dataacquisition from National Instrument, you will find it easy to use the DAQ Source instrument. However, here are some simple steps we recommend to follow when using the DAQ Source for the first time.

  1. Verify a NI DAQ device is connected to or plugged into your computer
  2. Open Multisim and create your circuit
  3. Add the DAQ Source to your schematic
    1. Access the DAQ Source from the instrument toolbar
    2. Place it on your schematic
    3. Wire it to the desired net
  4. Input real world DAQ data
    1. Double click the instrument symbol to open the interface
    2. Enter the channels you like to measure
    3. Set Min. and Max. Value, Sample Rate (Hz) and Recording Duration (s) to match your expected signal
    4. Press the Acquire Data control to get a new reading and update the graph
  5. Start the simulation


[+] Enlarge Image

 

Additional Resources

Search ni.com for more LabVIEW based instruments for NI Multisim

Tutorial on "How To Create A LabVIEW Based Instrument For NI Multisim"

Tutorial on "Assure Compatibility of LabVIEW based Instruments across different NI Multisim versions"

Learn more about Data Acquisition

 

Note: You only need NI LabVIEW to create or edit and an instrument. NI LabVIEW doesn’t need to be installed on the machine where you intend to run Multisim.

Requirements


Filename: daq_source.zip

Software Requirements


Application Software: Multisim Base Edition 9.x, LabVIEW Base Development System 8.2
Language(s): LabVIEW

Hardware Requirements


Hardware Group: Digital Multimeters (DMM), High-Speed Digitizers (Scopes), Multifunction DAQ (MIO)
Driver: NI-DAQmx 8.0

 
8 ratings | 4.12 out of 5
Print

Reader Comments | Submit a comment »

 

Legal
This example program (this "program") was developed by a National Instruments ("NI") Applications Engineer. Although technical support of this program may be made available by National Instruments, this program may not be completely tested and verified, and NI does not guarantee its quality in any way or that NI will continue to support this program with each new revision of related products and drivers. THIS EXAMPLE PROGRAM IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND AND SUBJECT TO CERTAIN RESTRICTIONS AS MORE SPECIFICALLY SET FORTH IN NI.COM'S TERMS OF USE (http://ni.com/legal/termsofuse/unitedstates/us/).