cancel
Showing results for 
Search instead for 
Did you mean: 

How to use pdm to pcm conversion library?

SHire
Associate

I am working on a project where I need to calculate the ambient noise in a given environment in decibels, for that purpose I am using st microelectronics's MP34DT01-M microphone which has an digital PDM output. From the stm application notes I got to know that I need to use pdm audio decoding library ,but I don't know from where to download this library , how to use it and how to initialise the stm32cube mx. I'm using nucleo- L476RG. please help.

2 REPLIES 2
SWood.8
Associate III

Hi. How did you go with this query ? I am just starting a project now and will be using this microphone on a NUCLEO-H7. Also have an L4 like yourself.

Eleon BORLINI
ST Employee

hi, for L4 I suggest you to start form the linked example. After downloading the FP-SNS-ALLMEMS2 pack, go to --> en.fp-sns-allmems2\STM32CubeFunctionPack_ALLMEMS2_V1.0.0\Projects\Multi\Applications\ALLMEMS2\EWARM\STM32L476RG-Nucleo and open the project ALLMEMS2_NL476.eww

The initialization and acquisition of audio peripheral is in x_nucleo_cca02m1_audio_l4.c (higher level layer), that calls the HAL of the digital filter for the sigma-delta modulator of the PDM, which is the stm32l4xx_hal_dfsdm.c. CCA02M1 is the x-nucleo expansion board for MEMS microphone.

Link: https://my.st.com/content/my_st_com/en/products/embedded-software/mcus-embedded-software/stm32-embedded-software/stm32-ode-function-pack-sw/fp-sns-allmems2.license=1549354628918.product=FP-SNS-ALLMEMS2.version=1.0.0.html