English
Language : 

PXR40RM Datasheet, PDF (1239/1434 Pages) Freescale Semiconductor, Inc – PXR40 Microcontroller
Enhanced Time Processing Unit (eTPU2)
the STAC bus imported value. The use of EAC is not allowed in client mode. This mode is configured
through the register ETPUREDCR (see Section 29.2.6.4, ETPUREDCR - eTPU STAC Configuration
Register).
29.3.5.2.5 STAC Bus Server Mode
When TCR2 bus is exported to the STAC bus as a server, it can provide either time or angle bus to other
peripherals, according to its operation mode. This mode is configured through the register ETPUREDCR
(see Section 29.2.6.4, ETPUREDCR - eTPU STAC Configuration Register). To provide sequential update
of the STAC clients, the Angle tick rate must not be faster than the STAC programmed update rate. This
requirement puts a limitation on the angle clock count rate on high rate mode. In this case the Angle and
Angle Fraction accumulator (see the eTPU Reference Manual for details) are advanced at rate of eTPU
clock divided by eight. Therefore, the STAC update rate for the Angle Bus must not be slower than eight
eTPU clocks.
29.3.5.2.6 TCR2 Bus in Angle Clock Mode
In this mode the TCR2 counter operates as part of the eTPU Angle Counter (EAC). The TCR2 bus value
reflects this angle representation in which it counts Angle Ticks. Angle Mode is selected when the AM bit
is set in ETPUTBCR.
Note that when TCR2 works in Angle Mode, it does not count directly from the TCR2 clock input which
indicates tooth signal transition. Its Angle counter is controlled by the Count Control and High Rate logic
(see the eTPU Reference Manual for details), which provides the interpolated pin position, and handle
cases of missing tooth, acceleration, de-acceleration and mechanical corrections.
The EAC uses the TCRCLK signal to get the tooth transition indications. The TCR2CTL field in
ETPUTBCR has to be set for the appropriate tooth edge detection rise, fall, “rise-and-fall” or none. TCR2
count clock comes from the EAC control and not directly from the physical tooth. This way the EAC
control processes the signal transitions and handles missing teeth and flywheel mechanical corrections.
Note that when TCR2CTL selects “none” for tooth edge selection, the TCR2 is not necessarily frozen, but
can still be incremented by the EAC logic.
In Angle Mode, eTPU channel 0, 1 or 2 operation is combined with the EAC operation. When channel 0
is selected for EAC operation, the TCRCLK digital filter is used both by the EAC and by channel 0 to get
full synchronization between the two logics.
The eTPU Angle Counter (EAC) logic runs continuously and updates the TCR2 Angle counter,
eliminating the microcode latency in updating the TCR2 value.
29.3.5.3 STAC Interface
Both time bases TCR1 and TCR2 can be shared between the Engines and with other blocks in the same
MCU. Each one of both eTPU engines can drive their time bases to the STAC (Shared Time and Count)
bus, acting as a server, while any other block can capture the value into its resources and behave like a
client. For further reference about the STAC bus operation refer to Section 29.2.6.4, ETPUREDCR - eTPU
STAC Configuration Register.
The eTPU can export to the STAC bus or import from the STAC bus the following internal resources:
Freescale Semiconductor
PXR40 Microcontroller Reference Manual, Rev. 1
29-71