EVAL-ADUC836QS AD [Analog Devices], EVAL-ADUC836QS Datasheet - Page 40

no-image

EVAL-ADUC836QS

Manufacturer Part Number
EVAL-ADUC836QS
Description
MicroConverter, Dual 16-Bit ADCs with Embedded 62 kB Flash MCU
Manufacturer
AD [Analog Devices]
Datasheet
TIME INTERVAL COUNTER (WAKE-UP/RTC TIMER)
A time interval counter (TIC) is provided on-chip for:
The TIC is capable of timeout intervals ranging from 1/128th
second to 255 hours. Furthermore, this counter is clocked by the
crystal oscillator rather than the by PLL, and thus has the abil i ty to
remain active in Power-Down mode and time long pow er-down
intervals. This has obvious applications for remote battery-powered
sensors where regular widely, spaced readings are required.
The TIC counter can easily be used to generate a real-time
clock. The hardware will count in seconds, minutes, and hours;
however, user software will have to count in days, months, and
years. The current time can be written to the timebase SFRs
(HTHSEC, SEC, MIN, and HOUR) while TCEN is low. When
the RTC timer is enabled (TCEN is set), the TCEN bit itself and
the HTHSEC, SEC, MIN, and HOUR Registers are not reset to
00H after a hardware or watchdog timer reset. This is to prevent
the need to recalibrate the real-time clock after a reset. However,
these registers will be reset to 00H after a power cycle (indepen-
dent of TCEN) or after any reset if TCEN is clear.
Six SFRs are associated with the time interval counter, TIMECON
being its control register. Depending on the con fi g u ra tion of the
IT0 and IT1 bits in TIMECON, the selected time counter register
overfl ow will clock the interval counter. When this counter is equal
to the time interval value loaded in the INTVAL SFR, the TII
bit (TIMECON.2) is set and gen er ates an interrupt if enabled.
(See IEIP2 SFR description under the Interrupt System section.)
Bit
7
6
5
4
3
2
1
0
ADuC836
Periodically waking up the part from power-down
Im ple ment ing a real-time clock
Counting longer intervals than the standard 8051 compatible
timers are capable of
Name
–––
–––
ITS1
ITS0
STI
TII
TIEN
TCEN
Description
Reserved for Future Use
Reserved for Future Use. For future product code compatibility, this bit should be written as a 1.
Interval Timebase Selection Bits.
Written by user to determine the interval counter update rate.
ITS1
0
0
1
1
Single Time Interval Bit.
Set by user to generate a single interval timeout. If set, a timeout will clear the TIEN bit.
Cleared by user to allow the interval counter to be automatically reloaded and start counting again at each interval
timeout.
TIC Interrupt Bit.
Set when the 8-bit interval counter matches the value in the INTVAL SFR.
Cleared by user soft ware.
Time Interval Enable Bit.
Set by user to enable the 8-bit time interval counter.
Cleared by user to disable and clear the contents of the 8-bit interval counter. To ensure that the 8-bit interval
counter is cleared, TIEN must be held low for at least 30.5 s (32 kHz).
Time Clock Enable Bit.
Set by user to enable the time clock to the time interval counters.
Cleared by user to disable the 32 kHz clock to the TIC and clear the 8-bit prescaler and the HTHSEC, SEC,
MIN, and HOURS SFRs. To ensure that these registers are cleared, TCEN must be held low for at least 30.5 s
(32 kHz). The time registers (HTHSEC, SEC, MIN, and HOUR) can be written only while TCEN is low.
ITS0
0
1
0
1
Table XVIII. TIMECON SFR Bit Designations
Interval Timebase
1/128 Second
Seconds
Minutes
Hours
–40–
If the ADuC836 is in Pow er-Down mode, again with TIC inter-
rupt enabled, the TII bit will wake up the device and resume
code execution by vec tor ing directly to the TIC interrupt service
vector address at 0053H. The TIC-related SFRs are described in
Table XVIII with a block diagram of the TIC shown in Figure 33.
TIME INTERVAL COUNTER INTERRUPT
TCEN
INTERVAL TIMEOUT
32.768kHz EXTERNAL CRYSTAL
Figure 33. TIC, Simplifi ed Block Diagram
HUNDREDTHS COUNTER
SECOND COUNTER
MINUTE COUNTER
HOUR COUNTER
PRESCALER
HOUR
8-BIT
HTHSEC
SEC
MIN
INTERVAL COUNTER
INTVAL SFR
EQUAL?
8-BIT
SELECTION
TIMEBASE
INTERVAL
ITS0, 1
MUX
REV. 0
TIEN

Related parts for EVAL-ADUC836QS