Datasheet

2009-2016 Microchip Technology Inc. DS60001156J-page 181
PIC32MX5XX/6XX/7XX
16.0 INPUT CAPTURE
The Input Capture module is useful in applications
requiring frequency (period) and pulse measurement.
The Input Capture module captures the 16-bit or 32-bit
value of the selected Time Base registers when an
event occurs at the ICx pin. The following events cause
capture events:
Simple capture event modes:
- Capture timer value on every falling edge of input
at ICx pin
- Capture timer value on every rising edge of input
at ICx pin
Capture timer value on every edge (rising and
falling)
Capture timer value on every edge (rising and
falling), specified edge first.
Prescaler capture event modes:
- Capture timer value on every 4th rising edge of
input at ICx pin
- Capture timer value on every 16th rising edge of
input at ICx pin
Each input capture channel can select between one of
two 16-bit timers (Timer2 or Timer3) for the time base,
or two 16-bit timers (Timer2 and Timer3) together to
form a 32-bit timer. The selected timer can use either
an internal or external clock.
Other operational features include:
Device wake-up from capture pin during Sleep and
Idle modes
Interrupt on input capture event
4-word FIFO buffer for capture values
Interrupt optionally generated after 1, 2, 3 or 4 buffer
locations are filled
Input Capture module can also be used to provide
additional sources of external interrupts
FIGURE 16-1: INPUT CAPTURE BLOCK DIAGRAM
Note: This data sheet summarizes the features
of the PIC32MX5XX/6XX/7XX family of
devices. It is not intended to be a
comprehensive reference source. To
complement the information in this data
sheet, refer to Section 15. “Input Cap-
ture” (DS60001122) of the “PIC32 Family
Reference Manual”, which is available
from the Microchip web site
(www.microchip.com/PIC32).
Prescaler
1, 4, 16
Edge Detect
FIFO Control
Interrupt
Event
Generation
ICxBUF<31:16>
Interrupt
Timer3
Timer2
ICxCON
ICI<1:0>
ICx Input
0
1
ICxBUF<15:0>
Data Space Interface
Peripheral Data Bus
C32
ICTMR
ICM<2:0>
FEDGE
ICBNE
ICOV
ICM<2:0>