You, Warner Losh, were spotted writing this on Sat, Apr 15, 2000 at 12:01:05AM -0600:
> In message <[EMAIL PROTECTED]> Mike Pritchard writes:
> : Here are the codes for the Compaq "Easy Access Internet Keyboard".
> : They also have a newer version with even more buttons, but I don't
> : have access to one, so I can't supply the codes for it.  If someone
> : is going to do some work to get the Microsoft keyboard's extra keys
> : to work, it shouldn't be hard to integrate these keys at the same time.
> 
> Thanks Mike.  If I move forward on this, I'll include these too.

To make FreeBSD grok them, go to sys/dev/kbd/atkbd.c (that's assuming
the keyboard is AT-style rather than USB), and modify atkbd_read_char():

--- atkbd.c     Sat Apr 15 11:58:13 2000
+++ atkbd.c.new Sat Apr 15 12:09:28 2000
@@ -681,6 +681,15 @@
                case 0x5d:      /* menu key */
                        keycode = 0x6b;
                        break;
+                /* the following are super-duper extended MS keys */
+                case 0x5f:     /* Sleep key */
+                        keycode = 0x6d;
+                        break;
+                case 0x65:    /* Search key */
+                        keycode = 0x6e;
+                case 0x66:    /* Favourites key */
+                        keycode = 0x70;
+
                default:        /* ignore everything else */
                        goto next_code;
                }

And so on for all the keys, using your scancodes in case
statements, and allocating new keycodes as you go along, starting
from the first available one now which is 0x6d.  Then
you just add new lines to keymap files, starting from 109=0x6d,
and it should work at once. We have 148 spare entries in keymap_t
at the moment, they should suffice for some time ;)

Of course, with all those new keys on all those keyboards, we should
perhaps think about whether to add all of them as new keycodes,
and if so, in which order, etc. I've no idea if FreeBSD's concept
of 'keycode' (i.e. key number independent of keyboard model) is
synchronized with other BSD's, or Linux, etc.

Have no idea what to do about X though. 

-- 
Anatoly Vorobey,
[EMAIL PROTECTED] http://pobox.com/~mellon/
"Angels can fly because they take themselves lightly" - G.K.Chesterton


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message

Reply via email to