How to enable the Thinkpad microphone mute key on Ubuntu 16.04
While the hardware mute button of my Lenovo x230 worked on Ubuntu 14.04 out of the box, it does not on Ubuntu 16.04. It is fairly simple to fix, though.
There is an extensive answer on Ask Ubuntu Archive , but only part of it was required for me. Here is the gist of it.
-
Open a terminal
-
Run
acpi_listen
and press the mute key. You should see something like this:Copybutton/f20 F20 00000080 00000000 K
Press
Ctrl
+C
to exit. -
Run
amixer scontrols
. You will see multiple lines, one of which should be:CopySimple mixer control 'Capture',0
If there is no
'Capture'
, you might see'Internal Mic'
or similar. -
Now bind the key to toggle that device. Create an ACPI event file for that:
Copysudo vim /etc/acpi/events/lenovo-mutemic
Add the following. Fill in
event
with theacpi_listen
result for your hardware mute key. If there was noCapture
control for you, change accordingly (keep the quotes).Copyevent=button/f20 F20 00000080 00000000 K action=/usr/bin/amixer sset 'Capture',0 toggle
-
Restart the ACPI service.
Copysudo service acpid restart
-
That should be all. Do some testing to see if it actually works.
On my x230, the hardware key has an integrated notification LED. If your Thinkpad does not have that, you could use your power LED and/or an extra notification bubble.
Please see the answer on askubuntu.com on how to add such features, or if you run into trouble.
Your development team has a full backlog of feature requests, chores and refactoring coupled with deadlines? We are familiar with that. With our "DevOps as a Service" offering, we support developer teams with infrastructure and operations expertise.