I use a Microsoft Natural Ergonomic Keyboard 4000 on Ubuntu 10.10. The multimedia keys (Volume, Play/Pause) work, the Mail and Calculator button as well.
Now I would love to use the zoom slider, if it were possible I'd like to use page scrolling with that. Is there some way to enable that?
Create the file
/etc/udev/rules.d/98-ms-ergo.rules
with the following contents:This will map the zoom key to page-up/page-down without changing the installed files in
/lib/udev
.Once added, you just need to unplug and replug your keyboard for it to start working.
On Xubuntu 13.10 (perhaps on Ubuntu 13.10 too) the same can be done as follows:
Edit key mappings in
/lib/udev/hwdb.d/60-keyboard.hwdb
:Run
sudo udevadm hwdb --update
Reboot.
In order to configure the Microsoft ergonomic keyboard 4000 we have to create a configuration file that contains the keyboard declaration and the records for mapping the keys.
To do so there are three types of information we need to determine:
scancode
which is the actual key on the keyboardname
to assign the desired functionality to the selected keyFirst find the keyboard type:
In terminal run the following command:
the output determines the keyboard type:
It appears after
ID
. In this case it is045e:00db
Second find the scancode and the name of the key.
To determine them, we use the
evtest
program which logs out the event information of a specific device on terminal:If you don't have the program, install it by running the following command:
By running the
evtest
program we get the following output:The output is pretty much self explanatory, insert the appropriate number for the keyboard, which here is number
3
then hit enter:Doing so, will output lots of information on the terminal and ends in following lines:
Now with every key-press on the keyboard it dumps out the key information. For example the Slash key next to the Right Shift shows:
The first line of the log contains the information about the actual key on the keyboard such as
scancode
which comes after the value. In this case it is 70038The second line contains the assigned functionality information like name of the key. In this case it is SLASH. Examine the other keys to find their appropriate names.
So in a nutshell:
After gathering the necessary information we create the configuration file:
Hit
i
to activate the Insert mode and type the following:Save and exit by pressing
escape
then typing:wq
and hit enter.Then run the following two commands for the configuration to take effect:
Finally unplug the keyboard and re-plug it in.
Some notes about the configuration file:
sudoedit
you can use any other text editor, just remember to follow the exact format of the file as explained above.v
andp
which stand for vendor and product. They are important as well.KEYBOARD_KEY_
The problem is that evdev driver ignores keycodes > 255.
The solution, thanks to Marco Chiappero:
On my machine, extra keys (HomePage, Search, Calc, etc.) and zoom input were sent though /dev/input/event5 whereas ordinary keys were sent through /dev/input/event4. Zoom key value agree with queueoverflow's.