19.7.8 32 kHz External Crystal Oscillator (XOSC32K) Control

Table 19-9. Register Bit Attribute Legend
SymbolDescriptionSymbolDescriptionSymbolDescription
RReadable bitHCCleared by Hardware(Grey cell)Unimplemented
WWritable bitHSSet by HardwareXBit is unknown at Reset
KWrite to clearSSoftware settable bit
Name: XOSC32K
Offset: 0x1C
Reset: 0x00200080
Property: PAC Write-Protection

Bit 3130292827262524 
          
Access  
Reset  
Bit 2322212019181716 
   CGM[3:0]   
Access R/WR/WR/WR/W 
Reset 1000 
Bit 15141312111098 
     STARTUP[3:0] 
Access R/WR/WR/WR/W 
Reset 0000 
Bit 76543210 
 ONDEMAND    XTALENENABLE  
Access R/WR/WR/W 
Reset 100 

Bits 21:18 – CGM[3:0] Control Gain Mode

These bits control the gain of the external crystal oscillator.

These bits are enable-protected.

ValueNameDescription
0x0CGM0The lower Control Gain Mode value
0x1CGM1A higher Control Gain Mode value than CGM0
0x2CGM2A higher Control Gain Mode value than CGM1
0x3CGM3A higher Control Gain Mode value than CGM2
0x4CGM4A higher Control Gain Mode value than CGM3
0x5CGM5A higher Control Gain Mode value than CGM4:
  • Min Recommended for SF=3, ESR ≤ 100K
  • Min Recommended for SF=5, ESR ≤ 60K
0x6CGM6A higher Control Gain Mode value than CGM5
0x7CGM7A higher Control Gain Mode value than CGM6
0x8CGM8A higher Control Gain Mode value than CGM7
0x9CGM9A higher Control Gain Mode value than CGM8
0xACGM10A higher Control Gain Mode value than CGM9, ( Min Recommended for SF=5, ESR ≤ 100K)
0xBCGM11A higher Control Gain Mode value than CGM10
0xCCGM12A higher Control Gain Mode value than CGM11
0xDCGM13A higher Control Gain Mode value than CGM12
0xECGM14A higher Control Gain Mode value than CGM13
0xFCGM15The highest Control Gain Mode value
Note:
  1. These bits are enable-protected. They cannot be written to if XOSC32K.ENABLE = 1.

Bits 11:8 – STARTUP[3:0] Oscillator Start-Up Time

These bits select the start-up time for the XOSC32K oscillator. The OSCULP32K oscillator is used to clock the start-up counter. The given time assumes an XOSC32K crystal frequency of 32.768 kHz.

After the XOSC32K.STARTUP time has expired, the XOSC32K clock is released internally after the selected programmable startup clock cycles plus 3 additional XOSC32 periods. The Clock Fail Detect (CFD) monitoring also starts when the clock is released for internal use. The user selected start-up time must equal or exceed the start-up time defined in the electrical characteristics.

STARTUP[2:0]OSCULP32K Clock CyclesPlus

XOSC32K

Clock Cycles

Equal

Approximate

Equivalent Time

0x01+3=~122 µs
0x116+3=~580 µs
0x232+3=~1.07 ms
0x32048+3=~62.6 ms
0x44096+3=~125.1 ms
0x58192+3=~250.1 ms
0x616384+3=~500.1 ms
0x732768+3=~1s
0x865536+3=~2s
0x9131072+3=~4s
0xA262144+3=~8s
0xB – 0xF------------Reserved
Note: These bits are enable-protected. They cannot be written to if XOSC32K.ENABLE = 1.

These bits are valid only when XOSC32K.XTALEN = 1, crystal XOSC32K selected.

Bit 7 – ONDEMAND On Demand Control

This bit controls how the XOSC32K behaves when a peripheral clock request is detected.

Note: This bit is enable-protected. It cannot be written to if XOSC32K.ENABLE = 1.
ValueDescription
0XOSC32K always run
1Only run if requested by a peripheral

Bit 2 – XTALEN Crystal Oscillator Enable

This bit controls the connections between the I/O pads and the external clock or crystal oscillator.

Note: This bit is enable-protected. It cannot be written to if XOSC32K.ENABLE = 1.
ValueDescription
0External clock connected on XIN32. XOUT32 can be used as general-purpose I/O.
1Crystal connected to XIN32/XOUT32.

Bit 1 – ENABLE Oscillator Enable

Note: It is necessary to wait for STATUS.XOSC32KRDY = 0 before enabling the XOSC32K.
ValueDescription
0The 32K oscillator is disabled.
1The 32K oscillator is enabled.