From: Hans-Christian Egtvedt <hcegtvedt@atmel.com>
To: alsa-devel@lists.sourceforge.net
Subject: How is buffer size, periode size and periods determined?
Date: Fri, 12 May 2006 15:55:38 +0200 [thread overview]
Message-ID: <446493DA.407@atmel.com> (raw)
Hi
I'm experiencing that my aplay/arecord (1.0.11) is setting up a bit
weird values for buffer size, period size and periods.
For example when trying to record S16_LE 44100 Hz Mono I get the
following parameters:
buffer size: 44100
period size: 4094
periods : 10
10 * 4094 = 40940 != 44100, the player asks for a bigger buffer than needed.
Other example, S16_LE 32000 Hz Mono:
buffer size: 32752
period size: 4094
periods : 8
8 * 4094 = 32752 == 32752, which is a correct buffer size.
How come the alsa-lib/aplay behaves like this? I would like to see the
last behaviour all the time. Does this point to a bug on my platform, or
is this the way alsa-lib can calculate the buffers?
The reason I'm asking is that it wastes some memory and the DMA
controller currently in the Linux for my platform doesn't like the
buffersize to be greater than periode size * periods.
--
With kind regards,
Med vennlig hilsen,
Hans-Christian Egtvedt
Applications Engineer - AVR Applications Lab
Atmel Norway
-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
next reply other threads:[~2006-05-12 13:55 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-05-12 13:55 Hans-Christian Egtvedt [this message]
2006-05-17 7:47 ` How is buffer size, periode size and periods de Giuliano Pochini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=446493DA.407@atmel.com \
--to=hcegtvedt@atmel.com \
--cc=alsa-devel@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.