VXI VT1538A DJ Equipment User Manual


 
Agilent E1538A Enhanced Frequency/Totalize/PWM SCP 21
Sense Quadrature
Position
This means that the E1538 will convert a digital quadrature signal pair into
an absolute 24-bit count. The count value can be read by the algorithm.
The E1538’s quadrature position function increments a counter value each
time there is a transition on either of the quadrature channel pair. When the
lower numbered channel’s signal LEADS the higher numbered channel, the
function counts up. When the lower numbered channel LAGS the higher
numbered channel, the function counts down.
To configure a pair of channels to sense quadrature count use
[SENSe:]FUNCtion:QUADrature [<count_preset>,](@<ch_list>)
<count_preset> if included, allows presetting the absolute counter
associated with the channel pair. All quadrature pairs in <ch_list> will
be preset to the same value. If not included, the default count at
algorithm start will be zero. <count_preset> can range from 0 to
16,777,215. The variable type is int32
<ch_list> must always specify both channels of a pair. More than one
pair can be specified. Both channels of any pair must be adjacent.
<ch_list> can specify channels on more than one E1538. The channel
numbers in <ch_list> must be in ascending order. The related error
messages are:
3115, "Channels specified are not in ascending order."
3116, "Multiple channels specified are not grouped correctly."
3117, "Grouped channels are not adjacent."
3122, "This multiple channel function must not span multiple SCPs."
The algorithm reads the current count through the low numbered
channel. The count is an unsigned 24-bit value ranging from 0 to
16,777,215. The counter can roll over from 16,777,2215 to 0, and roll
under from 0 to 16,777,215 is 16,777,215.
To configure channels 42 and 43 as one quadrature pair, and channels 48 and
49 as another pair
*RST
SENS:FUNC:QUAD 8192,(@142,143)
pair 42&43 preset to count of
8192
SENS:FUNC:QUAD 0,(@148,149)
pair 48&49 preset to 0
algorithm will retrieve values from input channels and place in CVT elements
ALG:DEF ’ALG1’,’writecvt(I142,42); writecvt(I148,48);’
INIT
start algorithm execution
begin loop
loops between here and end loop
SENS:DATA:CVT? (@42,48)
get quadrature position count
display or otherwise use count info
end loop