Datasheet

Table Of Contents
rely on a mechanism that is transparent to software and provides low latency wakeup.
The WFE mechanism relies on hardware and software working together to achieve energy saving. For example, stalling
execution of a processor until a device or another processor has set a flag:
the hardware provides the mechanism to enter the WFE low-power state.
software enters a polling loop to determine when the flag is set:
the polling processor issues a WFE instruction as part of a polling loop if the flag is clear.
an event is generated (hardware interrupt or Send-Event instruction from another processor) when the flag is set.
WFE wake up events
The following events are WFE wake up events:
the execution of an SEV instruction on the other processor
any exception entering the pending state if SEVONPEND in the System Control Register is set to 1.
an asynchronous exception at a priority that preempts any currently active exceptions.
a debug event with debug enabled.
The Event Register
The Event Register is a single bit register. When set, an Event Register indicates that an event has occurred, since the
register was last cleared, that might prevent the processor having to suspend operation on issuing a WFE instruction. The
following conditions apply to the Event Register:
A reset clears the Event Register.
Any WFE wakeup event, or the execution of an exception return instruction, sets the Event Register.
A WFE instruction clears the Event Register.
Software cannot read or write the value of the Event Register directly.
The Send-Event instruction
The Send-Event (SEV) instruction causes an event to be signalled to the other processor. The Send-Event instruction
generates a wakeup event.
The Wait For Event instruction
The action of the WFE instruction depends on the state of the Event Register:
If the Event Register is set, the instruction clears the register and returns immediately.
If the Event Register is clear the processor can suspend execution and enter a low-power state. It can remain in
that state until the processor detects a WFE wakeup event or a reset. When the processor detects a WFE wakeup
event, the WFE instruction completes.
WFE wakeup events can occur before a WFE instruction is issued. Software using the WFE mechanism must tolerate
spurious wake up events, including multiple wakeups.
2.4.2.8.3. Wait For Interrupt
RP2040 supports Wait For Interrupt through the hint instruction, WFI.
When a processor issues a WFI instruction it can suspend execution and enter a low-power state. It can remain in that
state until the processor detects one of the following WFI wake up events:
A reset.
An asynchronous exception at a priority that, if PRIMASK.PM was set to 0, would preempt any currently active
exceptions.
RP2040 Datasheet
2.4. Cortex-M0+ 67