HET
Res.
Angle
increment
HET
counter
10
Compare
value
Associ-
ated Pin
With the ACMP instruction, the compare that is performed will be:
9
10
13
£
<
4
13
3
16
9
CNT
ACMP
Angle Functions
1012
SPNU563A – March 2018
Copyright © 2018, Texas Instruments Incorporated
High-End Timer (N2HET) Module
23.3.2.4.2.2 ACMP Instruction Advantage
The ACMP instruction is more than an equality compare. ACMP instruction performs an in-between
comparison (old angle value < compare value
≤
new angle value) to match the position of the toothed
wheel. This instruction, where an equality compare executes every resolution, may miss a compare
match. For an example of ACMP compare within the NHET, see
.
Figure 23-54. Example of ACMP Compare Within the NHET
With the ACMP instruction, the compare is: 9 < 10
≤
13
NOTE:
To avoid multiple matches, the ACMP only matches during a single resolution.
Performing the following equations at the same time implements this compare:
CMP > NHET angle counter – Angle increment
CMP
≤
NHET angle counter