English
Language : 

MC68HC908GT16_07 Datasheet, PDF (217/292 Pages) Freescale Semiconductor, Inc – Microcontrollers
Chapter 17
Timebase Module (TBM)
17.1 Introduction
This section describes the timebase module (TBM). The TBM will generate periodic interrupts at user
selectable rates using a counter clocked by the external crystal clock. This TBM version uses 15 divider
stages, eight of which are user selectable.
17.2 Features
Features of the TBM include:
• Software programmable 1-Hz, 4-Hz, 16-Hz, 256-Hz, 512-Hz, 1024-Hz, 2048-Hz, and 4096-Hz
periodic interrupt using external 32.768-kHz crystal
• User selectable oscillator clock source enable during stop mode to allow periodic wakeup from stop
17.3 Functional Description
NOTE
This module is designed for a 32.768-kHz oscillator.
This module can generate a periodic interrupt by dividing the clock TBMCLK. The counter is initialized to
all 0s when TBON bit is cleared. The counter, shown in Figure 17-1, starts counting when the TBON bit
is set. When the counter overflows at the tap selected by TBR2:TBR0, the TBIF bit gets set. If the TBIE
bit is set, an interrupt request is sent to the CPU. The TBIF flag is cleared by writing a 1 to the TACK bit.
The first time the TBIF flag is set after enabling the timebase module, the interrupt is generated at
approximately half of the overflow period. Subsequent events occur at the exact period.
MC68HC908GT16 • MC68HC908GT8 • MC68HC08GT16 Data Sheet, Rev. 5.0
Freescale Semiconductor
217