National Instruments 1142 用户手册

下载
页码 86
Chapter 5
Using the SCXI-1141/1142/1143 Module
5-8
ni.com
Table 5-6.  Programming a Task in LabVIEW
Flowchart Step
VI or Program Step
Create Task in DAQ Assistant
Create a 
DAQmx Task Name Control
 located on the 
Controls»All Controls»I/O»DAQmx Name Controls 
subpalette, right-click it, and select 
New Task (DAQ 
Assistant)
.
Create a Task 
Programmatically 
(optional)
DAQmx Create Task.vi
 located on the Functions»
All Functions»NI Measurements»DAQmx - Data 
Acquisition»DAQmx Advanced Task Options
 
subpalette—This VI is optional if you created and configured 
the task using the DAQ Assistant. However, if you use it in 
LabVIEW, any changes you make to the task are not saved to a 
task in MAX.
Create Virtual Channel(s)
DAQMX Create Virtual Channel.vi
 located on the 
Functions»All Functions»NI Measurements»DAQmx - Data 
Acquisition
 subpalette—Use this VI to add virtual channels to 
the task. Select the type of virtual channel based on the 
measurement you plan to perform.
Adjust Timing Settings 
(optional)
DAQmx Timing.vi
 (Sample Clock by default)—This VI is 
optional if you created and configured the task using the DAQ 
Assistant. Any timing settings modified with this VI are not 
saved in the DAQ Assistant. They are only available for the 
present session.
Configure Channels 
(optional)
NI-DAQmx Channel Property Node, refer to the 
 section for 
more information. This step is optional if you created and fully 
configured the channels using the DAQ Assistant. Any channel 
modifications made with a channel property node are not saved 
in the task in the DAQ Assistant. They are only available for the 
present session.
Start Measurement
DAQmx Start Task.vi
Read Measurement
DAQmx Read.vi
Analyze Data
Some examples of data analysis include filtering, scaling, 
harmonic analysis, or level checking. Some data analysis tools 
are located on the Functions»Signal Analysis subpalette and on 
the Functions»All Functions»Analyze subpalette.