execute the interrupt service routine or continue the normal program execution according to the
Priority Mask Register (PRIMASK) configuration of the CPU.
Regulators, RAMs, and NVM State in Sleep Mode
The regulator operates in low-power mode by default and switches automatically to the normal mode in
case of a sleepwalking task requiring more power. It returns automatically to low power mode when the
sleepwalking task is completed.
BACKUP Mode
The BACKUP mode allows achieving the lowest power consumption aside from OFF. The device is
entirely powered off except for the backup domain. All peripherals in backup domain are allowed to run,
e.g. the RTC can be clocked by a 32.768kHz oscillator. All PM registers are reset except the
•
Entering Backup mode: This mode is entered by executing the WFI instruction after selecting the
Backup mode by writing the Sleep Mode bits in the Sleep Configuration register
(
•
Exiting Backup mode: is triggered when a Backup Reset is detected by the Reset Controller
(RSTC).
OFF Mode
In OFF mode, the device is entirely powered-off.
•
Entering OFF mode: This mode is entered by selecting the OFF mode in the Sleep Configuration
register by writing the Sleep Mode bits (SLEEPCFG.SLEEPMODE=OFF), and subsequent
execution of the WFI instruction.
•
Exiting OFF mode: This mode is left by pulling the RESET pin low, or when a power Reset is done.
20.6.3.4. I/O Lines Retention in BACKUP Mode
When entering BACKUP mode, the PORT is powered off but the pin configuration is retained. When the
device exits the BACKUP mode, the I/O line configuration can either be released or stretched, based on
the I/O Retention bit in the CTRLA register (
•
If IORET=0 when exiting BACKUP mode, the I/O lines configuration is released and driven by the
reset value of the PORT.
•
If the IORET=1 when exiting BACKUP mode, the configuration of the I/O lines is retained until the
IORET bit is written to 0. It allows the I/O lines to be retained until the application has programmed
the PORT.
20.6.3.5. Performance Level
The application can change the performance level on the fly writing to the by Performance Level Select
bit in the Performance Level Configuration register (
.PLSEL).
When changing to a lower performance level, the bus frequency must be reduced before writing
PLCFG.PLSEL in order to avoid exceeding the limit of the target performance level.
When changing to a higher performance level, the bus frequency can be increased only after the
Performance Level Ready flag in the Interrupt Flag Status and Clear (INTFLAG.PLRDY) bit set to '1',
indicating that the performance level transition is complete.
After a reset, the device starts in the lowest PL (lowest power consumption and lowest max frequency).
The application can then switch to another PL at anytime without any stop in the code execution. As
shown in
, performance level transition is possible only when the device is in active mode.
The Performance Level Disable bit in the Performance Level Configuration register (PLCFG.PLDIS) can
be used to freeze the performance level to PL0. This disables the performance level hardware
Atmel SAM L22G / L22J / L22N [DATASHEET]
Atmel-42402E-SAM L22G / L22J / L22N_Datasheet_Complete-07/2016
193