2 timers clock, 3 time counter (tmcnt), Timers clock -4 – Motorola MPC8260 User Manual

Page 142: Time counter (tmcnt) -4, Timers clock generation -4, See section 4.1.3, òtime counter (tmcnt)

Advertising
background image

4-4

MPC8260 PowerQUICC II UserÕs Manual

MOTOROLA

Part II. ConÞguration and Reset

4.1.2 Timers Clock

The two SIU timers (the time counter and the periodic interrupt timer) use the same clock
source, timersclk, which can be derived from several sources, as described in Figure 4-3.

Figure 4-3. Timers Clock Generation

For details, see Section 35.2.4, ÒPort Pin Assignment Register (PPAR).Ó For proper time
counter operation, the user must ensure that the frequency of timersclk for TMCNT is
8,192 Hz by properly selecting the external clock and programming BRG1 and the
prescaler control bits in the time counter status and control register (TMCNTSC[TCF]) and
periodic interrupt status and control register (PISCR[PTF]).

4.1.3 Time Counter (TMCNT)

The time counter (TMCNT) is a 32-bit counter that is clocked by timersclk. It provides a
time-of-day indication to the operating system and application software. The counter is
reset to zero on PORESET reset but is not affected by soft or hard reset. It is initialized by
the software; the user should set the timersclk frequency to 8,192 Hz, as explained in
Section 4.1.2, ÒTimers Clock.Ó

TMCNT can be programmed to generate a maskable interrupt when the time value matches
the value in its associated alarm register. It can also be programmed to generate an interrupt
every second. The time counter control and status register (TMCNTSC) is used to enable
or disable the various timer functions and report the interrupt source. Figure 4-4 shows a
block diagram of TMCNT.

PC[29]

PC[25]

CPM clock

PC[27]

PC[26]

Ports Programming

The user should select external clock
and/or BRG1 programming to yield ei-
ther 4 MHz or 32 KHz at this point.

BRG1

Divide by 512

Divide by 4

PISCR[PTF]

TMCNTSC[TCF]

Ports Programming

timersclk for TMCNT

timersclk for PIT

Advertising