Bug 11759 - Microsoft 6000 v2.0 keyboard extra keys
Summary: Microsoft 6000 v2.0 keyboard extra keys
Status: RESOLVED OBSOLETE
Alias: None
Product: Drivers
Classification: Unclassified
Component: Input Devices (show other bugs)
Hardware: All Linux
: P1 low
Assignee: Jiri Kosina
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-10-14 12:13 UTC by Andrew Kirilenko
Modified: 2013-12-10 16:12 UTC (History)
4 users (show)

See Also:
Kernel Version: 2.6.33
Subsystem:
Regression: No
Bisected commit-id:


Attachments
kernel config (8.72 KB, application/x-gzip)
2008-10-14 12:14 UTC, Andrew Kirilenko
Details
hid events (24.31 KB, application/octet-stream)
2008-10-20 04:32 UTC, Andrew Kirilenko
Details
lsusb (3.04 KB, application/octet-stream)
2008-10-20 06:35 UTC, Andrew Kirilenko
Details
Patch that resolves hotkey issue for certain Microsoft Wireless keyboards. (1.46 KB, patch)
2008-12-11 11:57 UTC, Adam Dorsey
Details | Diff
[PATCH] HID: adjust report descriptor fixup for MS 1028 receiver (1.79 KB, patch)
2009-01-19 02:29 UTC, Jiri Kosina
Details | Diff
HID: support for microsoft wireless otpical desktop 2.0 (2.12 KB, patch)
2009-03-31 14:44 UTC, Jiri Kosina
Details | Diff

Description Andrew Kirilenko 2008-10-14 12:13:56 UTC
Hello!

Trying to bring it on using evdev. When I'm trying to do:

cat /dev/input/by-path/pci-0000:00:1d.2-usb-0:2:1.0-event-kbd 

only normal keys and 5 of 22 extra keys produces output here. It'd be nice to have all other keys working.

I'll attach my kernel config now and provide any other info at request (including applying & testing patches if any).
Comment 1 Andrew Kirilenko 2008-10-14 12:14:30 UTC
Created attachment 18308 [details]
kernel config
Comment 2 Jiri Kosina 2008-10-17 03:01:44 UTC
Could you please compile your kernel with CONFIG_HID_DEBUG, modprobe the 'hid' module with 'debug=2' option, and send me the annotated output that appears in dmesg when you press the non-working buttons? We'd need to add special handling for this keyboard into hid-microsoft driver I guess.

I'll also need VID/PID of that device (lsusb output should be enough).
Comment 3 Andrew Kirilenko 2008-10-17 04:45:43 UTC
Will do (most likely tomorrow evening). 

Hmmm... What about hid-microsoft? I don't have such module at all (and it's not present in the kernel tree):

iced@iced linux % pwd
/usr/src/linux
iced@iced linux % find | grep microsoft
iced@iced linux % 
Comment 4 Jiri Kosina 2008-10-17 05:38:25 UTC
(In reply to comment #3)
> Will do (most likely tomorrow evening). 

Thanks.

> Hmmm... What about hid-microsoft? I don't have such module at all (and it's
> not
> present in the kernel tree):
> 
> iced@iced linux % pwd
> /usr/src/linux
> iced@iced linux % find | grep microsoft
> iced@iced linux % 
> 

I have merged this to Linus' tree a few days ago. HID quirks have been moved into separate drivers, as the previous state (quirks randomly placed all over the usbhid code) was just unmaintainable.
It will be present in 2.6.28
Comment 5 Andrew Kirilenko 2008-10-20 04:31:22 UTC
OK. I have enabled HID_DEBUG, modprobed hid as you requested, sshed from laptop to prevent unnecessary events, set big dmesg buffer, stored dmesg output into file, returned to the keyboard, pressed non working keys: zoom up, zoom down, gear, headphones, phone & earth, camera, mail, document (?), home, navigation back, navigation forward, play/pause, prev track, next track, mute, vol down, vol up, stored dmesg output again and created diff.
Comment 6 Andrew Kirilenko 2008-10-20 04:32:13 UTC
Created attachment 18374 [details]
hid events
Comment 7 Andrew Kirilenko 2008-10-20 06:35:30 UTC
Created attachment 18377 [details]
lsusb
Comment 8 Jiri Kosina 2008-10-21 01:42:00 UTC
(In reply to comment #6)
> Created an attachment (id=18374) [details]
> hid events

Andrew,

thanks a lot for providing the output. Unfortunately it is a little bit too confusing. Could you please annotate it in the following way:

'this appears when key FOO is pressed and released:'
....
'this apppears when key BAR is pressed and released:'
....

etc. From the dump you provided, the boundaries between individual events are not absolutely clear.
Thanks.
Comment 9 Andrew Kirilenko 2008-10-21 02:04:49 UTC
I'm at work now, will do at evening :)
Comment 10 Dice Wasser 2008-11-01 13:20:53 UTC
I am also using a microsoft natural keyboard,
I am a linux noob but know the keycodes and stuff all of these are in my kernal log for when I press different things all errors come in the form "translated set 2, code * on iso0060/serial0" use setkeycodes * to make it known
code 0xd9, setkeycodes e059 // seems to be a code thrown when keyboard idles
code 0x81, setkeycodes e001 // happens before a stream of two or more keys are beign sent
code 0xbb, "" e03b // button labeled help (microsoft help prolly)
code 0x88, e008 // button labeled undo (text editing)
code 0x87, e007 // redo (text editing)
code 0xbe, e03e // a button labeled new (document)
code 0xbf, e03f // button labeled open (document)
code 0xc0, e040 // button labeled close (document)
code 0xc1, e041 // button labeled reply (email)
code 0xc2, e042 // botton labeled fwd (email)
code 0xc3, e043 // button labeled send (email)
code 0xa3, e023 // spell (help spelling)
code 0xd7, e057 // save
code 0xd8, e058 // print
code 0xe4, e064 // My Pictures
code 0xbc, e03c // My Music
code 0x85, e005 // Start Instant Messaging client
code 0x96, e016 // Log Off button

I hope that helps...
Comment 11 John G. 2008-11-27 11:17:24 UTC
I have exactly the same issue with this keyboard. First of all here is a picture of it so you understand what buttons im talking about:
http://le-poilu.whykywa.com/public/img/MS_WLD6000v2/MS_WLD6000v2.0_05.jpg

Apart from the extra buttons theres a "f lock" button that when enabled the F1,F2.. etc behave as usual. When disabled they produce different scancodes or no scancodes at all depending on kernel version as i will explain further on.

With kernel version up to 2.6.25:

All extra keys except four work perfect. X recognises them and i can use them in gnome keyboard shortcuts (they get shortcut names that correspond to the icon the key has on the keyboard for example XF86AudioMute for mute button, XF86Mail for the mail button and so on). The only 4 keys that dont work are the following:
a) "lock" button: (its the right one above the numpad) It doesnt give any output with showkey -s but it gives keycode 433 with showkey -k
b) F10 with f-lock disabled: No scancode (showkey -s) but it gives keycode 432
c) Zoom button: It is the big button on the lower left side of the keyboard. It is actually two buttons, one on the upper edge of the button (zoom up) and one on the lower (zoom down). Again nothing with showkey -s but zoom-up gives keycode 418 and zoom-down 419.

With kernel 2.6.26 and 2.6.27:

The only extra buttons that work are the five numbered ones above the f keys, between the volume up key and star/favorites key. They produce both scancodes and keycodes and i can use them in gnome keyboard showrtcuts. All other buttons produce neither scancodes or keycodes.

lsusb gives this: Bus 002 Device 002: ID 045e:00f9 Microsoft Corp.

Unfortunately i cant give you hid debug output. If i modprobe hid with debug=2 option then cat /proc/kmesg keeps printing stuff quickly even if i dont press any key or move the mouse. If i press any of the extra buttons they do give some output but i dont know how to capture it :(
Comment 12 Adam Dorsey 2008-12-04 17:16:08 UTC
This is happening in Ubuntu 8.10 "Intrepid Ibex".  There is a bunch of information available at https://bugs.launchpad.net/ubuntu/+bug/281993 as well as a patch that seems to fix the issue.  

In short, some code was written in drivers/hid/usbhid/hid-quirks.c to handle getting certain unworking keys working on devices using the Microsoft Wireless Desktop Receiver 3.1 (model 1028).  The previously nonworking hotkeys ("My Favorites" on a Wireless Comfort Keyboard 4000) now work at the expense of the other (previously working) hotkeys.  Removing the special case in hid-quirks.c allows the main set of hotkeys to work again, at the expense of the "My Favorites" keys.  

It would be cool if a method of making both sets of hotkeys work at the same time could be found, but I personally would settle for working play, pause, volume, etc. and screw the "Favorites."
Comment 13 Adam Dorsey 2008-12-11 11:57:47 UTC
Created attachment 19255 [details]
Patch that resolves hotkey issue for certain Microsoft Wireless keyboards.

This is the patch that I mentioned previously.  It simply removes the workaround previously added for the specific version of wireless receiver common to these keyboards (Model 1028, I think - Microsoft Wireless Desktop Receiver 3.1)
Comment 14 Adam Dorsey 2008-12-27 00:05:38 UTC
http://markmail.org/message/2xxgwhvjpy3xomyw

Apparently this was known when the original patch was accepted.

What is the approved method to proceed?  There's a lot of people with broken keyboards, and a fix that didn't require a kernel patch would be really nice...

Alternatively, there is a parameter in usbhid.ko called rdesc_quirks involving the "quirks" section of the module.  That is what is broken for this keyboard.  Can someone give me details on proper use of this parameter so maybe I can come up with a solution that doesn't involve repatching my kernel every release?
Comment 15 Jiri Kosina 2009-01-19 02:29:13 UTC
Created attachment 19885 [details]
[PATCH] HID: adjust report descriptor fixup for MS 1028 receiver

This patch, resolving the issue, has been queued in HID tree.
Comment 16 Michael Hanke 2009-03-26 16:39:13 UTC
there is a similar keyboard (it's probably the predecessor) with the same bug.

It does not have DEVICE-ID 0x00f9, but 00e3 (Microsoft Wireless Optical Desktop 2.20).
It is a combo-device (keyboard: model 1011 / mouse: model 1007) and shows exactly the same behaviour as mentioned here before.
Comment 17 Jiri Kosina 2009-03-31 14:44:21 UTC
Created attachment 20759 [details]
HID: support for microsoft wireless otpical desktop 2.0

Does the attached patch fix the problem? It adds the very same handling as we have for 0x00f9.
Comment 18 Mehmet Giritli 2010-06-03 09:59:27 UTC
Hi,

I have a microsoft comfort keyboard 5000 wireless combo with a 2.4GHz Transceiver and had problems with some of its keys as mentioned in the above messages.

dmesg lists this set as follows:

microsoft 0003:045E:0745.0001: input: USB HID v1.11 Keyboard [Microsoft Microsoft® 2.4GHz Transceiver v6.0] on usb-0000:00:1d.1-2/input0
microsoft 0003:045E:0745.0002: input: USB HID v1.11 Mouse [Microsoft Microsoft® 2.4GHz Transceiver v6.0] on usb-0000:00:1d.1-2/input1
microsoft 0003:045E:0745.0003: input: USB HID v1.11 Device [Microsoft Microsoft® 2.4GHz Transceiver v6.0] on usb-0000:00:1d.1-2/input2

Adapting Jiri's patch for device id 0745 helped me to solve most of the problem with a kernel 2.6.33. 

Now I have only 3 keys left which are not generating any scancode events.

Two of these keys are zoom in and zoom out keys. The third one is Windows 7 "flip key" shortcut key for browsing through taskbar favourites.

Any chance I can get these keys to work as well?

http://www.microsoft.com/presspass/press/2009/aug0908-04wcd5000pr.mspx?rss_fdn=press%20releases

Note You need to log in before you can comment on or make changes to this bug.