14 REAL-TIME CLOCK (RTC)
S1C17F13 TeChniCal Manual
Seiko epson Corporation
14-5
(Rev. 1.0)
Control Registers
14.6
RTC Control Register
Register name
Bit
Bit name
Initial
Reset
R/W
Remarks
RTCCTL
15–9 –
0x00
–
R
–
8
RTCST
0
H0
R
7–6 –
0x0
–
R
5
BCDMD
0
H0
R/W
4
RTC24H
0
H0
R/W
3–1 –
0x0
–
R
0
RTCRUN
0
H0
R/W
Bits 15–9 Reserved
Bit 8
RTCST
This bit indicates the RTC operating status.
1 (R):
Running
0 (R):
Stop
The RTCCTL.RTCST bit goes 1 when the RTC starts counting by writing 1 to the RTCCTL.RTCRUN
bit and it reverts to 0 when the count operation is actually stopped after 0 is written to the RTCCTL.
RTCRUN bit. When setting counter values, write 0 to the RTCCTL.RTCRUN bit and make sure that
the RTCCTL.RTCST bit is cleared to 0 before writing data.
Bits 7–6
Reserved
Bit 5
BCDMD
This bit sets the second, minute, and hour counters into binary or BCD mode.
1 (R/W): BCD mode
0 (R/W): Binary mode
See “RTC Counters” for the configuration of the counter in each mode.
Bit 4
RTC24h
This bit sets the hour counter to 24H mode or 12H mode.
1 (R/W): 12H mode
0 (R/W): 24H mode
This selection changes the count range of the hour counter. Note, however, that the counter value is
not updated automatically, therefore, it must be programmed again.
Note: Be sure to avoid writing to this bit when the RTCCTL.RTCRUN bit = 1.
Bits 3–1
Reserved
Bit 0
RTCRun
This bit starts/stops the RTC.
1 (R/W): Start
0 (R/W): Stop
When the RTC stops counting by writing 0 to this bit, the counter retains the value when it was
stopped. Writing 1 to this bit again resumes counting from the value retained.
Writing 1 to the RTCCTL.RTCRUN bit resets the OSC1A divider in the clock generator.