English
Language : 

C8051F52X_12 Datasheet, PDF (77/221 Pages) Silicon Laboratories – 8/4/2 kB ISP Flash MCU Family
C8051F52x/F53x
less than 100 nA. See Section “13.1. Priority Crossbar Decoder” on page 122 for details on configuring
Comparator outputs via the digital Crossbar. Comparator inputs can be externally driven from –0.25 V to
(VREGIN) + 0.25 V without damage or upset. The complete Comparator electrical specifications are given
in Table 2.7 on page 31.
The Comparator response time may be configured in software via the CPTnMD register (see SFR Defini-
tion 7.3). Selecting a longer response time reduces the Comparator supply current. See Table 2.7 on
page 31 for complete timing and current consumption specifications.
CP0+
VIN+
VIN- CP0-
+
CP0
_
OUT
CIRCUIT CONFIGURATION
Positive Hysteresis Voltage
(Programmed with CP0HYP Bits)
VIN-
INPUTS
VIN+
Negative Hysteresis Voltage
(Programmed by CP0HYN Bits)
VOH
OUTPUT
VOL
Positive Hysteresis
Disabled
Negative Hysteresis
Disabled
Maximum
Positive Hysteresis
Maximum
Negative Hysteresis
Figure 7.2. Comparator Hysteresis Plot
The Comparator hysteresis is software-programmable via its Comparator Control register CPT0CN. The
user can program both the amount of hysteresis voltage (referred to the input voltage) and the positive and
negative-going symmetry of this hysteresis around the threshold voltage.
The Comparator hysteresis is programmed using Bits3–0 in the Comparator Control Register CPT0CN
(shown in SFR Definition 7.1). The amount of negative hysteresis voltage is determined by the settings of
the CP0HYN bits. As shown in Table 2.7 on page 31, settings of 20, 10 or 5 mV of negative hysteresis can
be programmed, or negative hysteresis can be disabled. In a similar way, the amount of positive hysteresis
is determined by the setting the CP0HYP bits.
Comparator interrupts can be generated on both rising-edge and falling-edge output transitions. (For Inter-
rupt enable and priority control, see Section “10. Interrupt Handler” on page 98). The CP0FIF flag is set to
logic 1 upon a Comparator falling-edge detect, and the CP0RIF flag is set to logic 1 upon the Comparator
rising-edge detect. Once set, these bits remain set until cleared by software. The output state of the Com-
parator can be obtained at any time by reading the CP0OUT bit. The Comparator is enabled by setting the
CP0EN bit to logic 1 and is disabled by clearing this bit to logic 0. When the Comparator is enabled, the
internal oscillator is awakened from SUSPEND mode if the Comparator output is logic 0.
Rev. 1.4
77