
dsPIC30F Quadrature Encoder Interface Module
© 2005 Microchip Technology Inc.
Page 9
© 2005 Microchip Technology Incorporated. All Rights Reserved.
dsPIC30F Quadrature Encoder Interface Module
9
Quadrature Decoder
O
Four basic modes
O
x 2 mode with Index Pulse reset
O
X 2 mode with reset by match
O
X 4 mode Index Pulse reset
O
X 4 mode with reset by match
As we have already seen, the quadrature decoder must determine the direction
of rotation looking at the two incoming phase signals, and generate the clock
that will be used by the position counter.
We can select between two modes: in the first one (x2) the decoder only
generates a clock impulse at the rising and falling edges of Phase A signal; in
the other mode (x4), the clock pulses are generate at each edge of phase A
and Phase B. The position counter can be reset either by the index pulse
coming from the encoder or by the matching of the current position counter
value with the number in the Maximum Count Register.