How to remap broken (laptop) keyboard?

Using applications, configuring, problems
Post Reply
Message
Author
rob
Posts: 50
Joined: Wed 18 May 2005, 12:09

How to remap broken (laptop) keyboard?

#1 Post by rob »

One of the keys on my keyboard oes not work. In windows I was able to remap the ¬`| key to replace the broken letter d on my UK keyboard in the registry quite easily or use the onscreen keyboard. Reading up on the problem in linux, I have found that I must create my own keymap. could some kin user please give an explanation to make my own keymap or uploa one for me please with `¬| key as d? For anyone wondering, seamonkey spell check filled in a few ds for me. Thanks

User avatar
Aitch
Posts: 6518
Joined: Wed 04 Apr 2007, 15:57
Location: Chatham, Kent, UK

#2 Post by Aitch »

Isn't it easier/cheaper to replace the keyboard?

Aitch

User avatar
Flash
Official Dog Handler
Posts: 13071
Joined: Wed 04 May 2005, 16:04
Location: Arizona USA

#3 Post by Flash »

Maybe it's a laptop. :)

I'm pretty sure that there are threads in the forum which produced answers that could be adapted to solve this problem. I entered "remap AND keyboard" in the forum search and got 3 results: this thread, plus
http://www.murga-linux.com/puppy/viewto ... 204#208204
http://www.murga-linux.com/puppy/viewto ... 339#165339

muggins
Posts: 6724
Joined: Fri 20 Jan 2006, 10:44
Location: hobart

#4 Post by muggins »

What about gtkeyboard?

To use it on pup4, you would probably need to install these files:

glib12-1.2.10.pet (53k)
gtk+12-1.2.10.pet (522k)
gdk_pixbuf10-0.22.0.pet (121k)
imlib-1.9.15-1.pet (386k)

Or what about:

http://www.columbia.edu/~djv/docs/keyremap.html

I'm sure there are other key remap programs, but I can't think of any at the moment. On my laptop, the old trick of using the numeric keypad, and entering Alt+100 doesn't work.

muggins
Posts: 6724
Joined: Fri 20 Jan 2006, 10:44
Location: hobart

#5 Post by muggins »

Or xhkeys?

rob
Posts: 50
Joined: Wed 18 May 2005, 12:09

#6 Post by rob »

Its a laptop :)
I'm trying Xkeycaps as mentioned in one of those previous threads. Thanks

tony
Posts: 334
Joined: Sat 14 Jan 2006, 10:52
Location: Montreal.ca

Broken laptop keys

#7 Post by tony »

Hi rob,

This link was very helpful :-

http://www.columbia.edu/~djv/docs/keyremap.html

I have a dodgy w. So in a terminal typing xmodmap -pke gives the keycodes.

for me keycode 10 is the 1 and exclamation mark

So xmodmap -e "keycode 10 = 1 w" changed the exclamation mark to w

It was only a quick test so picking another key where you could replace both upper and lower case letters by using the shift key would be a better choice.

Once you have got it working put the xmodmap command into /etc/rc.d/rc.local

I don't think this will work for passwords as rc.local is read after the system starts.

Regards Tony

rob
Posts: 50
Joined: Wed 18 May 2005, 12:09

Remap keyboard

#8 Post by rob »

My main problem is typing the key that isn't working in the rxvt window for testing. I on´t even know how to copy an paste there!

tony
Posts: 334
Joined: Sat 14 Jan 2006, 10:52
Location: Montreal.ca

Dodgy keys

#9 Post by tony »

Hi rob,

my mouse has a left and right button plus a wheel in the middle.

I mark the text with the left button and then click the wheel to paste.

You can copy a letter from anywhere and put it in like this.

You could probably just use the keyboard but you will have to Google to

find out how.

I missed out on the fact that a totally inactive key would cause problems.

I checked out xmodmap on my own computer which is ok.

It's my grandsons computer which is dodgy.

Regards Tony

muggins
Posts: 6724
Joined: Fri 20 Jan 2006, 10:44
Location: hobart

#10 Post by muggins »

What's going on Rob? For some reason I thought you had it sorted! Can you give more info on which key you're trying to remap "d" to, as mentioned in your first post in this thread...as I'm none the wiser what key is represented by ¬|

rob
Posts: 50
Joined: Wed 18 May 2005, 12:09

Remapping key

#11 Post by rob »

The key I'm trying to get mapped to d is the key left of number 1 on my keyboard. I wish to map it to the letter d, as I have it in windows. I was told how to do it, but I can't get a d written in the console window as my d key isn't working! :s What is the paste shortcut for the console window (not ctrl+v, tried that and it didnt work) Sorry guys.

muggins
Posts: 6724
Joined: Fri 20 Jan 2006, 10:44
Location: hobart

#12 Post by muggins »

I'm currently on pup2.16, and can paste into a console via Control+v, Shift+insert, and clicking both mouse button simultaneously. I don't know why some of these stopped working for pup4?

But when I'm using pup4, the last, simulating middle mousebutton click, definitely worked.

muggins
Posts: 6724
Joined: Fri 20 Jan 2006, 10:44
Location: hobart

#13 Post by muggins »

Rob,

I don't know if there are any gtk frontends to xmodmap anywhere, but I just compiled XKeyCaps, and while it looks a bit dated in it's interface, it does the job.

I just went with the default 101-key keyboard, right-clicked the d key & selected Exchange Keys, then clicked the backtick-tilde keys, then Write Output-> Changed Keys, and it worked straight away.

Because I've compiled it on p2.16, if you were using p4 or p3, you would need to install libxaw95-1.1.4.pet

Also, I think this is only effective during the current Xsession. The above write procedure saved the keymap as /root/.xmodmap-puppypc, so I imagine that this might be overwritten on reboot, so if you saved it as some other name, xxx, then added a line, to /etc/rc.d/rc.local, like:

Code: Select all

xmodmap xxx
then it would be loaded on reboot. Let us know whether this works for you.
Attachments
xkeycaps-2.46.pet
(94.4 KiB) Downloaded 467 times

Post Reply