Capture Module - Control and Status Registers
802
SPRUH22I – April 2012 – Revised November 2019
Copyright © 2012–2019, Texas Instruments Incorporated
C28 Enhanced Capture (eCAP) Module
NOTE:
In APWM mode, writing to CAP1/CAP2 active registers also writes the same value to the
corresponding shadow registers CAP3/CAP4. This emulates immediate mode. Writing to the
shadow registers CAP3/CAP4 invokes the shadow mode.
Figure 8-15. Capture-3 Register (CAP3)
31
0
CAP3
R/W-0
LEGEND: R/W = Read/Write; R = Read only; -
n
= value after reset
Table 8-5. Capture-3 Register (CAP3) Field Descriptions
Bit(s)
Field
Description
31:0
CAP3
In CMP mode, this is a time-stamp capture register. In APWM mode, this is the period shadow
(APRD) register. You update the PWM period value through this register. In this mode, CAP3
(APRD) shadows CAP1.
Figure 8-16. Capture-4 Register (CAP4)
31
0
CAP4
R/W-0
LEGEND: R/W = Read/Write; R = Read only; -
n
= value after reset
Table 8-6. Capture-4 Register (CAP4) Field Descriptions
Bit(s)
Field
Description
31:0
CAP4
In CMP mode, this is a time-stamp capture register. In APWM mode, this is the compare shadow
(ACMP) register. You update the PWM compare value via this register. In this mode, CAP4
(ACMP) shadows CAP2.
Figure 8-17. ECAP Control Register 1 (ECCTL1)
15
14
13
12
11
10
9
8
FREE/SOFT
PRESCALE
CAPLDEN
R/W-0
R/W-0
R/W-0
7
6
5
4
3
2
1
0
CTRRST4
CAP4POL
CTRRST3
CAP3POL
CTRRST2
CAP2POL
CTRRST1
CAP1POL
R/W-0
R/W-0
R/W-0
R/W-0
R/W-0
R/W-0
R/W-0
R/W-0
LEGEND: R/W = Read/Write; R = Read only; -
n
= value after reset
Table 8-7. ECAP Control Register 1 (ECCTL1) Field Descriptions
Bit(s)
Field
Value
Description
15:14
FREE/SOFT
Emulation Control
00
TSCTR counter stops immediately on emulation suspend
01
TSCTR counter runs until = 0
1x
TSCTR counter is unaffected by emulation suspend (Run Free)
13:9
PRESCALE
Event Filter prescale select
00000
Divide by 1 (i.e,. no prescale, by-pass the prescaler)
00001
Divide by 2
00010
Divide by 4
00011
Divide by 6