* support for jackSense feature in modern sound cards
@ 2008-02-10 19:33 Balaji Rao
2008-02-10 19:59 ` Tobin Davis
2008-02-10 21:55 ` Mark Brown
0 siblings, 2 replies; 3+ messages in thread
From: Balaji Rao @ 2008-02-10 19:33 UTC (permalink / raw)
To: alsa-devel
Hello people,
How well is the jack sense feature in modern soundcards supported in the
kernel ? I opened up a few driver sources like hda-intel and found the
word 'jack sense' in some files, but i could not find it being used anywhere.
Are there standard interfaces in kmix or equivalent software that use the jack
sense feature ? If not, wouldn't it be nice to have a standard interface to
expose this feature so that kmix and others could make use of in a device
independent way ?
If yes, I would be more than willing to contribute to its development.
Please clarify.
--
regards,
balaji rao
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: support for jackSense feature in modern sound cards
2008-02-10 19:33 support for jackSense feature in modern sound cards Balaji Rao
@ 2008-02-10 19:59 ` Tobin Davis
2008-02-10 21:55 ` Mark Brown
1 sibling, 0 replies; 3+ messages in thread
From: Tobin Davis @ 2008-02-10 19:59 UTC (permalink / raw)
To: Balaji Rao; +Cc: alsa-devel
Actually, most of the hda_intel sound codecs support jack sense to a
certain extent. They are mainly used to mute/unmute speaker and
microphone channels when headphones or external microphones are plugged
in. Some of the codecs support additional sensing to determine the type
of device plugged in, but that is very limited in the drivers, mainly
because of the diverse nature of the systems that these codecs are used
in.
Tobin
On Mon, 2008-02-11 at 01:03 +0530, Balaji Rao wrote:
> Hello people,
>
> How well is the jack sense feature in modern soundcards supported in the
> kernel ? I opened up a few driver sources like hda-intel and found the
> word 'jack sense' in some files, but i could not find it being used anywhere.
>
> Are there standard interfaces in kmix or equivalent software that use the jack
> sense feature ? If not, wouldn't it be nice to have a standard interface to
> expose this feature so that kmix and others could make use of in a device
> independent way ?
>
> If yes, I would be more than willing to contribute to its development.
>
> Please clarify.
>
--
Tobin Davis
I hate users
you sound like a sysadmin already!
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: support for jackSense feature in modern sound cards
2008-02-10 19:33 support for jackSense feature in modern sound cards Balaji Rao
2008-02-10 19:59 ` Tobin Davis
@ 2008-02-10 21:55 ` Mark Brown
1 sibling, 0 replies; 3+ messages in thread
From: Mark Brown @ 2008-02-10 21:55 UTC (permalink / raw)
To: Balaji Rao; +Cc: liam.girdwood, alsa-devel
On Mon, Feb 11, 2008 at 01:03:37AM +0530, Balaji Rao wrote:
> How well is the jack sense feature in modern soundcards supported in the
> kernel ? I opened up a few driver sources like hda-intel and found the
> word 'jack sense' in some files, but i could not find it being used anywhere.
FWIW this feature is frequently called "jack detect" or "headphone
detect". I have actually been looking at this, mostly within the
context of ASoC although obviously this all applies to ALSA core too.
There is some in-kernel support for it at present, though some of those
don't expose anything to user space and do fixed things to the hardware
when there is a headphone detect event.
There is also an existing user space API for communicating events to
user space via the input subsystem - this is in use by some of the
Zaurus systems. Jacks are represented as switch events of type
SW_HEADPHONE_INSERT. User space can listen for these events and can
then adjust the system configuration as appropriate.
My plan for supporting this in ALSA had been to add helpers to assist in
the creation of input devices representing the jacks along with new
switch types to allow systems that can detect the type of device plugged
into a jack to represent this to user space (eg, SW_SPEAKER_INSERT).
The helpers would parent the input device off the sound card device and
provide a name for the jack to user space. My intention is to post some
code once I've got sound working on the Zylonite (since that has jack
detect support and would allow me to show working code).
> Are there standard interfaces in kmix or equivalent software that use the jack
> sense feature ? If not, wouldn't it be nice to have a standard interface to
> expose this feature so that kmix and others could make use of in a device
> independent way ?
The existing user space API does seem reasonable to me - logically, a
headphone jack does correspond to a switch and applications that respond
to jack insert events are likely to also want to pay attention to other
input events such as the mute and volume control keys often found on
keyboards.
For embedded uses the expectation was that this would be used in
conjunction with the ALSA scenario management API which my colleague
Liam Girdwood is currently developing:
http://opensource.wolfsonmicro.com/node/14
This may or may not be appropriate for desktop systems, I am less
familiar with the issues there.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2008-02-10 21:55 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-02-10 19:33 support for jackSense feature in modern sound cards Balaji Rao
2008-02-10 19:59 ` Tobin Davis
2008-02-10 21:55 ` Mark Brown
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox