
Rev. 1.00
171 of ���
�an�a�� 1�� �01�
Standard 8051 8-Bit Flash MCU
HT85F2260/HT85F2270/HT85F2280
Comparators
Comparators
CP0CR Register
SFR Address: DEh
Bit
7
6
5
4
3
2
1
0
Name
—
CP0ON
CP0POL
CP0OUT
CP0OS
CP0RSTL
CP0RST
—
R/W
—
R/W
R/W
R/W
R/W
R/W
R/W
—
POR
—
0
0
0
1
0
0
—
Bit 7
Unimplemented, read as “0”
Bit 6
CP0ON:
Comparator 0 On/Off control
0: Off
1: On
This is the Comparator 0 on/off control bit. If the bit is zero the comparator will be
switched off and no power consumed even if analog voltages are applied to its inputs.
For power sensitive applications this bit should be cleared to zero if the comparator is
not used or before the device enters the Power-Down or IDLE mode.
Bit 5
CP0POL:
Comparator 0 output polarity
0: Output not inverted
1: Output inverted
This is the comparator 0 polarity bit. If the bit is zero then the CP0OUT bit will reflect
the non-inverted output condition of the comparator. If the bit is high the comparator
CP0OUT bit will be inverted.
Bit 4
CP0OUT:
Comparator 0 output bit
CP0POL=0
0: CP0+ < CP0-
1: CP0+ > CP0-
CP0POL=1
0: CP0+ > CP0-
1: CP0+ < CP0-
This bit stores the comparator 0 output bit. The polarity of the bit is determined by the
voltages on the comparator 0 inputs and by the condition of the CP0POL bit.
Bit 3
CP0OS:
Comparator 0 output path select
0: C0OUT pin
1: Internal use
This is the comparator 0 output path select control bit. If the bit is set to “0” and the
CP0ON bit is “1” the comparator 0 output is connected to an external C0OUT pin. If
the bit is set to “1” or the CP0ON bit is “1” the comparator 0 output signal is only used
internally by the device allowing the shared comparator output pin to retain its normal
I/O operation.
Bit 2
CP0RSTL:
Output reset signal select
0: CP0OUT=0 will reset the MCU
1: CP0OUT=1 will reset the MCU
The CP0RST bit should be set high first to enable this function.
Bit 1
CP0RST:
Comparator 0 output to reset MCU function control
0: Disable
1: Enable
Bit 0
Unimplemented, read as “0”