Aplay noise every time

Hi, I have a question: we used rt5640 codec, and it works, but when we aplay a wav file, it will had a “po” noise every time at the begining, then it is ok, the noise just appears at the beginning of aplay.
We debug rt5640 driver, found in rt5640_probe:
IS_ERR(rt5640->mclk) is true, we don’t know why mclk is err but the codec can still work?

Hi rd1,

The MCLK clock is not mandatory for RT5640 codec. It can derive its system clock based on I2S bit clock, I think this is what is happening in your case. You can confirm this by adding prints inside the codec driver on its system clock configuration. Or you can share your codec board datasheet and DT/driver configuration for further analysis.

If you are interested to use MCLK, you need to add the relevant clock node to your codec device node in DT. And you can check if pop is still observed.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.