[wdmaudiodev] Crackles when playing audio

  • From: Matthieu Collette <matthieu.collette@xxxxxxx>
  • To: wdmaudiodev@xxxxxxxxxxxxx
  • Date: Wed, 11 May 2016 16:13:40 +0200

Hi,

I am developing a virtual audio driver based on the MSVAD project which I
have modified to send audio data from kernel to user space using a
connection oriented socket. The audio data is then sent over a network to a
remote playback device.

This works almost as expected but I am noticing some crackles when playing
audio on the remote playback device.

I have implemented a wav file recorder in order to know where the problem
is located in my kernel driver, user space application or on the remote
playback device. This recorder actually runs in user space and records
everything sent from my kernel driver.

Here is what I do:
I am playing audio from an online source
I send the audio data format from kernel to user space using a connection
oriented socket
I send the audio data as provided from IDMAChannel::CopyTo using the
previous socket
In user space, I append in a buffer all audio data packets as received from
the socket
I periodically save to file a wav file based and the audio format and data

I can ear crackles when I play the recorded wav file, meaning the problem
is located in my kernel driver.

Could those crackles come from an alignment issue ?
Could it be due to a bad estimation of the DMA position ?

Any kind of help is welcome ;)

Thanks in advance !

Best regards.

Matt

Other related posts: