Reading PDM data from MP34DT05-A with STM32F407 I2S
- August 13, 2018
- 14 replies
- 10806 views
Hello, it is the first time when i have to deal with microphones and PDM interface. I just can't get correct data from the microphone, or the data is correct but i am doing something terribly wrong. I configure I2S to sample microphone with DMA. When DMA Rx callback is received, i do the processing of PDM data and send it to PC via USB VCP interface. Problem is that when i get the data in PC, there are some high frequency harmonics which are giving very anoying "beep" sound, even though in the background i can hear the "clap sound" that i am making with my hands. Could someone look at my code and tell me what am i doing wrong?
I attache the main file of my program, also the file where DMA controller of I2S is configured. I also attach pictures of how my signals look in frequency and time domains. Appreciate for the help if anyone could tell my what i am doing wrong.
By the way, i have read ST documents UM2372, AN5027. I do not see from them that i am doing something wrong.
I also add the recorded wav file. Listen it carefully and at low sound because the "beep" is really annoying. You can hear in the background that i am clap two times slowly, then one time i do a double clap quickly.
Will wait for the responses, cheers.