
UM10800
All information provided in this document is subject to legal disclaimers.
© NXP Semiconductors N.V. 2016. All rights reserved.
User manual
Rev. 1.2 — 5 October 2016
281 of 487
NXP Semiconductors
UM10800
Chapter 16: LPC82x SCTimer/PWM
16.6.20 SCT match registers 0 to 7 (REGMODEn bit = 0)
Match registers are compared to the counters to help create events. When the UNIFY bit
is 0, the L and H registers are independently compared to the L and H counters. When
UNIFY is 1, the combined L and H registers hold a 32-bit value that is compared to the
unified counter. A Match can only occur in a clock in which the counter is running (STOP
and HALT are both 0).
Match registers can be read at any time. Writing to the MATCH_L, MATCH_H, or unified
register is only allowed when the corresponding counter is halted (HALT bits are set to 1 in
the CTRL register). Match events occur in the SCT clock in which the counter is (or would
be) incremented to the next value. When a Match event limits its counter as described in
, the value in the Match register is the last value of the counter before it is
cleared to zero (or decremented if BIDIR is 1).
There is no “write-through” from Reload registers to Match registers. Before starting a
counter, software can write one value to the Match register used in the first cycle of the
counter and a different value to the corresponding Match Reload register used in the
second cycle.
16.6.21 SCT capture registers 0 to 7 (REGMODEn bit = 1)
These registers allow software to record the counter values upon occurrence of the events
selected by the corresponding Capture Control registers occurred.
16.6.22 SCT match reload registers 0 to 7 (REGMODEn bit = 0)
A Match register (L, H, or unified 32-bit) is loaded from its corresponding Reload register
at the start of each new counter cycle, that is
•
when BIDIR = 0 and the counter is cleared to zero upon reaching it limit condition.
Table 242. SCT match registers 0 to 7 (MATCH[0:7], address 0x5000 4100 (MATCH0) to
0x5000 411C (MATCH7)) bit description (REGMODEn bit = 0)
Bit
Symbol
Description
Reset
value
15:0
MATCHn_L
When UNIFY = 0, read or write the 16-bit value to be compared to
the L counter. When UNIFY = 1, read or write the lower 16 bits of
the 32-bit value to be compared to the unified counter.
0
31:16
MATCHn_H When UNIFY = 0, read or write the 16-bit value to be compared to
the H counter. When UNIFY = 1, read or write the upper 16 bits of
the 32-bit value to be compared to the unified counter.
0
Table 243. SCT capture registers 0 to 7 (CAP[0:7], address 0x5000 4100 (CAP0) to 0x5000
411C (CAP7)) bit description (REGMODEn bit = 1)
Bit
Symbol
Description
Reset
value
15:0
CAPn_L
When UNIFY = 0, read the 16-bit counter value at which this
register was last captured. When UNIFY = 1, read the lower 16 bits
of the 32-bit value at which this register was last captured.
0
31:16
CAPn_H
When UNIFY = 0, read the 16-bit counter value at which this
register was last captured. When UNIFY = 1, read the upper 16 bits
of the 32-bit value at which this register was last captured.
0