13.4.2.1 OSC32K - Internal 32.768 kHz Oscillator Operation

The OSC32K provides a tunable, low-speed, and low-power clock source. OSC32K runs whenever it is requested by any peripheral.

Once OSC32K is stable and ready to be used as a clock source, the OSC32K Ready bit in the STATUS register (STATUS.OSC32KRDY) is set to ‘1’. An interrupt is generated on the OSC32RDY ‘0’ to ‘1’ transition if the OSC32K Ready bit in the Interrupt Enable Set register (INTENSET.OSC32KRDY) is set to ‘1’.

It is possible to lock the OSC32K configuration by setting the Write Lock bit in the OSC32KCTRL register (OSC32KCTRL.WRTLOCK) to ‘1’. The OSC32K configuration is now locked until a Device Reset is detected.

OSC32K can be used as a source for the Real-Time Counter (RTC). A clock request for the OSC32K is automatically generated. Before enabling the RTC peripheral, the corresponding oscillator output must be selected in the RTC Clock Source Selection bit field in the RTC Control register (RTCCTRL.RTCSEL). Also, the OSC32K oscillator must be configured in the OSC32KCTRL register in order to ensure proper operation. For details on RTC clock configuration, refer to the Real-Time Counter Clock Selection section.

OSC32K can also be used as a source for Generic Clock Generators (GCLK), the Watchdog Timer (WDT), or for other peripherals through a generic clock request interface implemented in hardware. Requests over this interface will start the oscillator if it is not already running. Before enabling the peripheral that will generate a clock request, the oscillator must be configured in the OSC32KCTRL register to ensure proper operation.