Skip to contentSkip to conversation

P1022 audio driver help!

DISCUSSION eshe168 2 participants 4 messages May 30, 2014 – Jun 2, 2014

lore
Share & tools
lore

eshe168

author
#0 lore raw

@timur

hi,

Audio card (wm8776) cannot work in full duplex, CPU is FSL P1022.
The PCB design about audio card reference FSL P1022 development board, and palying or recording is OK separately.

My question is whether P1022 audio driver cannot support full duplex?

The following is my test method.
test script:
#!/bin/sh
echo "start plarying"
aplay /nor-disk/audiosrv/Success.wav &
sleep 1
echo "start recording"
arecord -d 5 -t wav -D "plug:SLAVE='hw:0,1'" -r 19886 test.wav

when start "record", "aplay" just suspend, and I cannot listen voice. when record is over, I found aplay still suspend. according to "ps -aux":
root 1499 0.2 0.1 4012 1500 pts/0 S 08:25 0:00 aplay /nor-disk/audiosrv/Success.wav

But, I run this script in a PC linux, I can listen the voice, the audio card can record my voice simultaneous.

Looking forward your response!

Thanks!

B.R.
YXS

#1 lore raw
Quoted 6 lines · On 05/30/2014 01:03 AM, eshe168 wrote:

@timur
hi,
Audio card (wm8776) cannot work in full duplex, CPU is FSL P1022. The PCB design about audio card reference FSL P1022 development board, and palying or recording is OK separately.
My question is whether P1022 audio driver cannot support full duplex?

I was never able to get the P1022ds audio to work in full duplex. After trying for a few weeks, I just gave up.

If you look inside fsl_ssi.c (the main driver) you'll see this comment I wrote:

/*
* FIXME: The documentation says that SxCCR[WL] should not be
* modified while the SSI is enabled. The only time this can
* happen is if we're trying to do simultaneous playback and
* capture in asynchronous mode. Unfortunately, I have been enable
* to get that to work at all on the P1022DS. Therefore, we don't
* bother to disable/enable the SSI when setting SxCCR[WL], because
* the SSI will stop anyway. Maybe one day, this will get fixed. */

(it should say "I have been unable" instead of "I have been enable")

Full duplex works fine on the MPC8610, which has the same audio controller as the P1022, so I know the controller is physically capable of it. I just don't know why it doesn't work on the P1022DS. I also don't know if it's a problem with the P1022DS board or with the P1022 SOC itself.

#2 lore raw

Hi Timur
thanks for your repons.
I have another question. Did you test full duplex in P1022 RDK board?Our design is same with P1022 RDK. B.R.杨小帅

Quoted 6 lines · From: Timur TabiDate: 2014-05-30 23:48To: eshe168CC: linuxppc-dev…

@timur
hi,
Audio card (wm8776) cannot work in full duplex, CPU is FSL P1022. The PCB design about audio card reference FSL P1022 development board, and palying or recording is OK separately.
My question is whether P1022 audio driver cannot support full duplex?


I was never able to get the P1022ds audio to work in full duplex.  After trying for a few weeks, I just gave up.

If you look inside fsl_ssi.c (the main driver) you'll see this comment I wrote:

/*
  * FIXME: The documentation says that SxCCR[WL] should not be
  * modified while the SSI is enabled.  The only time this can
  * happen is if we're trying to do simultaneous playback and
  * capture in asynchronous mode.  Unfortunately, I have been enable
  * to get that to work at all on the P1022DS.  Therefore, we don't
  * bother to disable/enable the SSI when setting SxCCR[WL], because
  * the SSI will stop anyway.  Maybe one day, this will get fixed. */

(it should say "I have been unable" instead of "I have been enable")
Full duplex works fine on the MPC8610, which has the same audio controller as the P1022, so I know the controller is physically capable of it.  I just don't know why it doesn't work on the P1022DS.  I also don't know if it's a problem with the P1022DS board or with the P1022 SOC itself.

#3 lore raw
Quoted 3 lines · [email protected] wrote:

I have another question. Did you test full duplex in P1022 RDK board? Our design is same with P1022 RDK.

No, I don't think I did. The P1022RDK was not a board that my team was responsible for, so I only did minimal work on it. I added support for it in the upstream kernel. It was so long ago that I don't really remember much about it. I still have the board, though.