
Understanding the eTPU Channel Hardware, Rev. 0
Architecture of the eTPU Channel
Freescale Semiconductor
4
2.2
Action Units
There are two sets of match and capture registers associated with each channel. These are referred to as
Action Unit A
and
Action Unit B
and the corresponding match and capture registers are also designated
A
and
B
. Earlier documentation used the numbers 1 and 2 respectively to distinguish these units, and some
older software samples and primitive identifiers may continue to use the old designation.
The action units include one each match and capture registers, and associated latches which are described
below.
2.2.1
Match Registers
Action units A and B are similar but not identical. Each one has a match register and a capture register,
which are identical. The differences in the action units are controlled by the channel mode logic
configuration.
The match registers consist of a register holding a match value and a comparators continuously comparing
the register value with a selected TCR. The comparators can operate either in an
equals-only
or a
greater-than-or-equal
mode. In
equals-only
, the comparators asserts on a clock cycle when the selected
TCR exactly equals the register value. In
greater-than-or-equal
, the comparator makes a relative
comparison of the register value with the TCR. The match is satisfied if the TCR is equal to or no more
than 0x7FFFFF greater than the register value. For a detailed discussion of this comparison, please see the
Reference Manual.
When either Match Register A or Match Register B comparator asserts, it sets the corresponding match
recognition latch
MatchALatch
(
MRLA)
or
MatchBLatch
(
MRLB)
.
2.2.2
Capture Registers
Pin transitions or matches can cause the capture registers in the action units to latch the value of either
TCR1 or TCR2 at the time of the match event or pin transition. In general, a TCR value can be captured
on a match--for example, to catch the time a certain angle triggered action occurred--but if a programmed
transition is detected, the capture value will overwrite a previously captured match. Also, a first transition
might capture both TCRs, but a second transition may overwrite one of them. The exact details on what is
captured on which event is described in
Section 3, “Channel Modes
.”
2.2.3
Transition Detect Latches
A pin action which captures one or more TCRs will also set the corresponding transition detect latch
(TDL),
TransitionALatch
(
TDLA
) or
TransitionBLatch
(
TDLB
).
The TDLs are always set coherently with the capture of the TCR in the capture register, so if the TDL is
set, the capture register will hold the value in the TCR at the time of the transition. Note that service may
have been requested by a match or previous transition when a transition occurs. When the scheduler grants
service to a channel, the eTPU executes a Time Slot Transition (TST), during which it sets up the
environment for the channel service. As part of the TST, the eTPU latches the state of the TDLs for