The prescaler is OFF when both functions are OFF (RTC Peripheral
Enable (RTCEN) bit in RTC.CTRLA and the Periodic Interrupt Timer Enable (PITEN) bit
in RTC.PITCTRLA are ‘0
’), but it is running (that is, its internal
counter is counting) when either function is enabled. For this reason, the timing of
the first PIT interrupt and the first RTC count tick will be unknown (anytime
between enabling and a full period).
For PERIOD=CYC16 in RTC.PITCTRLA, the PIT output effectively follows the state of the prescaler counter bit 3, so the resulting interrupt output has a period of 16 CLK_RTC cycles.
The time between writing PITEN to ‘1’ and the first PIT interrupt can vary between virtually zero and a full PIT period of 16 CLK_RTC cycles. The precise delay between enabling the PIT and its first output depends on the prescaler’s counting phase: the first interrupt shown below is produced by writing PITEN to ‘1’ at any time inside the leading time window.