lkml.org 
[lkml]   [2016]   [May]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] ASoC: pcm: allow changing the playback/capture rates for symmetric links
On Mon, May 02, 2016 at 09:43:53AM +0200, Peter Rosin wrote:

> The problem is in the drain/close part. If I leave out snd_pcm_drain
> I naturally lose the tail of the output, but if I have it I get what
> I guess is a repeat of the content in some circular buffer. I.e. the
> very last part of the played sound is played twice(ice).

> If I instead write the generated samples to a file and play them
> with aplay, all is fine, so I appear to be misunderstanding the
> alsa api?

> Anything obviously wrong in the above code?

Look at how aplay handles this... it's a natural consequence of the
hardware being free running. You need to either make the teardown
non-blocking or play some silence at the end.
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2016-05-04 19:01    [W:0.533 / U:0.020 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site