cancel
Showing results for 
Search instead for 
Did you mean: 

Which is the correct way to interface a digital microphone to a codec?

nmagniez
Associate II
Posted on February 07, 2014 at 10:09

Which is the correct way to interface a digital microphone to a codec?

1 REPLY 1
Alessandro MORCELLI
Associate II
Posted on February 07, 2014 at 11:33

Commonly, the digital microphones operate in an environment where a codec provides the suitable clock and consequently accepts the digital data of the microphone. Additionally, the microphone can be used in single mode or in a stereo configuration. When used in stereo configuration the data output of the couple of microphone can be shorted. Concerning the stereo configuration, the LR pins of the involved digital microphones must be respectively set to Vdd and gnd. This setting will produce an output composed by the succession of valid data and Hi-Z. Once the mode is chosen, the goal of the codec is to sample the data coming from the sensor. The sampling rate of the codec must be set according to the used mode. For a stereo configuration, in case of the codec is able to sample only on rising or falling edge of the click, the sampling rate of the codec must be doubled with respect to microphone clock. Finally the codec must include a decimation algorithm in order to decode the PDM signal coming from the microphone.

Details about the ST PDM library can be found on the AN3998, available on ST web:

http://www.st.com/internet/com/TECHNICAL_RESOURCES/TECHNICAL_LITERATURE/APPLICATION_NOTE/DM00040808.pdf

The library is released to the open market thus enabling development of STM32-based audio application exploiting ST digital MEMS Microphones, it is available at the following link:

http://www.st.com/stonline/stappl/resourceSelector/app?page=resourceSelector&doctype=FIRMWARE&SubClassID=1521

Alessandro