Audio device capture settings at start in Kernel
Arjun Sarwal
arjun at laptop.org
Tue Feb 19 19:04:04 EST 2008
Currently, when the audio capture device is opened, the kernel applies
these settings
1. The DC mode enable setting is disabled
2. The bias voltage is enabled
Both are settings that allow the built in mic to get enabled properly.
The rationale of applying these settings is that if Activities quit
prematurely without properly closing the capture device,another
Activity that uses this device, mustn't need to do anything special to
get a default recording stream from the mic.
The flip-side of applying these settings is that using an alsa
interface, say such as pyalsaaudio to acquire a specified certain
number of samples makes it impossible to get these samples at anything
but the default settings. This is because when the specified call to
get samples opens the capture device, the kernel overrides with the
default settings (outlined in point 1 and 2 in the beginning of this
email)
My suggestion -- apply default settings only at close of capture
device and not while opening it
Given the current settings, I am out of ideas of how to write code
that allows one to, at-will request for _a_ sample from the ADC at a
specified set of capture settings and get it. Any suggestions ?
--
Arjun Sarwal
More information about the Devel
mailing list