VXI VT1422A User Manual

Page 171

Advertising
background image

Advanced Programming with the VT1529B 169

Chapter 5

3. Next, create a custom linear EU conversion for the excitation voltage
channel. This EU will create the ratio of the newly measured value divided
by the original value. The first channel’s pre-INITiate excitation value
measured by the MEAS:VOLT:EXC? query above will be used to create
this EU. For this example, assume that this initial value was 5.60 V.

DIAG:CUST:MXB 1.0/5.60,0.0,(@10006)

Create custom linear EU to
compute ratio of current
excitation voltage to initial value

SENS:FUNC:CUST:HVOL (@10006)

Enables custom EU on
excitation channel

4. Use the ratio inside the algorithm to adjust the DSP-computed value.
After computing the corrected reading, the writefifo(), writecvt() or
writeboth() algorithm calls can be used to send the corrected data to the
FIFO and/or CVT. This is a code segment from the algorithm:

{
float ratio;
float chan0, chan1, chan2;

/* get the ratio of new to initial excitation voltages */
ratio = I10006;

/* read and correct channel data */
chan0 = I10000 * ratio;
chan1 = I10001 * ratio;
chan2 = I10002 * ratio;

/* write corrected values to FIFO and the normal
position in CVT for this channel */
writeboth(chan0,

10);

writeboth(chan1,

11);

writeboth(chan2,

12);

writeboth(chan3,

13);

} /* end of code segment */

5. Download the algorithm and start scanning.

6. Read the data with SENS:DATA:FIFO? This data will be corrected strain
readings. Note that the data order in the FIFO will be channel 10006, 10000,
10001, 10002.

Note

Doing these corrections in an algorithm will increase the duration of the
Execute Algorithm phase of the VT1422A operational cycle (see
Figure 6-2 on page 195) and can slow down the frequency at which the
VT1422A can scan channels. For this reason, this method should be limited
to only those channels needed for the algorithms.

Advertising
This manual is related to the following products: