You are not logged in.

#1 2012-02-16 02:08:55

/dev/zero
Member
From: Melbourne, Australia
Registered: 2011-10-20
Posts: 1,247

How to detect headphone controller events?

Hello Archers,

I just purchased a pair of noise-cancelling headphones. They come with an external controller integrated into the cord. The controller has a "talk mode" button for pausing and unpausing music.

The box did not specify any OS requirements and did not come with any software; however, the talk-mode button does not seem to work. No events show up when I press talk-mode while running either of,

xev

and

udevadm monitor

and in addition to the lack of detected events, it certainly does not pause mplayer.

I got my stfw on and found this same problem on unix.stackexchange.com. That topic only looks fairly new, and I don't see any real answers yet.

So, I'm asking, in order of most preferred information to the least:

  1. Does anyone know any way to use such devices with any media players in Linux?

  2. Does anyone know any userspace method to detect signals coming from such devices? If I could detect the events, I could probably whip up a script to control mplayer through a fifo.

  3. If all else fails, does it seem like it would be doable to hack something up in kernel space, eg write a module?


Edit: oops, forgot to give some system info.

lspci -nnmvk | grep -B1 -A5 -i audio

Device:	00:1b.0
Class:	Audio device [0403]
Vendor:	Intel Corporation [8086]
Device:	6 Series/C200 Series Chipset Family High Definition Audio Controller [1c20]
SVendor:	Acer Incorporated [ALI] [1025]
SDevice:	Device [0504]
Rev:	04
Driver:	snd_hda_intel

lsmod

Module                  Size  Used by
ipv6                  247318  32 
ipt_REJECT              1989  3 
xt_tcpudp               1875  4 
nf_conntrack_ipv4       9593  5 
nf_defrag_ipv4          1015  1 nf_conntrack_ipv4
xt_conntrack            2645  5 
nf_conntrack           50451  2 xt_conntrack,nf_conntrack_ipv4
iptable_filter          1092  1 
ip_tables               9026  1 iptable_filter
x_tables               11766  5 ip_tables,iptable_filter,xt_conntrack,xt_tcpudp,ipt_REJECT
uvcvideo               57039  0 
acpi_cpufreq            5113  1 
sdhci_pci               8912  0 
mperf                    995  1 acpi_cpufreq
sdhci                  20030  1 sdhci_pci
mmc_core               71470  2 sdhci,sdhci_pci
wl                   2428067  0 
evdev                   7278  15 
xts                     1929  4 
gf128mul                5950  1 xts

(There's not much here because I've got an ABS kernel with a bunch of stuff compiled in.)

aplay -l

**** List of PLAYBACK Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: ALC269VB Analog [ALC269VB Analog]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

Last edited by /dev/zero (2012-02-16 02:21:33)

Offline

Board footer

Powered by FluxBB