English
Language : 

W79E225A Datasheet, PDF (128/200 Pages) Winbond – 8-bit Microcontroller
Preliminary W79E225A/227A Data Sheet
15. MOTION FEEDBACK MODULE
Motion feedback module is a peripheral module designed for motion feedback applications. This
module includes two sub-modules:
• Input Capture Module (IC).
• Quadrature Encoder Interface (QEI).
There are three 16-bit registers cascaded by two 8-bit SFR in motion feedback module, but with
different definitions in each sub-module. Together with Timer 3, these modules provide a number of
options for motion and control applications. Most of the features for the QEI and IC sub-modules are
fully programmable thus making a flexible peripheral structure that can accommodate a wide range of
uses. A simplified block diagram of the entire Motion Feedback module is shown in Figure 15-2.
Note: The input pins are common to the IC and QEI sub-modules, only one of these two sub-
modules may be used at any given time. IC sub-module is the default value upon reset.
15.1 Input Capture Module (IC)
The capture modules are function to detect and measure pulse width and period of a square wave.
It supports 3 capture inputs and digital noise rejection filter. The modules are configured by CAPCON0
and CAPCON1 SFR registers. Input Capture 0, 1 & 2 have their own edge detector but share with one
timer i.e. Timer 3. The Input Capture pins structure are Schmitt trigger. For this operation it basically
consists of;
• 3 capture module function blocks.
• Timer 3 block.
Each capture module block consists of 2 bytes of capture registers, noise filter and programmable
edge triggers. Noise Filter is used to filter the unwanted glitch or pulse on the trigger input pin.
The noise filter can be enabled through bit ENFx (CAPCON1). If enabled, the capture logic required
to sample 4 consecutive same capture input value in order to recognize an edge as a capture event. A
possible implementation of digital noise filter is as follow; the interval between pulses requirement for
input capture is 1 machine cycle width, which is the same as the pulse width required to guarantee a
trigger for all trigger edge mode. For less than 3 system clocks, anything less than 3 clocks will not
have any trigger and pulse width of 3 or more but less than 4 clocks will trigger but will not guarantee
100% because input sampling is at stage C3 of the machine cycle.
Figure 15-1: Noise Filter
- 128 -
Publication Release Date: December 14, 2007
Revision A2.0