Atmel SAM4L Xplained Pro Evaluation Kit Atmel ATSAM4L-XPRO ATSAM4L-XPRO Data Sheet

Product codes
ATSAM4L-XPRO
Page of 1204
806
42023E–SAM–07/2013
ATSAM4L8/L4/L2
Figure 30-2. Clock Control
30.6.1.5
TC operating modes
Each channel can independently operate in two different modes:
• Capture mode provides measurement on signals.
• Waveform mode provides wave generation.
The TC operating mode selection is done by writing to the Wave bit in the CCRn register
(CCRn.WAVE). 
In Capture mode, TIOA and TIOB are configured as inputs.
In Waveform mode, TIOA is always configured to be an output and TIOB is an output if it is not
selected to be the external trigger.
30.6.1.6
Trigger
A trigger resets the counter and starts the counter clock. Three types of triggers are common to
both modes, and a fourth external trigger is available to each mode.
The following triggers are common to both modes:
• Software Trigger: each channel has a software trigger, available by writing a one to the 
Software Trigger Command bit in CCRn (CCRn.SWTRG).
• SYNC: each channel has a synchronization signal SYNC. When asserted, this signal has the 
same effect as a software trigger. The SYNC signals of all channels are asserted 
simultaneously by writing a one to the Synchro Command bit in the BCR register 
(BCR.SYNC).
• Compare RC Trigger: RC is implemented in each channel and can provide a trigger when the 
counter value matches the RC value if the RC Compare Trigger Enable bit in CMRn 
(CMRn.CPCTRG) is written to one.
Q
S
R
S
R
Q
CLKSTA
CLKEN
CLKDIS
Stop
Event
Disable
Counter
Clock
Selected
Clock
Trigger
Event