Example 2; Example 3 - National Instruments PCI E Series Programmer's Manual

Register-level programmer manual, multifunction i/o boards for pci bus computers, register-level
Hide thumbs Also See for PCI E Series:
Table of Contents

Advertisement

Example 3

© National Instruments Corporation
If (!VirtualFIFO)
Wait until DACs have been preloaded.
AO_Command_1_Register = 0x0554;
18. Call
AO_Start_The_Acquisition
trigger.
AO_Command_2_Register
AO START1 pulse = 1;
19. Poll the AO_FIFO_Full_St bit and write data from the array into the
data FIFO whenever the data FIFO is not full.
while (there is more data to write)
{
while (FIFO is not full)
{
AO_DAC_FIFO_Data = data;
}
}
This example generates a waveform using local buffer mode. This example
does not support the PCI-MIO-16XE-50 boards, because it has virtual
analog output FIFOs.
Initialize the data FIFO with a 100 point buffer. Output the buffer 50 times.
The update interval is 100 µs. Confirm operation with an oscilloscope.
1.
Perform Analog Output Example 2 Steps 1 through 9.
2.
Call
AO_Counting
buffers. Configure the DAQ-STC for non-continuous operation
(AO will stop on BC_TC). Load the BC counter with 49 (output the
buffer 50 times). Load the UC counter with 100 (the first buffer
contains 100 points). Write 99 to UC Load Register A (each
subsequent buffer contains 100 points).
Joint_Reset_Register
AO configuration start = 1;
AO_Mode_1_Register
AO continuous = 0;
AO_Mode_2_Register
AO BC initial load source = 0;
AO_BC_Load_A_Registers (24 bits)
Number of buffers -1 = 49;
to pulse the software START1
to program the buffer size and the number of
4-39
Chapter 4
Programming
PCI E Series RLPM

Advertisement

Table of Contents
loading

Table of Contents