MPC563XM Reference Manual, Rev. 1
842
Freescale Semiconductor
Preliminary—Subject to Change Without Notice
23.4.6
Time Bases
Each eTPU engine has two Time Counter Registers, TCR1 and TCR2. They provide 24-bit time bases,
shared by all 32 channels. Any channel can use both time bases to:
•
Match channel’s internal registers Match1 or Match2;
•
Capture time base value to channel’s internal registers, Capture1 and/or Capture2, when a match
recognition or an Input transition detection occurs. For more information on channel events refer
to
Section 23.4.5, “Enhanced Channels
.”
The TCR1 and TCR2 counters are accessible by the microcode for read and write operations. Its current
value is used for getting the current time, and the captured values are used for channel relative time
calculations of future events. When they are written at the same time they are incremented from any clock
source, the written value prevails.
TCR1 with ETPUTBCR[TCR1CS]=0 and TCR2 values are updated in T2 and read in T4 (see
Section 23.6.1, “Microcycle and I/O Timing
). TCR1 can also work at full-speed system clock, and so be
updated on both T2 and T4, when ETPUTBCR[TCR1CS]=1. Both TCR1 and TCR2 values can be
imported from or exported to the Red Line (STAC) bus. When their values are imported (Red Line
Clients), these registers are written from the Red Line bus and can only be read by microcode. For
information on Red Line bus protocol and definition of Red Line modules refer to IPI Red Line and
Section 23.4.6.3, “Red Line Interface
The TCR2 counters between the two Engines are out of phase by 1 system clock, even when Time Bases
are shared between them through Red Line. It also applies to TCR1 counters if ETPUTBCR[TCR1CS]=0,
but they can be in phase otherwise.
23.4.6.1
Timer Count Register 1 - TCR1
TCR1 can be used in the following modes:
•
Internally Clocked Mode
•
Externally Clocked Mode
•
Red Line (STAC) Bus Client Mode
The host program can read TCR1 time base through the ETPUTB1R (see
- eTPU Time Base 1 (TCR1) Visibility Register
The TCR1 bus runs through all the local engine channels. In channels which select TCR1 as Match1 and/or
Match2 source, when its value is greater or equal to the programmed match value, a match1 and/or match2
event occurs on that channel. A recognized match event sets its related Match Recognition Latch 1 or 2,
and according to the Predefined Channel Modes (PDCM) it may generate a channel service request. For
details on eTPU channels refer to
Section 23.4.5, “Enhanced Channels
23.4.6.1.1
Externally Clocked Mode
TCR1 can be driven externally by the TCRCLK input, after the digital filter. The TCR1 clock source is
configured by the TCR1CTL bit, as shown in
. For more information on clock source
selection, please refer to
Section 23.3.3.1, “ETPUTBCR - eTPU Time Base Configuration Register
.”
Содержание MPC5632M
Страница 22: ...MPC563XM Reference Manual Rev 1 22 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 62: ...MPC563XM Reference Manual Rev 1 62 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 92: ...MPC563XM Reference Manual Rev 1 92 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 168: ...MPC563XM Reference Manual Rev 1 168 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 242: ...MPC563XM Reference Manual Rev 1 242 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 302: ...MPC563XM Reference Manual Rev 1 302 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 410: ...MPC563XM Reference Manual Rev 1 410 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 440: ...MPC563XM Reference Manual Rev 1 440 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 464: ...MPC563XM Reference Manual Rev 1 464 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 554: ...MPC563XM Reference Manual Rev 1 554 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 590: ...MPC563XM Reference Manual Rev 1 590 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 622: ...MPC563XM Reference Manual Rev 1 622 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 716: ...MPC563XM Reference Manual Rev 1 716 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 1114: ...MPC563XM Reference Manual Rev 1 1114 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 1144: ...MPC563XM Reference Manual Rev 1 1144 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 1266: ...MPC563XM Reference Manual Rev 1 1266 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 1316: ...MPC563XM Reference Manual Rev 1 1316 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 1348: ...MPC563XM Reference Manual Rev 1 1348 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 1362: ...MPC563XM Reference Manual Rev 1 1362 Freescale Semiconductor Preliminary Subject to Change Without Notice ...
Страница 1382: ...MPC563XM Reference Manual Rev 1 1382 Freescale Semiconductor Preliminary Subject to Change Without Notice ...