I am trying do the audio loopback on i.mx6 sabresd board.
Audio is in from mic port of board, and out to speaker from headphone port.
I used following command:
arecord -Dhw:0,0 -c 2 -f S16_LE -r 44100 | aplay
It is ok that i can hear the audio output from speaker.
But there is a serious delay, i measured with an oscilloscope,
and it is about 400ms.
Now the problem is:
How can i reduce this delay time? My customer's requirement is 100ms.
And I think that the time is costed by the memory copy.
Can bellow flow be achieved？ without the alsa frame work.
audio--->SSI RX FIFO--->SSI TX FIFO---->
Hi Gao and Lei, I would be interested in this discussion as I am working on improving audio latencies on iMX6.
Is it possible to have this discussion in English, is there a auto-translate option in the forum ?
Hi Sinan Akman,
Did u get SPDIF to ASRC P2P channel working? I am facing an issue in this p2p SDMA transfer. SDMA reads only left channel FIFO of SPDIF. Do you have any idea to make SDMA to read both left and right FIFO of SPDIF?
Hi Abesh, we weren't trying to do this over asrc but rather directly from spdif to ssi. Both fifo's were filling. We had (still have) sync issues but this is different. You should have both fifo's being filled. Do you get any error in status registers ?
Could you please provide some inputs to make SPDIF to SSI(without ASRC) working in our side?
Did you use more than one SDMA channel for transfer data from spdif to ssi?
Did you enable Dual FIFO in SSI?
Hi Abeesg, IIRC we tried this on one channel but we then had our own sdma related issues so I don't remember if we
went further enough for two channels. In your case, you seemed to get the two channels out of sync perhaps as a result
of problem in you signal. Can you simple try this on one channel and if it works try it on another channel, i.e. have left
and right working separately first. If you get everything clean then we can look into why you might be having syncing
the both channels. Please let me know how far you are able to get with one channel only.
Hi Lei, thanks for your reply and writing this again in English for me. This is actually interesting. We were trying to get p2p sdma working between spdif and ssi but we observed that every once a while sdma repeats transferring the same frame. We asked FSL if they know of any customer who successfully implemented p2p with any device other than asrc but haven't heard back. Would you know of any working implementation of p2p that does not use asrc.
Thanks and best regards
what do you mean "SDMA repeats the same frame"? did you mean 2 channels, but only one channel data is transferring?
when using SSI p2p, dual fifo is not needed, you should disable ssi dual fifo mode.
Hi Lei, in our experiment we used only one channel and didn't use the dual fifo. We observed that every once a while after a dma transfer is completed the same data was transferred again as if there was an error and the previous transfer was repeated. Do you know anyone who had used spdif-ssi p2p sdma successfully ?