AN4538
Application note
Power consumption optimization with STM32F3xx microcontrollers
Introduction
This application note describes how to optimize the power consumption of an application
based on STM32F3xx microcontrollers.
Reducing power consumption while performing complex real-time applications presents a
major challenge for the recent embedded applications.
This application note is splitted in two main parts:
•
•
The first part gives an overview of low-power design integrated features and
techniques to reduce the power consumption.
The second part describes a use case (a smart motor control application) that
highlights the power efficiency of STM32F3xx microcontrollers for the competitive
applications of the embedded system market.
This application note is provided with the STSW-STM32036 software package that contains
an example of STM32F3xx microcontroller low-power application. This application is based
on the USART, DMA, timer, comparator, RTC peripherals using STM32F3xx microcontroller
low-power modes and features.
Table 1. Applicable products and software
Type
Part numbers
STM32F301x6/8,
STM32F302x6/8/B/C/D/E,
STM32F303x6/8/B/C/D/E,
STM32F334xx, STM32F373xx,
STM32F318xx, STM32F328xx, STM32F358xx, STM32F378xx,
STM32F398xx
STSW-STM32036
Microcontrollers
Software
January 2015
DocID026505 Rev 1
1/25
www.st.com
1
Contents
AN4538
Contents
1
STM32F3xx microcontroller low-power overview . . . . . . . . . . . . . . . . . 5
1.1
Power supply . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
1.1.1
1.1.2
1.1.3
STM32F3xxxx device power supply with an internal regulator . . . . . . . . 5
STM32F3x8xx device power supply . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
Power supply summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
1.2
1.3
1.4
Power mode features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
Wake up from low-power modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
STM32F3xx microcontroller power saving techniques . . . . . . . . . . . . . . . 10
1.4.1
1.4.2
General techniques . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
Low-power features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
2
STM32F3xx microcontroller low-power application example . . . . . . . 12
2.1
Application description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
2.1.1
2.1.2
2.1.3
Functional overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
Application modules . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
State machine . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
Architecture description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
Peripherals configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
Environment setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Application setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
Measuring current consumption . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
2.2
Software description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
2.2.1
2.2.2
2.3
How to use the application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
2.3.1
2.3.2
2.4
Application current consumption . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
2.4.1
3
4
Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
Revision history . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
2/25
DocID026505 Rev 1
AN4538
List of tables
List of tables
Table 1.
Table 2.
Table 3.
Table 4.
Table 5.
Table 6.
Applicable products and software . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
STM32F3xxxx device power supply considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
Wake up from low-power mode sources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
Wake up from low-power mode timing examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
low-power mode data of the measured example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
Document revision history . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
DocID026505 Rev 1
3/25
3
List of figures
AN4538
List of figures
Figure 1.
Figure 2.
Figure 3.
Figure 4.
Figure 5.
Figure 6.
Figure 7.
Figure 8.
Power supply overview in STM32F3xxxx devices with an internal regulator . . . . . . . . . . . . 5
Power supply overview in STM32F3x8xx devices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
Application synoptic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
Application modules and functional interconnections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
Application state machine . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
STM32F3xx microcontroller low-power project overview . . . . . . . . . . . . . . . . . . . . . . . . . . 17
NUCLEO-F302R8 hardware connection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
Log time display of the measured example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
4/25
DocID026505 Rev 1
AN4538
STM32F3xx microcontroller low-power overview
1
STM32F3xx microcontroller low-power overview
STM32F3xx microcontrollers are based on ARM
®
Cortex
®
-M4 core running up to 72 MHz
with a high number of integrated advanced analog peripherals. They integrate an efficient
power supply architecture and various power modes that lead to the power consumption
reduction at the application level and simplify the application design.
1.1
Power supply
STM32F3xxxx devices have an optimized power supply architecture to combine real-time
capabilities, digital signal processing, and low-voltage operations with highly integrated
analog peripherals.
There are two different power supply architectures, depending on the availability of the
internal voltage regulator in the STM32F3xx microcontrollers:
1.1.1
STM32F3xxxx device power supply with an internal regulator
The embedded voltage regulator is used to supply the internal 1.8 V digital power domain
that contains the core, the memories and the digital peripherals as described in
Figure 1.
Figure 1. Power supply overview in STM32F3xxxx devices with an internal regulator
DocID026505 Rev 1
5/25
24