Game keys

James Cameron quozl at laptop.org
Mon Nov 3 04:49:10 EST 2008


On Mon, Nov 03, 2008 at 07:45:07PM +1100, James Cameron wrote:
> Some scancodes have no mapping to keycodes in the kernel on debxo, yet
> they have a mapping on the OLPC OS build.

Because the mapping has not gone upstream yet.

On OLPC OS build 757, loadkeys is run by /etc/init.d/olpc-configure,
which is provided by package olpc-utils.  It uses the manufacturing tag
data or reads /dev/nvram to pick a keyboard layout.  This is not what
you are looking for.

Here is what you are looking for ... /usr/sbin/setolpckeys provided by
the olpc-utils-0.84.29.20080820git1d35c4-1.olpc3.i386 package defines a
set of translations via a udev rule, see
/etc/udev/rules.d/96-olpc-keyboard.rules

ACTION=="add", SYSFS{name}=="AT Translated Set 2 keyboard", KERNEL=="event*", RUN+="/usr/sbin/setolpckeys /dev/input/%k"

The udev rule is courtesy of package initscripts-8.76.2-1.olpc3.7.i386

I'll ponder adding this into debxo.  I was able to retrofit it just
fine now, by copying across the udev rule file and the binary.

git://dev.laptop.org/projects/olpc-utils

-- 
James Cameron    mailto:quozl at us.netrek.org     http://quozl.netrek.org/



More information about the Devel mailing list