The device can wake-up from Sleep through one of the following events:
When the SLEEP instruction is being
executed, the next instruction (PC + 2) is prefetched. For the device to wake-up through an
interrupt event, the corresponding Interrupt Enable bit must be enabled in the PIEx
register. Wake-up will occur regardless of the state of the Global Interrupt Enable (GIE)
bit. If the GIE bit is disabled, the device will continue execution at the instruction
after the SLEEP instruction. If the GIE bit is
enabled, the device executes the instruction after the SLEEP instruction and then call the Interrupt Service Routine (ISR).
NOP as the immediate instruction after the SLEEP
instruction.The WDT is cleared when the device wakes-up from Sleep, regardless of the source of wake-up. Upon a wake-from-Sleep event, the core will wait for a combination of three conditions before beginning execution. The conditions are: