
M0A21/M0A23 Series
May 06, 2022
Page
314
of 746
Rev 1.02
M0
A21
/M
0
A
2
3
SE
RIES
TEC
H
NICAL
RE
FEREN
C
E
M
ANUAL
pin, and first capture event occurred at falling edge transfer.
011 = Capture event occurred when detect both rising and falling edge transfer on TMx_EXT (x= 0~3)
pin, and first capture event occurred at rising edge transfer.
110 = First capture event occurred at falling edge, follows capture events are at rising edge transfer on
TMx_EXT (x= 0~3) pin.
111 = First capture event occurred at rising edge, follows capture events are at falling edge transfer on
TMx_EXT (x= 0~3) pin.
100, 101 = Reserved.
Enable Single Pulse Mode:
000 = Measure
falling edge
falling edge
transfer on TMx_EXT (x= 0~3) pin.
001 = Measure
rising edge
rising edge
transfer on TMx_EXT (x= 0~3) pin.
110 = Measure
falling edge
rising edge
transfer on TMx_EXT (x= 0~3) pin.
111 = Measure
rising edge
falling edge
transfer on TMx_EXT (x= 0~3) pin.
010, 011, 100, 101 = Reserved.
[11]
Reserved
Reserved.
[10:8]
INTERCAPSEL
Internal Capture Source Selection to Trigger Capture Function
000 = Capture Function source is from internal ACMP0 output signal.
001 = Capture Function source is from internal ACMP1 output signal.
101 = Capture Function source is from LIRC.
Others = Reserved.
Note:
these bits only available when CAPSRC (TIMERx_CTL[16]) is 1.
[7]
CNTDBEN
Timer Counter Pin De-bounce Enable Bit
0 = TMx (x= 0~3) pin de-bounce Disabled.
1 = TMx (x= 0~3) pin de-bounce Enabled.
Note:
If this bit is enabled, the edge detection of TMx pin is detected with de-bounce circuit.
[6]
CAPDBEN
Timer External Capture Pin De-bounce Enable Bit
0 = TMx_EXT (x= 0~3) pin de-bounce or ACMP output de-bounce Disabled.
1 = TMx_EXT (x= 0~3) pin de-bounce or ACMP output de-bounce Enabled.
Note:
If this bit is enabled, the edge detection of TMx_EXT pin or ACMP output is detected with de-
bounce circuit.
[5]
CAPIEN
Timer External Capture Interrupt Enable Bit
0 = TMx_EXT (x= 0~3) pin, LIRC, or ACMP detection Interrupt Disabled.
1 = TMx_EXT (x= 0~3) pin, LIRC, or ACMP detection Interrupt Enabled.
Note:
CAPIEN is used to enable timer external interrupt. If CAPIEN enabled, timer will rise an interrupt
when CAPIF (TIMERx_EINTSTS[0]) is 1.
For example, while CAPIEN = 1, CAPEN = 1, and CAPEDGE = 00, a 1 to 0 transition on the Tx_EXT
(x= 0~3) pin, or ACMP will cause the CAPIF to be set then the interrupt signal is generated and sent to
NVIC to inform CPU.
[4]
CAPFUNCS
Capture Function Selection
0 = External Capture Mode Enabled.
1 = External Reset Mode Enabled.
Note 1:
When CAPFUNCS is 0, transition on TMx_EXT (x= 0~3) pin is using to save current 24-bit timer
counter value (CNT value) to CAPDAT field.
Note 2:
When CAPFUNCS is 1, transition on TMx_EXT (x= 0~3) pin is using to save current 24-bit timer
counter value (CNT value) to CAPDAT field then CNT value will be reset immediately.
[3]
CAPEN
Timer Capture Enable Bit
This bit enables the capture input function.
0 =Capture source Disabled.
1 =Capture source Enabled.