Power Reduction Techniques; Turn Off Peripherals In Modustoolbox™ Software; Turn Off Components In Psoc™ Creator - Infineon PSoC 4000S Manual

4 mcu low-power modes and power reduction techniques
Table of Contents

Advertisement

PSoC™ 4 MCU low-power modes and power reduction techniques

Power reduction techniques

5
Power reduction techniques
In many applications, you can gain additional power reductions by properly managing PSoC™ 4 MCU blocks as
well as powering down external components. This section presents some techniques for doing so.
5.1
Turn OFF peripherals in ModusToolbox™ software
You can save unnecessary current consumption by disabling unused blocks. The power saved depends on the
block disabled.
Any block that can be disabled in active or sleep mode is supported by__Enable() and _Disable()
functions. The _Disable() function immediately halts all operations of the peripheral. The peripheral may
be actively performing a task, so check its status before disabling it. The following code snippet uses the
timer/counter from the TCPWM block as an example.
/* <Check task status here.> */
/* Disable the peripheral. */
Cy_TCPWM_Counter_Disable(TCPWM, MY_TCPWM_CNT_NUM);
Restart the peripheral by calling the _Enable() function. It is recommended that the peripheral be re-
initialized before enabling.
/* Initialize the peripheral */
Cy_TCPWM_Counter_Init(TCPWM, MY_TCPWM_CNT_NUM, &config);
/* Enable the peripheral. */
Cy_TCPWM_Counter_Enable(TCPWM, MY_TCPWM_CNT_NUM);
Some peripherals such as the TCPWM may need to be trigger started. This is a software trigger that ensures that
all TCPWM counters are started at the same time. Call this function when the when one or more TCPWM
counters need to be started.
/* Trigger start the peripheral. */
Cy_TCPWM_TriggerStart(TCPWM, MY_TCPWM_CNT_MASK);
Note:
Not all peripherals need to be trigger started, check the
information.
5.2
Turn OFF components in PSoC™ Creator
The easiest way to reduce power in active mode is to turn OFF unused PSoC™ Creator components.
Any component that can be disabled in active or Sleep mode includes a _Stop()function in its API. This
function immediately halts all operation of the component and sets it to its lowest power state. The component
may be actively performing a task, so check its status before stopping it.
Application Note
peripheral driver library(PDL)
12 of 38
for more
001-86233 Rev. *I
2021-11-04

Advertisement

Table of Contents
loading

Table of Contents