18.8.4 Peripheral Channel Control

PCHTRLm controls the settings of Peripheral Channel number m (m=0..20).

Name: PCHCTRLm
Offset: 0x80 + m*0x04 [m=0..20]
Reset: 0x00000000
Property: PAC Write-Protection

Bit 3130292827262524 
          
Access  
Reset  
Bit 2322212019181716 
          
Access  
Reset  
Bit 15141312111098 
          
Access  
Reset  
Bit 76543210 
 WRTLOCKCHEN   GEN[2:0] 
Access R/WR/WR/WR/WR/W 
Reset 00000 

Bit 7 – WRTLOCK Write Lock

After this bit is set to '1', further writes to the PCHCTRLm register will be discarded. The control register of the corresponding Generator n (GENCTRLn), as assigned in PCHCTRLm.GEN, will also be locked. It can only be unlocked by a Power Reset.

Note that Generator 0 cannot be locked.

ValueDescription
0The Peripheral Channel register and the associated Generator register are not locked
1The Peripheral Channel register and the associated Generator register are locked

Bit 6 – CHEN Channel Enable

This bit is used to enable and disable a Peripheral Channel.

CAUTION: When changing this bit, the bit value must be read-back to ensure the synchronization is complete (polling method).
ValueDescription
0The Peripheral Channel is disabled
1The Peripheral Channel is enabled

Bits 2:0 – GEN[2:0] Generator Selection

This bit field selects the Generator to be used as the source of a peripheral clock, as shown in the table below:

Table 18-7. Generator Selection
ValueDescription
0x0Generic Clock Generator 0
0x1Generic Clock Generator 1
0x2Generic Clock Generator 2
0x3Generic Clock Generator 3
0x4Generic Clock Generator 4
Table 18-8. Reset Value after a User Reset or a Power Reset
ResetPCHCTRLm.GENPCHCTRLm.CHENPCHCTRLm.WRTLOCK
Power Reset0x00x00x0
User Reset

If WRTLOCK = 0
: 0x0

If WRTLOCK = 1: no change

If WRTLOCK = 0
: 0x0

If WRTLOCK = 1: no change

No change

A Power Reset will reset all the PCHCTRLm registers.

A User Reset will reset a PCHCTRL if WRTLOCK=0, or else, the content of that PCHCTRL remains unchanged.

The PCHCTRL register Reset values are shown in the table below.

Table 18-9. PCHCTRLm Mapping
index(m)NameDescription
0GCLK_DPLLFDPLL96M input clock source for reference
1GCLK_DPLL_32KFDPLL96M 32 kHz clock for FDPLL96M internal clock timer
2GCLK_DFLLULPDFLLULP clock for DFLLULP
3GCLK_EICEIC
4GCLK_FREQM_MSRFREQM Measure
5GCLK_FREQM_REFFREQM Reference
6GCLK_EVSYS_CHANNEL_0EVSYS_CHANNEL_0
7GCLK_EVSYS_CHANNEL_1EVSYS_CHANNEL_1
8GCLK_EVSYS_CHANNEL_2EVSYS_CHANNEL_2
9GCLK_EVSYS_CHANNEL_3EVSYS_CHANNEL_3
10GCLK_SERCOM[0,1,2]_SLOWSERCOM[0,1,2]_SLOW
11GCLK_SERCOM0_CORESERCOM0_CORE
12GCLK_SERCOM1_CORESERCOM1_CORE
13GCLK_SERCOM2_CORESERCOM2_CORE
14GCLK_TC0, GCLK_TC1TC0,TC1
15GCLK_TC2TC2
16GCLK_ADCADC
17GCLK_ACAC
18GCLK_DACDAC
19GCLK_PTCPTC
20GCLK_CCLCCL