
III PERIPHERAL BLOCK: CLOCK TIMER
B-III-7-4
EPSON
S1C33210 FUNCTION PART
Setting alarm function
The clock timer has an alarm function, enabling an interrupt to be generated at a specified time and day. This
specification can be made in minutes, hours, and days for each alarm or a combination of multiple alarms.
Use TCASE[2:0] (D[4:2) / Clock timer interrupt control register (0x40152) for this specification.
Table 7.3 Alarm Factor Selection
TCASE2
TCASE1
TCASE0
Alarm factor
X
X
1
Minutes alarm
X
1
X
Hours alarm
1
X
X
Day alarm
0
0
0
None
For example, if TCASE is set to "001", only a minutes alarm is enabled and an alarm is generated at a specified
minute every hour. If TCASE is set to "111", an alarm is generated on each specified day at each specified hour
and minute. If alarms are not to be used, set TCASE to "000".
An interrupt can be generated every minute, every hour, and every day through the use of the counter's
interrupt function instead of the alarm function.
To specify a day, hours, and minutes, use the registers shown below:
To specify minutes: TCCH[5:0] (D[5:0]) / Minute-comparison data register (0x40159)
0 to 59 minutes*
To specify hours:
TCCD[4:0] (D[4:0]) / Hour-comparison data register (0x4015A)
0 to 23 hours*
To specify day:
TCCN4[4:0] (D[4:0]) / Day-comparison data register 0x4015B)
0 to 31 days after
∗
The minute-comparison data register (6 bits) and hour-comparison data register (5 bits) can be set for up to 63
minutes and 31 hours, respectively. Note that even when the data set in these registers exceeds 59 minutes or 23
hours, the data is not considered invalid.
The values set in these registers are compared with those of each counter, and when they match, the alarm
factor generation flag TCAF (D0) / Clock timer interrupt control register (0x40152) is set to "1". If clock timer
interrupts have been enabled using the interrupt controller, an interrupt is generated when the flag is set.
The day-comparison data register is a 5-bit register, and its value is compared with the five low-order bits of
the day counter. Therefore, an alarm can be generated for up to 31 days after the register is set.
Interrupt Function
Clock timer interrupt factors
The clock timer can generate an interrupt using a 32-Hz, 8-Hz, 2-Hz, 1-Hz (1-second), 1-minute, 1-hour, or 1-
day signal. The interrupt factor to be used from among these signals can be selected using the interrupt factor
selection bit TCISE[2:0] (D[7:5]) / Clock timer interrupt control register (0x40152).
Table 7.4 Selecting Interrupt Factor
TCISE2
TCISE1
TCISE0
Interrupt factor
1
1
1
None
1
1
0
1 day
1
0
1
1 hour
1
0
0
1 minute
0
1
1
1 Hz
0
1
0
2 Hz
0
0
1
8 Hz
0
0
0
32 Hz
An interrupt factor is generated at intervals of a selected signal (each falling edge of the signal).
If interrupts based on these signals are not to be used, set TCISE to "111".
When a selected interrupt factor is generated, the interrupt factor generation flag TCIF (D1) / Clock timer
interrupt control register (0x40152) is set to "1". At the same time, the clock timer interrupt factor flag FCTM
(D1) / Port input 4–7, clock timer, A/D interrupt factor flag register (0x40287) also is set to "1". At this time,
if the interrupt conditions set by the interrupt control registers are met, an interrupt to the CPU is generated.
Summary of Contents for S1C33210
Page 4: ......
Page 13: ...S1C33210 PRODUCT PART ...
Page 14: ......
Page 124: ...APPENDIX B PIN CHARACTERISTICS A 110 EPSON S1C33210 PRODUCT PART THIS PAGE IS BLANK ...
Page 125: ...S1C33210 FUNCTION PART ...
Page 126: ......
Page 127: ...S1C33210 FUNCTION PART I OUTLINE ...
Page 128: ......
Page 130: ...I OUTLINE INTRODUCTION B I 1 2 EPSON S1C33210 FUNCTION PART THIS PAGE IS BLANK ...
Page 138: ...I OUTLINE LIST OF PINS B I 3 6 EPSON S1C33210 FUNCTION PART THIS PAGE IS BLANK ...
Page 139: ...S1C33210 FUNCTION PART II CORE BLOCK ...
Page 140: ......
Page 142: ...II CORE BLOCK INTRODUCTION B II 1 2 EPSON S1C33210 FUNCTION PART THIS PAGE IS BLANK ...
Page 148: ...II CORE BLOCK CPU AND OPERATING MODE B II 2 6 EPSON S1C33210 FUNCTION PART THIS PAGE IS BLANK ...
Page 152: ...II CORE BLOCK INITIAL RESET B II 3 4 EPSON S1C33210 FUNCTION PART THIS PAGE IS BLANK ...
Page 234: ...II CORE BLOCK CLG Clock Generator B II 6 10 EPSON S1C33210 FUNCTION PART THIS PAGE IS BLANK ...
Page 236: ...II CORE BLOCK DBG Debug Unit B II 7 2 EPSON S1C33210 FUNCTION PART THIS PAGE IS BLANK ...
Page 237: ...S1C33210 FUNCTION PART III PERIPHERAL BLOCK ...
Page 238: ......
Page 240: ...III PERIPHERAL BLOCK INTRODUCTION B III 1 2 EPSON S1C33210 FUNCTION PART THIS PAGE IS BLANK ...
Page 296: ...III PERIPHERAL BLOCK WATCHDOG TIMER B III 5 4 EPSON S1C33210 FUNCTION PART THIS PAGE IS BLANK ...
Page 429: ...S1C33210 FUNCTION PART IV ANALOG BLOCK ...
Page 430: ......
Page 432: ...IV ANALOG BLOCK INTRODUCTION B IV 1 2 EPSON S1C33210 FUNCTION PART THIS PAGE IS BLANK ...
Page 448: ...IV ANALOG BLOCK A D CONVERTER B IV 2 16 EPSON S1C33210 FUNCTION PART THIS PAGE IS BLANK ...
Page 449: ...S1C33210 FUNCTION PART V DMA BLOCK ...
Page 450: ......
Page 452: ...V DMA BLOCK INTRODUCTION B V 1 2 EPSON S1C33210 FUNCTION PART THIS PAGE IS BLANK ...
Page 506: ...V DMA BLOCK IDMA Intelligent DMA B V 3 18 EPSON S1C33210 FUNCTION PART THIS PAGE IS BLANK ...
Page 507: ...S1C33210 FUNCTION PART Appendix I O MAP ...
Page 508: ......
Page 557: ......