This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

SK-TDA4VM: Audio capture uderrun after running 4 hours with PROCESSOR-SDK-LINUX-J721E 08.00.00.08 (12 Aug 2021)

Part Number: SK-TDA4VM

Hi ALSA expert,

I have modified the SK-TDA4 boards to support audio capture.

I am using alsa lib to write a capture app, after running for 4 hours without any problem, suddenly I got an underrun error when calling snd_pcm_readi().

I don't think my reading rate and audio rate is different because I checked snd_pcm_avail_delay() every time after reading and the avail does not increase over time, it is just moving around a constant value.

I also check time between 2 reads and it does not has a long delay when the issue occured. 

Moreover, I have seen the avail has big jump in rare case even I am keeping the same reading rate.

Could you please let me know if the ALSA audio capture has been tested 24 hours without any issues?

Do you have any suggestion for me to find the root cause?

Thank you and best regards,

Nam