2018-08-28 01:19 AM
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.
2019-02-04 07:03 PM
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.
2019-02-05 01:29 AM
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.