Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have bought a (DIGITECH XC-4943) multi-media keyboard. It has no manual and some of the keys are not labelled. Is there a utility (or some delphi code) I can use to display the messages that each key sends ?

share|improve this question

migrated from Jul 25 '12 at 9:05

This question came from our site for professional and enthusiast programmers.

The xev tool under X or showkey program under Linux console will report this information. – sarnold Jul 24 '12 at 4:01

You have different options depending on the OS you use.

First, you must know a few terms: A scancode is the lowest identification number for a key. If a key does not have a scancode then we cannot do anything because it means that the kernel does not see it. A keycode is the second level of identification for a key, a keycode corresponds to a function. A symbol is the third level of identification for a key, it is the way Xorg refers to keys.

As a Linux user, you can use the showkey command in a TTY terminal to check for keycodes. Do not use this under a Terminal Emulator on Xorg. If you wish to use a Terminal Emulator, use the xev command from the xorg-xev package.

If you do not see a keycode on your screen against a keypress, you must take a chance with finding its scancodes and assigning a keycode to them.

Press the key on a TTY Terminal and then execute:

$ dmesg|tail -5

If you see something akin to this:

atkbd.c: Unknown key pressed (translated set 2, code 0xf1 on isa0060/serio0).
atkbd.c: Use 'setkeycodes e071 <keycode>' to make it known.

You know that the kernel recognizes the keypress, but has no keycode assigned to it. Use the setkeycodes as mentioned to assign a keycode to the scancode.

EDIT: Let me know if you want more information on doing all this from within Xorg. Or for further information on creating and assigning special keys.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.