PDM microphone glitch at beginning of the recording
Hello,
I'm using the IMP34DT05 microphone using the I2S interface. I'm sampling at 22kHz but I have a problem when I look at the recording saved on micro SD. In the first part of the audio, I see a glitch and then an exponential decay of that spike (see attached image).
The strange thing is that not all the recordings have such a glitch at 0.046 s, which is exactly after the first 512 Bytes (see second screenshot).
The PDM data are converted to PCM using the PDMFilter function. Any suggestion on how to get rid of this? and the reason why is happening?

