Renesas RA Family Getting Started with Low Power Applications for RA6 and
RA4 Groups
R11AN0471EU0104 Rev.1.04 Page 20 of 40
Oct.1.21
4. Application Architectures
Figure 17 shows transitions between LPM and Normal mode in LPM applications. The WFI instructions
activate LPM, the configured interrupt such as AGT1 underflow interrupt or external interrupt IRQ13-DS
cancels LPM and wakes up the MCU.
Note: The transition from the Normal Mode to the Deep Software Standby mode is handled internally by the
LPM driver via the Software Standby mode with the
DPSBYCR.DPSBY bit set to 1.
Figure 17. Transition Between LPM and Normal Mode
4.1 Clock Changing and LPM Transition
This application demonstrates the use case where the clock source to the CPU is changed at runtime. It also
demonstrates entering and exiting the different LPM using the API provided by the FSP. Without the
availability of the APIs, a developer would need to configure the registers related to LPM and CGC manually,
thereby adding to the development timeline.
The following Figure 18 shows the different clock sources and the associated LPM used in the application
and different transition states. The application implemented using the event driven mechanism. In this event
driven system, events can be user driven or system generated, which are used as the input to the finite state
machine. Two separate state transition tables are used here in the application.
• Clock transition table (clock_transition_table)
• LPM Transition table (lpm_transition_table).
The transition table has the list of actions to be performed based on the events received. For instance, when
user event “Button Press - Long” is received upon power on reset, the finite state machine will start running
and change the clock to HOCO. If user event “Button Press – Short“ is received, the finite state machine will
switch to the LPM state machine and start the LPM operation.