[PATCH 3/3] sandbox: fix sound driver
Simon Glass
sjg at chromium.org
Mon Dec 5 17:11:44 CET 2022
On Mon, 5 Dec 2022 at 09:53, Heinrich Schuchardt
<heinrich.schuchardt at canonical.com> wrote:
>
> In the callback function we have to use memcpy(). Otherwise we add
> the new samples on top of what is stored in the stream buffer.
>
> If we don't have enough data, zero out the rest of the stream buffer.
>
> Our sampling frequency is 48000. Let the batch size for the callback
> function be 960. If we play a multiple of 20 ms, this will always be
> a full batch.
>
> Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt at canonical.com>
> ---
> arch/sandbox/cpu/sdl.c | 11 +++++------
> 1 file changed, 5 insertions(+), 6 deletions(-)
>
Reviewed-by: Simon Glass <sjg at chromium.org>
More information about the U-Boot
mailing list