Specifications

Reading CVT elements
The application program reads one or more CVT elements by executing the SCPI
command [SENSe:]DATA:CVT? (@<element_list>), where <element_list>
specifies one or more individual elements and/or a range of contiguous elements.
The following example command will help to explain the <element_list> syntax.
DATA:CVT? (@10,20,30:33,40:43,330) Return elements 10, 20, 30-33,
40-43 and element 330.
Individual element numbers are isolated by commas. A contiguous range of
elements is specified by: <starting element>colon<ending element>.
Writing values to the FIFO
The FIFO, as the name implies, is a First-In-First-Out buffer. It can buffer up to
65,024 values. This capability allows an algorithm to send a continuous stream of
data values related in time by their position in the buffer. This can be thought of as
an electronic strip-chart recorder. Each value is sent to the FIFO by executing the
Algorithm Language intrinsic statement writefifo(<expression>). The following is
an example algorithm statement:
writefifo(O139); /* send output channel 39’s value to the FIFO */
Since the actual algorithm execution rate can be determined (see “Programming the
Trigger Timer” on page 79), the time relationship of readings in the FIFO is very
deterministic.
Reading values from the FIFO
For a discussion on reading values from the FIFO, see “Retrieving Algorithm Data”
on page 81.
Writing values to the FIFO and CVT
The writeboth(<expression>,<cvt_element>) statement sends the value of
<expression> both to the FIFO and to a <cvt_element>. Reading these values is
done the same way as mentioned for writefifo() and writecvt().
Setting a VXIbus
Interrupt
The algorithm language provides the function interrupt() to force a VXIbus
interrupt. When interrupt() is executed in an algorithm, a VXIbus interrupt line
(selected by the SCPI command DIAG:INTR[:LINe]) is asserted. The following
example algorithm code tests an input channel value and sets an interrupt if it is
higher or lower than set limits.
static float upper_limit = 1.2, lower_limit = 0.2;
if( I124 > upper_limit || I124 < lower_limit ) interrupt();
The Algorithm Language and Environment
Accessing the VT1419A’s Resources
Chapter 4 113
Artisan Technology Group - Quality Instrumentation ... Guaranteed | (888) 88-SOURCE | www.artisantg.com