NI 5922 Calibration Procedure
22
ni.com
8.
Call
niScope_InitiateAcquisition
(niScope Initiate
Acquisition VI) with the following parameter:
•
vi
: The instrument handle you obtained from
niScope_init
9.
Call
niScope_Fetch
(niScope Multi Fetch VI) with the following
parameters:
•
channelList
:
"0"
•
timeout
:
5.0
•
numSamples:
–1
10. The Fetch function returns a two-dimensional array, with one row
corresponding to each of the 400 triggered records. For this array,
complete the following steps:
a.
Perform a mathematical convolution on the first record with
the array (+1, –1). Denote the result as X1, which contains
501 elements.
b.
Discard the first 150 elements and the last 151 elements from X1.
Denote the resulting array as X2, which contains 200 elements.
c.
Perform a circular rotation of the elements within array X2 so that
index 0 of the array contains the element with the largest value.
Denote the result as X3.
A circular rotation takes the first element of the array, makes it the
last element and shifts all the other elements over one space. The
second element now becomes the first. Repeat this process until
you reach the desired result.
d.
Perform a complex FFT on the array X3. The result is an array
of complex numbers with 200 elements. Discard the last
119 elements. Take the magnitude of the complex number to
obtain a real number for each element. Denote this array as X4.
e.
Denote the last element of array X4 as R. Perform the following
calculation on the complex number R:
The absolute value notation implies calculating the real magnitude
(or radius) of the complex number.
f.
The vector X4 has 81 elements. Index this vector from
i
= 0 to 80.
Calculate a new complex vector X5 by calculating on all the
elements within X4:
e
R
R
------
1 80
/
=
X
5
i
[ ]
X
4
i
[ ]
(
)
e
i
⁄
sin
π
i
200
⁄
×
(
)
----------------------------------------
=