Skip to contentSkip to conversation

input: Add KEY_MIC_MUTE

RFC PATCH In review Jerone Young 2 participants 3 messages May 20, 2010

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

RFC PATCH 1/1 input: Add KEY_MIC_MUTE

Today Lenovo Thinkpads are coming with a new key for muting the microphone. They started this with the T400s & it is now on T410(s)/510, W510/W710, L412/512, X100e, Edge 13/14/15 Thinkpads. Currently 12 models, with more coming in the foreseeable future.

I want to define a keycode for microphone mute to be able take advantage of this key in userspace.

The only issue is I'm not sure the best code to use, or if these are defined from somewhere else? Here is what I propose .. though feedback would be greatly appreciated.

include/linux/input.h +2 -0
index 746d426..ca5373a 100644
@@ -377,6 +377,8 @@ struct input_absinfo {
 
 #define KEY_WIMAX              246
 
+#define KEY_MICROPHONE_MUTE           247     /* mute microphone */
+
 /* Range 248 - 255 is reserved for special needs of AT keyboard driver

*/

#define BTN_MISC 0x100

#1 lore raw
Quoted 4 lines · Jerone Young

Today Lenovo Thinkpads are coming with a new key for muting the microphone. They started this with the T400s & it is now on T410(s)/510, W510/W710, L412/512, X100e, Edge 13/14/15 Thinkpads. Currently 12 models, with more coming in the foreseeable future.

There's a "Microphone" usage name listed in the HID Usage Tables (under Consumer Page) which would probably do fine.

Do this button toggle the mute status?

Cheers

#2 lore raw
Quoted 8 lines · Bastien Nocera
Quoted 4 lines · Jerone Young

Today Lenovo Thinkpads are coming with a new key for muting the microphone. They started this with the T400s & it is now on T410(s)/510, W510/W710, L412/512, X100e, Edge 13/14/15 Thinkpads. Currently 12 models, with more coming in the foreseeable future.

There's a "Microphone" usage name listed in the HID Usage Tables (under Consumer Page) which would probably do fine.

Thanks for the pointer. HID Usage Table seems like it would be in line to what I'm trying to do. Though still doesn't define a set keycode anywhere (this would actually be great to line this up to a standard).

Quoted 2 lines

Do this button toggle the mute status?

Yes it's a toggle for microphone (though done all in software) .. so no hardware controls going on here. Right now on these Thinkpads sends an acpi event, we can remap that to a standard key code once it is defined (done in module thinkpad-acpi).

I also failed to mention before that there is also Thinkpad USB keyboard as well with the key:
http://www.thinkpads.com/wp-content/gallery/thinkpad-usb-keyboard/lenovo_thinkpad_usb_ultranav_keyboard-top.jpg
It sends a keycode..though that can be remmapped in udev to whatever ends up getting defined.

Thanks,
Jerone

Quoted 3 lines

Cheers