29.6.14 Sleep Mode Operation
The Run in Standby bits in the Comparator x Control registers (COMPCTRLx.RUNSTDBY) control the behavior of the AC during standby sleep mode. Each RUNSTDBY bit controls one comparator. When the bit is zero, the comparator is disabled during sleep, but maintains its current configuration. When the bit is one, the comparator continues to operate during sleep. Note that when RUNSTDBY is zero, the analog blocks are powered off for the lowest power consumption. This necessitates a start-up time delay when the system returns from sleep.
When RUNSTDBY is one, any enabled AC interrupt source can wake up the CPU. While the CPU is sleeping, single-shot comparisons are only triggerable by events. The AC can also be used during sleep modes where the clock used by the AC is disabled, provided that the AC is still powered (not in shutdown). In this case, the behavior is slightly different and depends on the measurement mode.
COMPCTRLx.MODE | RUNSTDBY=0 | RUNSTDBY=1 |
---|---|---|
0 (Continuous) | COMPx disabled | GCLK_AC_DIG stopped, COMPx enabled |
1 (Single-shot) | COMPx disabled | GCLK_AC_DIG stopped, COMPx enabled only when triggered by an input event |