Skip to main content
October 11, 2021
Question

STM32L4 Minimizing power consumption

  • October 11, 2021
  • 4 replies
  • 1279 views

Hello, I design a device, based on STM32L475RE MCU

and my goal is to minimize the power consumption.

Peripheral I use :

  • 3 sensors(accelerometer, temperature, humidity) and external RTC(M41T64Q6F) on I2C bus
  • External flash on SPI
  • USB
  • ADC to read battery level

  1. Would it be better for power consumption to change HSE for MSI, and is it reliable for peripheral I use to work with MSI?
  2. USB is needed really rarely, so is it possible to initialize USB when connected and does it make sense?
  3. How to know that USB is connected?

This topic has been closed for replies.

4 replies

TDK
October 11, 2021

> 1. Would it be better for power consumption to change HSE for MSI, and is it reliable for peripheral I use to work with MSI?

The datasheet includes detailed breakdown of current consumption by MSI and HSE. In general, MSI uses less power.

0693W00000FC5oeQAD.png 

0693W00000FC5ooQAD.png 

The L475 supports crystal-less USB, but requires an LSE to do so. No other peripheral that you're using needs precise timing.

> 2. USB is needed really rarely, so is it possible to initialize USB when connected and does it make sense?

Makes sense to me.

> 3. How to know that USB is connected?

Connect VBUS to a pin (preferably with resistor divider), and monitor it.

"If you feel a post has answered your question, please click ""Accept as Solution""."
October 12, 2021

Thank you,

I've created cube mx project to try clock settings and as I understand USB could work even without LSE

TDK
October 12, 2021
It may work, and likely will at ambient temperature, but it’s very much not guaranteed and likely won’t work over the full temperature range.
"If you feel a post has answered your question, please click ""Accept as Solution""."
S.Ma
Principal
October 12, 2021

Depending on your mission profile, you might also try to aim for the lowest working sysclk frequency, which will make you zoom in interrupt latencies and jitter. Most people prefer to bail out by crancking up sysclk instead.