Measurement Computing UL for NI LabVIEW User Manual
Page 24

Universal Library Virtual Instruments (VIs)
Analog Input VIs
PretrigCount
Specifies the number of samples before the trigger that will be returned.
PretrigCount
must be less than
TotalCount
- 512. If the trigger occurs too early,
then fewer than the requested number of pre-trigger samples will be collected. In
that case a
TOOFEW
error will occur. The
PretrigCount
will be set to indicate how
many pretrigger samples were collected and the post-trigger samples will still be
collected.
TotalCount
Specifies the total number of samples that will be collected and stored in
DataArray
. TotalCount must be greater than or equal to
PretrigCount
+ 512. If the
trigger occurs too early, then fewer than the requested number of samples will be
collected. In that case a
TOOFEW
error will occur. The
TotalCount
will be set to
indicate how many total samples were actually collected.
Rate
Desired sample rate in samples per channel per second.
Range
If the selected A/D board does not have a programmable gain feature, this
argument will be ignored. Otherwise the
Range
can be set to any of the ranges that
are supported by the selected A/D board. See the "
page 19 for valid values.
Refer to board-specific information contained in the Universal Library User's
Guide (available on our we
ConvertData
Set this option to False (default) when using APretrBg.VI.
DTConnect
When the DTCONNECT option (True) is used with this VI, the data from ALL
A/D conversions is sent out the DT-CONNECT interface. While this VI is waiting
for a trigger to occur, it will send data out the DT-CONNECT interface
continuously. If you have a MCC memory board plugged into the DT-CONNECT
interface then you should use
EXTMEMORY
option rather than this option.
ExtMemory
If you use this option (True) to send the data to a connected memory board then
you must use MemRdPrt.VI to later read the pre-trigger data from the memory
board. If you use MemRead.VI, the data will NOT be in the correct order. Every
time this option is used it will overwrite any data that is already stored in the
memory board. Read all data from the board (with MemRdPrt.VI) before
collecting any new data. The Mega Fifo memory must be fully populated to use the
APretrBg.VI or APretrFg.VI.
Context
The data array for the pretrigger data. This is a data structure containing output
information including the board number, the contents of
DataArray
, the size of
DataArray
, and the initial status of the background operation.
CONTEXT
must be
wired to subsequent VIs in order to process this VI correctly.
Follow the steps below when wiring this VI:
1.
Start a background operation.
2.
GetStatus.VI checks for completion (boolean output called "Running").
3.
StopBg.VI terminates the operation, if not already done, and frees memory aliases.
4.
Data output from the background operation is passed to GetStatus.VI and StopBg.VI
via Context, and can be wired from one or both of them for intermediate or final
actions, respectively.
The demo VIs illustrate this process effectively.
PretrigCount
Actual number of pre-trigger A/D samples collected.
TotalCount
Total number of A/D samples collected.
Rate
Actual sample rate in scans per second .
ErrCode
Error code returned from the Universal Library. Zero if no error occurred. Use the
ErrMsg VI to convert
ErrCode
into a readable string.
24