=
Compare match
MASK
RTCC_TIME
RTCC_DATE
RTCC_CCx_TIME
RTCC_CCx_DATE
RTCC_CCx_CTRL_DAYCC
[0b000,
DAYOW]
[DAYOMT,
DAYOMU]
[MONTHT,MONTHU]
MASK
[MONTHT,MONTHU]
[DAYT,DAYU]
Figure 11.5. RTCC Compare in calendar mode, COMPBASE = CNT
To generate periodically recurring events, is possible to mask out parts of the compare match values. By configuring COMPMASK in
RTCC_CCx_CTRL, parts of the compare values will be masked out, limiting which part of the compare register being subject to com-
parison with the counter.
Figure 11.6 RTCC Compare mask illustration, COMPMASK=11 on page 297
illustrates the effect of COMP-
MASK when in normal mode and calendar mode.
SECU
SECT
MINU
MINT
HOURU
HOURT
DAYU
DAYT
MONTHU
MONTHT
1
4
5
7
8
11
12
14
15
18
19
20
21
24
25
26
27
30
31
CCV
CC_CTRL_COMPMASK
0
31
MASKED
Subject to comparison
20
21
0
Figure 11.6. RTCC Compare mask illustration, COMPMASK=11
Upon a compare match, the respective Capture/Compare interrupt flag CCx is set. Additionally, the event selected by the CMOA setting
is generated on the corresponding PRS output. This is illustrated in
Figure 11.3 RTCC Compare match and PRS output illustration on
.
11.3.3 Interrupts and PRS Output
The RTCC has one interrupt for each of its 3 Capture/Compare channels, CC0, CC1, and CC2. Each Capture/Compare channel has a
PRS output with configurable actions upon compare match.
The interrupt flag CNTTICK is set each time the main counter receives a tick (each second in calendar mode). In calendar mode, there
are also interrupt flags being set each minute, hour, day, week, and month.
Upon oscillator failure detection, the OSCFAIL flag will be set.
EFM32JG1 Reference Manual
RTCC - Real Time Counter and Calendar
silabs.com
| Smart. Connected. Energy-friendly.
Preliminary Rev. 0.6 | 297