English
Language : 

SH7710 Datasheet, PDF (568/996 Pages) Renesas Technology Corp – Renesas 32-Bit RISC Microcomputer SuperHTM RISC engine Family / SH7700 Series
Section 15 Realtime Clock (RTC)
(a) To read the time
without using interrupts
Disable the carry
interrupt
Write 0 to CIE in RCR1
Clear the carry flag
Read counter
register
Write 0 to CF in RCR1
Note: Set AF in RCR1 to 1 so that alarm
flag is not cleared.
Yes
Carry flag = 1?
Read RCR1 and check CF
No
(b) To use interrupts
Enable the carry
interrupt
Clear the carry flag
Read counter
register
Write 1 to CIE in RCR1,
and write 0 to CF in RCR1
Note: Set AF in RCR1 to 1 so that
alarm flag is not cleared.
Yes
Interrupt
generated?
No
Disable the carry
interrupt
Write 0 to CIE in RCR1
Figure 15.3 Reading Time
Rev. 2.00 Dec. 07, 2005 Page 526 of 950
REJ09B0079-0200