Datasheet

2013-2014 Microchip Technology Inc. DS70000689D-page 365
dsPIC33EPXXXGM3XX/6XX/7XX
26.0 OP AMP/COMPARATOR
MODULE
The dsPIC33EPXXXGM3XX/6XX/7XX devices contain
up to five comparators that can be configured in various
ways. Comparators, CMP1, CMP2, CMP3 and CMP5,
also have the option to be configured as op amps, with
the output being brought to an external pin for gain/
filtering connections. As shown in Figure 26-1, individual
comparator options are specified by the comparator
module’s Special Function Register (SFR) control bits.
These options allow users to:
Select the edge for trigger and interrupt generation
Configure the comparator voltage reference
Configure output blanking and masking
Configure as a comparator or op amp
(CMP1, CMP2, CMP3 and CMP5 only)
FIGURE 26-1: OP AMP/COMPARATOR x MODULE BLOCK DIAGRAM
Note 1: This data sheet summarizes the features
of the dsPIC33EPXXXGM3XX/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 the “dsPIC33/PIC24
Family Reference Manual”, “Op Amp/
Comparator” (DS70000357), which is
available from the Microchip web site
(www.microchip.com).
2: Some registers and associated bits
described in this section may not be
available on all devices. Refer to
Section 4.0 “Memory Organization” in
this data sheet for device-specific register
and bit information.
Note: Not all op amp/comparator input/output
connections are available on all devices.
See the “Pin Diagrams” section for
available connections.
Blanking
Function
Digital
Filter
CxOUT
(1)
(see Figure 26-3)
(see Figure 26-4)
CMP4
Blanking
Function
Digital
Filter
(see Figure 26-3)
(see Figure 26-4)
+
V
IN+
PTG Trigger
Input
C4OUT
(1)
Trigger
Output
0
1
00
10
Op Amp/Comparator 1, 2, 3, 5
Comparator 4
C4IN1+
CV
REFIN
VIN-
0
1
11
00
CCH<1:0> (CM4CON<1:0>)
OA3/AN6
C4IN1-
CREF (CMxCON<4>)
01
10
OA1/AN3
OA2/AN0
(x = 1, 2, 3, 5)
CxIN1+
CV
REFIN
CxIN1-
C
XIN3-
CMPx
+
V
IN-
V
IN+
CCH<1:0> (CMxCON<1:0>)
CREF (CMxCON<4>)
Op Amp/Comparator
Op Amp x
+
OAx
OAxOUT
OPMODE (CMxCON<10>)
(to ADCx)
01
CxIN2-
11
CXIN4-
Note 1: The CxOUT pin is not a dedicated output pin on the device. This must be mapped to a physical pin using
Peripheral Pin Select (PPS). Refer to Section 11.0 “I/O Ports” for more information.