Skip to main content
Vvenk.1
Visitor II
September 28, 2020
Question

Low power modes on STM32L4 series MCU

  • September 28, 2020
  • 2 replies
  • 1139 views

Hi,

Below is my requirement:

  1. Need to send a DAC sample every 2ms (on 32KHZ clock)
  2. Every 12 sec will do an access to external flash to copy a block of memory (on HSI clock)

how can i accomplish this? am new to microcontroller, can anyone help me with some link/ tutorial on this.

Regards,

Venkatesh

This topic has been closed for replies.

2 replies

KnarfB
Super User
September 28, 2020

A tiny example using a timer driven DMA triggering DAC is this: https://m0agx.eu/2019/03/30/generating-signals-with-stm32l4-timer-dma-and-dac/

This works also in sleep mode where the MCU core is halted except for interrupt handling.

The block copy from flash could be done in the circular DMA (half-)completion handlers.

Technical Moderator
September 28, 2020

Hello @Vvenk.1​ ,

You can get inspired from the DAC example for your board within STM32CubeL4 package and refer to the STM32L4-DAC training and

AN3126 Application note Audio and waveform generation using the DAC in STM32 products

Hope this helps you.

Imen

In order to give better visibility on the answered topics, please click on 'Best answer' on the reply which solved your issue or answered your question. Thanks