
Comparator (COMP)
RM0351
682/1830
DocID024597 Rev 5
22.6 COMP
registers
22.6.1
Comparator 1 control and status register (COMP1_CSR)
The COMP1_CSR is the Comparator 1 control/status register. It contains all the bits /flags
related to comparator1.
Address offset: 0x00
System reset value: 0x0000 0000
31
30
29
28
27
26
25
24
23
22
21
20
19
18
17
16
LOCK
VALUE
Res.
Res.
Res.
Res.
Res.
Res.
SCAL
EN
BRG
EN
Res.
BLANKING
HYST
rs
r
rw
rw
rw
rw
15
14
13
12
11
10
9
8
7
6
5
4
3
2
1
0
POLA
RITY
Res.
Res.
Res.
Res.
Res.
Res.
Res.
INP
SEL.
INMSEL PWRMODE
Res.
EN
rw
rw
rw
rw
rw
Bit 31
LOCK:
COMP1_CSR register lock bit
This bit is set by software and cleared by a hardware system reset. It locks the whole
content of the comparator 1 control register, COMP1_CSR[31:0].
0: COMP1_CSR[31:0] for comparator 1 are read/write
1: COMP1_CSR[31:0] for comparator 1 are read-only
Bit 30
VALUE:
Comparator 1 output status bit
This bit is read-only. It reflects the current comparator 1 output taking into account
POLARITY bit effect.
Bits 29:24 Reserved, must be kept at reset value.
Bit 23
SCALEN
: Voltage scaler enable bit
This bit is set and cleared by software. This bit enable the outputs of the V
REFINT
divider
available on the minus input of the Comparator 1.
0: Bandgap scaler disable (if SCALEN bit of COMP2_CSR register is also reset)
1: Bandgap scaler enable
Bit 22
BRGEN:
Scaler bridge enable
This bit is set and cleared by software (only if LOCK not set). This bit enable the bridge of
the scaler.
0: Scaler resistor bridge disable (if BRGEN bit of COMP2_CSR register is also reset)
1: Scaler resistor bridge enable
If SCALEN is set and BRGEN is reset, BG voltage reference is available but not 1/4BGAP,
1/2BGAP, 3/4 BGAP. BGAP value is sent instead of 1/4BGAP, 1/2BGAP, 3/4 BGAP.
If SCALEN and BRGEN are set, 1/4 BGAP 1/2BGAP 3/4BGAP and BGAP voltage
references are available.
Bit 21 Reserved, must be kept at reset value