[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: extra buttons lost after upgrade

I have done the following with the "extra" keys on my Thinkpad

1) I ran "xev" to find out the keycodes for the "extra" keys

2) These keys generated scancodes 223 & 224.  The scancode
   translations for xkb for a bunch of devices are given (in our case,
   probably xfree86) in /etc/X11/xkb/keycodes/xfree86.  For example,
   223 & 224 are symbols I6A and I69.

3) I'm using a pc101 model which is based on the us layout, basic

4) I added a new variant to extend the basic variant as follows:

	Made a new stanza in /etc/X11/xkb/symbols/pc:

	xkb_symbols "t41p" {

		include "pc/us(basic)"
		key <I6A> {	[	F13	]	};
		key <I69> {	[	F14	]	};

	I added a line to symbols.dir to identify the new variant:

	-------- -------- pc/us(t41p)

5) I then used the XkbVariant "t41p" in the input secion of my
   XF86Config-4 file.

   You can test this without restarting X using:

	setxkbmap -rules xfree86 -model pc101 -layout "us" -variant "t41p"

   You can verify that these new keys are now bound to F13 and F14 using "xev".
   Then you can bind these (e.g. in gnome) to new events as desired.

One can do the same sort of thing with any device.  For example, I
just bought a Keyspan PR-US2 dohicky that controls the mouse and two
buttons remotely via radio for making presentations (and has a built
in laser pointer).  I make presentations with Latex via acroread so I
am about to remap the Windows specific buttons for advancing
powerpoint slides to buttons to advance Acroread.  Will add a variant
to xkb for this the same way.



On Tue, Nov 30, 2004 at 11:28:51PM +0100, Anders Breindahl wrote: 
> On Tuesday 30 November 2004 10:57, Stefan Rutzinger wrote:
> > hello,
> > 
> > I have an inspiron 8200 laptop and could use the four extra keys (play 
> > stop rew fwd) in X11 until last apt-get upgrade (testing).
> > 
> > In /etc/X11/xkb/keycodes/xfree86 they are still aliased from I01..I04 to 
> > keycode 129..132.
> > 
> > In /etc/X11/Xmodmap keycodes 129..132 are still assigned to letters (xvzb 
> > for the xmms player).
> > 
> > Yet it doesn't work anymore, the letters are not even printed in an xterm. 
> > No message, no beep.
> > 
> > What has changed? Keyboard? For some strange reason I already had to 
> > change from 104keys to 105keys to get back the <>| key.
> Hi,
> I am in the same situation (although on an 8000, and never having had the keys 
> working), and I have noted that the kernel prints out something, when I press 
> the buttons in the console. I am to bind the key using the command 
> `setkeycodes e001 <keycode>' it says. I am able to bind mmkeys to the 
> keycodes i choose, when I run the commands as recommended.
> I suppose that the keycode is never translated at kernel-level, and thereby no 
> signal can be generated in X. Do anyone happen to know the file, in which 
> these keycodes are defined?
> I hope it helps.
> Anders Breindahl.
> -- 
> To UNSUBSCRIBE, email to debian-laptop-REQUEST@lists.debian.org
> with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org



Martin Weinberg                      Phone: (413) 256-3044
21 Gulf Road
Pelham, MA  01002

Reply to: