Subject: Re: keytable
To: None <port-arm32@NetBSD.ORG>
From: Robert Black <r.black@ic.ac.uk>
List: port-arm32
Date: 04/09/1997 17:29:57
On Apr 8,  7:18pm, Peter Berg wrote:
> Subject: keytable
> Hello,
>
> in which format is the keytable in
>
> 	/usr/src/sys/arch/arm32/mainbus/kbd.c
>
> in
>
> 	key_struct keys[256] = { ... };
>
> stored ?
>
> I'll try to add a german layout, but I couldn't find out how the values are
> sorted / coded there.

Five numbers for each raw key number. The first four of these are cooked key
numbers (ACSII for the alphanumeric codes) for the base symbol, the shifted
symbol, the ctrl symbol and the alt symbol respectively. The last number is a
flag byte which controls whether the key is a modifier key and a couple of
other things (like the effect of caps-lock - see the MODIFIER_ #defines in
kbd.c). Some keys produce multibyte key codes (for example E0 followed by an
extended keycode) - these have a separate table. Cooked values of 0x100 or
greater are special codes which typically produce sequences of bytes.

> I hope a new console driver will support loadable fonts and keytables, but as
> long as it is not yet available, I think it is time to add 'hard coded'
> support for german keyboards.

It supports keytables and one day it will have a font loading facility.

Cheers

Rob