UM11029
All information provided in this document is subject to legal disclaimers.
© NXP Semiconductors N.V. 2017. All rights reserved.
User manual
Rev. 1.0 — 16 June 2017
392 of 515
NXP Semiconductors
UM11029
Chapter 21: LPC84x SCTimer/PWM
A state variable can be used to track and control multiple cycles of the associated counter
in any desired operational sequence. The state variable is logically associated with a state
machine diagram which represents the SCTimer/PWM configuration. See
and
for more about the relationship between states and events.
The STATELD/STADEV fields in the event control registers of all defined events set all
possible values for the state variable. The change of the state variable during multiple
counter cycles reflects how the associated state machine moves from one state to the
next.
If UNIFY = 1 in the CONFIG register, only the _L bits are used.
If UNIFY = 0 in the CONFIG register, this register can be written to as two registers
STATE_L and STATE_H. Both the L and H registers can be read or written individually or
in a single 32-bit read or write operation.
21.6.10 SCTimer/PWM input register
Software can read the state of the SCTimer/PWM inputs in this read-only register in
slightly different forms.
1. The AIN bit displays the state of the input captured on each rising edge of the
SCTimer/PWM clock This corresponds to a nearly direct read-out of the input but can
cause spurious fluctuations in case of an asynchronous input signal.
2. The SIN bit displays the form of the input as it is used for event detection. This may
include additional stages of synchronization, depending on what is specified for that
input in the INSYNC field in the CONFIG register:
–
If the INSYNC bit is set for the input, the input is triple-synchronized to the
SCTimer/PWM clock resulting in a stable signal that is delayed by three
SCTimer/PWM clock cycles.
–
If the INSYNC bit is not set, the SIN bit value is identical to the AIN bit value.
Table 393. SCTimer/PWM state register (STATE, offset 0x044) bit description
Bit
Symbol
Description
Reset
value
4:0
STATE_L
State variable.
0
15:5
-
Reserved.
-
20:16
STATE_H
State variable.
0
31:21
-
Reserved.
-
Table 394. SCTimer/PWM input register (INPUT, offset 0x048) bit description
Bit
Symbol
Description
Reset
value
0
AIN0
Input 0 state. Input 0 state on the last SCTimer/PWM clock edge.
-
1
AIN1
Input 1 state. Input 1 state on the last SCTimer/PWM clock edge.
-
2
AIN2
Input 2 state. Input 2 state on the last SCTimer/PWM clock edge.
-
3
AIN3
Input 3 state. Input 3 state on the last SCTimer/PWM clock edge.
-
4
AIN4
Input 4 state. Input 4 state on the last SCTimer/PWM clock edge.
-
15:5
-
Reserved.
-