English
Language : 

PIC18F2331 Datasheet, PDF (161/396 Pages) Microchip Technology – 28/40/44-Pin Enhanced Flash Microcontrollers with nanoWatt Technology, High Performance PWM and A/D
PIC18F2331/2431/4331/4431
16.0 MOTION FEEDBACK MODULE
The Motion Feedback module is a special-purpose
peripheral designed for motion feedback applications.
Together with the Power Control PWM module (see
Section 17.0 “Power Control PWM Module”), it pro-
vides a variety of control solutions for a wide range of
electric motors.
The module actually consists of two hardware
sub-modules:
• Input Capture module (IC)
• Quadrature Encoder Interface (QEI).
Together with Timer5 (see Section 14.0 “Timer5 Mod-
ule”), these modules provide a number of options for
motion and control applications.
Many of the features for the IC and QEI submodules
are fully programmable, creating a flexible peripheral
structure that can accommodate a wide range of
in-system uses. An overview of the available features
is presented in Table 16-1. A simplified block diagram
of the entire Motion Feedback module is shown in
Figure 16-1.
Note:
Because the same input pins are common
to the IC and QEI submodules, only one of
these two submodules may be used at any
given time. If both modules are on, the QEI
submodule will take precedence.
TABLE 16-1: SUMMARY OF MOTION FEEDBACK MODULE FEATURES
Submodule
Mode(s)
Features
Timer
Function
IC (3x) • Synchronous
• Input Capture
QEI QEI
Velocity
measurement
• Flexible input capture modes
• Available prescaler
• Selectable time base reset
• Special event trigger for ADC
sampling/conversion or
optional TMR5 Reset feature
(CAP1 only)
• Wake-up from Sleep function
• Selectable interrupt frequency
• Optional noise filter
• Detect position
• Detect direction of rotation
• Large bandwidth (Fcy/16)
• Optional noise filter
• 2x and 4x update modes
• Velocity event postscaler
• Counter overflow flag for low
rotation speed
• Utilizes Input Capture 1 logic
(IC1)
• High and low velocity support
TMR5
• 3x Input Capture (edge
capture, pulse width, period
measurement, capture on
change)
• Special event triggers the A/D
conversion on the CAP1 input
16-bit • Position measurement
position • Direction of rotation status
counter
TMR5 • Precise velocity measurement
• Direction of rotation status
 2003 Microchip Technology Inc.
Preliminary
DS39616B-page 159