All of lore.kernel.org
 help / color / mirror / Atom feed
* Questions about the console keyboard driver / translation tables
@ 2012-03-10 23:14 finkler
  0 siblings, 0 replies; only message in thread
From: finkler @ 2012-03-10 23:14 UTC (permalink / raw)
  To: linux-kernel

Hi there,

I am trying to understand the logic of the Linux keyboard driver, I am 
not sure if this is the right place to ask, but I don't know where else 
I could.

Btw. I am talking about an unicode console here.

1.) The Linux kernel (currently) can take 256 translation tables 
(keymaps), I figured that if I have 8 Mod-Keys and I can press two at 
the same time, then this makes 256 possible modifications.
E.g. the value of my keycode of the button 'a' is 0x0b61 (small letter 
a) in table 0 and 0x0b41 (capital letter A) in table 1, so is it true 
that table 1 is for shift pressed keycodes?
If so, then why is shift (KG_SHIFT in linux/keyboard.h [1]) set to 0, 
and how do I compute the modifications, meaning how do I know what e.g. 
index 231 represents?

2.) As seen above, the value for 'a' is actually 0x0b61 instead of 
0x0061, if b indicates a type (here KT_LOCK) why isn't it 0xfb61, 
because I thought that only values above 0xf000 represent typed values, 
and the values below are simply unicode values.
The values above are read via the KDGKBENT ioctl [2], are these values 
read differently then written?
E.g. would I only type 0xfb61 when using the KDSKBENT ioctl?

3.) If I wanted to assign "Return" to a keycode, what is the difference 
between using a simple 0x000d (13) and the KT_SPEC type with the 
function fn_enter (which is supposedly 0xf201)?

I hope anyone can help me out a little,
thank you very much in advance,
regards,
Finkler

1: http://tomoyo.sourceforge.jp/cgi-bin...nux/keyboard.h
2: http://www.kernel.org/doc/man-pages/...e_ioctl.4.html


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2012-03-10 23:15 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-03-10 23:14 Questions about the console keyboard driver / translation tables finkler

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.