Jump to content

Keyboard Keycodes for Multimedia Keys


rickwood
 Share

Recommended Posts

I would like to use Hotkeys to activate the multimedia/web keys on my microsoft multimedia keyboard. I'm running Mandrake 10 alongside of Xandros 2 in a dual boot configuration.

 

In Xandros, I've successfully set up Hotkeys by using xev to identify the keycodes for each of the keyboard's special keys. All keys return valid keycodes, and setting up Hotkeys posed no problems.

 

In Mandrake, most of the special keys are also identified using xev. However, the keycode for one key is different in Mandrake than in Xandros. This is quite odd, but easy enough to deal with. Also, four of the special keys do not return a keycode at all in Mandrake using xev. It is as if X doesn't even know these keys exist on my keyboard. Hence, I'm a little perplexed at how to use these four keys in Mandrake.

 

Does anyone know what X configuration files and/or settings I should be looking at to try and determine the difference between Xandros and Mandrake in recognizing the special keys on this keyboard? Also, if I can find the appropriate configuration files, is it simply a matter of overwriting the Mandrake file(s) with the corresponding Xandros file(s)? Any suggestions would be appreciated.

Link to comment
Share on other sites

I use "hotkeys" for my M$ Natural Multimedia Keyboard, works like a charm. On MDK, all it takes is urpmi hotkeys, and some tweaking the config file. I didn't set any xev settings.

 

No problems with it yet, and I've been running it for a couple of days, yet. Here's counting the days. ;)

 

93,

-Sascha.rb

Link to comment
Share on other sites

I'm glad it's working for you. It's partially working for me, but as I indicated, four of the keys don't work at all regardless of tweaking the Hotkeys configuration. Hotkeys won't be able to use these keys until X recognizes that the keys are there. I was simply using xev to help troubleshoot the problem and determine why these keys don't seem to work.

Link to comment
Share on other sites

As a start, take a look at your /etc/X11/XF86Config-4 file InputDevice section to see what the Option "XkbModel" is set to. I'm using a Microsoft Internet keyboard, so I set my XkbModel to "microsoftpro". This provides keycodes and keysyms for all the keys on my keyboard.

 

The standard X install process doesn't offer this as an option so I have to set it manually. To see the available models look at the file /usr/lib/X11/xkb/rules/xfree86.lst. If you don't find what you need there, you can always dig into writing your own XKB config files, but be warned that XKB is a highly flexible but rather arcane rats nest of rules. Good Luck.

 

As for associating a keycode with a keysym, if you know about xev you probably know about xmodmap too. Its probably easier to use xmodmap that to write the appropriate XKB files. Finally, to make those multimedia keys usefull, I've found lineak easy to set up. MDK now includes the rpm package lineakd-0.7.2-2mdk (might be contrib).

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...