![Texas Instruments AM1808 Technical Reference Manual Download Page 521](http://html.mh-extra.com/html/texas-instruments/am1808/am1808_technical-reference-manual_1094558521.webp)
PWM duty
(0 to 1.0 in Q15 format)
PWM period (N CPU cycles)
MEP step
MEP scale factor
Number of MEP steps
in one coarse step
Coarse step size
16−bit CMPA register value
16−bit CMPAHR register value
= number of coarse steps
= (number of MEP steps) << 8 + 0x180 (rounding)
(A)
Number of coarse steps
Number of MEP steps
= integer(PWMduty * PWMperiod)
= fraction(PWMduty * PWMperiod) * (MEPScaleFactor)
Architecture
521
SPRUH82C – April 2013 – Revised September 2016
Copyright © 2013–2016, Texas Instruments Incorporated
Enhanced High-Resolution Pulse-Width Modulator (eHRPWM)
16.2.10.2 Architecture of the High-Resolution PWM Submodule
The HRPWM is based on micro edge positioner (MEP) technology. MEP logic is capable of positioning an
edge very finely by sub-dividing one coarse system clock of a conventional PWM generator. The time step
accuracy is on the order of 150 ps. The HRPWM also has a self-check software diagnostics mode to
check if the MEP logic is running optimally, under all operating conditions.
shows the relationship between one coarse system clock and edge position in terms of MEP
steps, which are controlled via an 8-bit field in the Compare A extension register (CMPAHR).
Figure 16-45. Operating Logic Using MEP
A
For MEP range and rounding adjustment.
To generate an HRPWM waveform, configure the TBM, CCM, and AQM registers as you would to
generate a conventional PWM of a given frequency and polarity. The HRPWM works together with the
TBM, CCM, and AQM registers to extend edge resolution, and should be configured accordingly. Although
many programming combinations are possible, only a few are needed and practical.
16.2.10.3 Controlling and Monitoring the High-Resolution PWM Submodule
The MEP of the HRPWM is controlled by two extension registers, each 8-bits wide. These two HRPWM
registers are concatenated with the 16-bit TBPHS and CMPA registers used to control PWM operation.
•
TBPHSHR - Time-Base Phase High-Resolution Register
•
CMPAHR - Counter-Compare A High-Resolution Register
lists the registers used to control and monitor the high-resolution PWM submodule.
Table 16-32. HRPWM Submodule Registers
Acronym
Register Description
Address Offset
Shadowed
TBPHSHR
Extension Register for HRPWM Phase
4h
No
CMPAHR
Extension Register for HRPWM Duty
10h
Yes
HRCNFG
HRPWM Configuration Register
1040h
No