Programming instructions

Chapter 6 One-Stop Single-Point Acquisition
LabVIEW Data Acquisition Basics Manual 6-6
©
National Instruments Corporation
Using Analog Input/Output Control Loops
When you want to output analog data after receiving some analog input
data, use analog input/output (I/O) control loops. With control loops, this
process is repeated over and over again.
The single-point analog input and output VIs support several analog
I/O control loops at once because you can acquire analog inputs from
several different channels in one scan, and write all the analog output
values with one update. You perform a single analog input call, process the
analog output values for each channel and then perform a single analog
output call to update all the output channels.
The following sections describe the two different types of analog I/O
control loop techniques:
software-timed
and
hardware-timed analog I/O
.
Using Software-Timed Analog I/O Control Loops
With software-timed analog control loops the analog acquisition rate and
subsequent control loop rate are controlled by a software timer such as the
Wait Until Next Millisecond multiple timer. The acquisition is performed
during each loop iteration when the AI Single Scan VI is called and the
control loop is executed once for each time interval. Your loop timing can
be interrupted by any user interaction, which means your acquisition rate is
not as consistent as that which can be achieved through hardware-timed
control loops. Generally, if you do not need a precise acquisition rate for
your control loop, software timing is appropriate.
Besides user interaction, a large number or large-sized front panel
indicators, like charts and graphs, affect control loop rates. Refreshing the
monitor screen interrupts the system clock, which controls loop rates.
Therefore, you should keep the number of charts and graphs to a minimum
when you are using software-timed control loops.
An example of software-timed control loops is the Analog IO Control Loop
(immed) VI located in
labview\examples\daq\anlog_io\
anlog_io.llb
.