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.

omapl-138 audio swapping channels with aiff, wav and flac only

Using a kernel that has the following patches applied:

http://www.mail-archive.com/davinci-linux-open-source@linux.davincidsp.com/msg15857.html

and

http://www.mail-archive.com/davinci-linux-open-source@linux.davincidsp.com/msg18471.html

I am finding that the left and right channels become swapped when I pause and then play and then at random times during playback. Our system is using kernel version 2.6.33-rc4, with gstreamer as the player and a WM8776 codec being used is slave mode. All audio clocks are provided externally to the omapl and codec.

I also applied the following patch:

http://www.mail-archive.com/davinci-linux-open-source@linux.davincidsp.com/msg21521.html

to move the sram allocator to shared ram, this seemed to improve things in that not every time that I pause or play a track will the audio swap channels.

With each audio format it gets worse using the following bit rates and sample frequencies:

aiff                     16bit/44.1kH

flac                    24bit/88.2kHz                   24bit/86kHz

wav                   24bit/88.2kHz                   24bit/86kHz

All of the audio is being decoded only, there is no video in our system. It is built using openembedded.

Where can I look next to make improvements?

 

 

  • I have an update on the issue. By increasing the sram buffer size I can get audio playback to be perfect, but almost every time that I pause and then play I get the channels swapped.

    Looking at the formats above aiff looks like it is the odd one out, but in fact gstreamer takes this 16bit data and converts it to 32bit. So this would mean that all data here is 32bits, which would mean that left and right samples are being moved out of memory in separate 32bit samples, so when pause is used on the restart there is no check for the samples being left or right data.

    For 16bit data the samples are moved as left and right within the same 32bits, so they are never swapped after pausing.

    Has anyone seen this issue? Are there any solutions?