Re: beagleboardxm 2.6.39rc4 mcbsp problems.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Friday 20 May 2011 02:58:30 Steve Calfee wrote:
> On 05/19/11 04:28, Peter Ujfalusi wrote:
> Correct, I can set bit clock to 64*lrclk, 48*lrclk, 128*lrclk, 17*lrclk,
> and 18*lrclk.

Strange, that there is no option for 32*lrclk.

> The audio folks here think that it is normal to send more
> than required bit clocks, data is sent first so just ignore the rest.

Yes, it is allowed. The rest should be ignored.
But I'm afraid, OMAP McBSP can not handle this in a way you (and me) wanted 
to.

> It would appear that the mcbsp doesn't really use the lrclk (I think
> called FSX), it just uses a positive transition to start the bit
> shifting for all the requested bits. The falling edge does not start the
> right channel, the shifter keeps going until all requested l/r counts
> have been sent.

Yeah, McBSP only cares about the start condition, it does not care about the 
right channel FSX transition.
This is the reason it is not possible to handle the scenario you are aiming 
for.
At start condition, it just start to send the data stream (frame1 followed by 
frame2 in dual-phase mode - in single phase mode it can send up to 128 
frames).
Having said that, there might be a way to actually work this around with 
McBSP's multichannel mode. Configuring it for 4 slots, and only shift data for 
slot 0, and 2 in case of your setup (16bit data within 32 bitclocks).
It is a long shot, I can not promise that I can take a look right away, but if 
you have time.... ;)

> > You should have full stereo sound now.
> 
> I do, thanks.

Cool :D

> I am truly amazed that I was able to follow your
> instructions and get it to work first time. You must really know your
> alsa machine implementation.

Thanks, I try.

> The problem is that now I cannot run 44.1Khz audio, I get underruns. I
> am guessing that software is expanding the samples from 16 bits to 32?
> Without your hack 44.1Khz audio works fine (but only audible in the
> first channel).

Hmm. I have used similar mode with twl4030, and tlv320dac33 (S32_LE with 
24msbits) without issues with underrun. Let's see.
Can you check /sys/devices/platform/omap-mcbsp.X/dma_op_mode, max_tx_thres for 
your McBSP port?
I would suggest to switch the dma_op_mode to threshold mode in any port.

When you play audio try to use bigger periods, something like 10ms:
aplay -Dplughw:0,0 --period-time=10000 -v <your sample>

Replace the -Dplughw:0,0 to point to the wm98095 PCM.

Could you post the output of aplay?

> I talk to Peter every day. He brought up the codec, I am trying to use
> the Beagleboardxm as a generic Linux platform for new codec bringups and
> for following kernel and alsa cutting edge software.

Make sense..

-- 
PÃter
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux