Remap dead Left Arrow key onto Menu key? (Solved)

Booting, installing, newbie
Post Reply
Message
Author
Mitchellray
Posts: 116
Joined: Mon 07 Dec 2009, 04:30

Remap dead Left Arrow key onto Menu key? (Solved)

#1 Post by Mitchellray »

Hello,
I am still searching for assistance on how to map the Left Arrow function onto the right Menu key on my netbook.
The Left Arrow key does not work. It is dead. It is supposed to function normally as Left arrow and also Fn+Home.

It is not worth buying a new keyboard, due to cost and also that it might not work. I'd be worried about getting the pre-connected cable seated properly in the connector without ruining it.

There has been some past input from posters here on the forum, but the thread ended without a resolution to the issue I am trying to resolve.

Any help will be much appreciated.
Mitchellray

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#2 Post by nooby »

Edit. I know from my own personal experiences how frustrated I felt again and again when I totally failed to get help. One issue I had took 6 month or more. And I asked many many times. So try to be patient :)

Yes sure many here do want to help you but you have to consider where you are at!
Puppy forum is a totally volunteer forum. No paid person to help you out.

We all here do this on our free time and out of a compassion to help others out.

You started a new thread without linking to your old one so we could learn from that one what people has suggested up to now.

http://www.murga-linux.com/puppy/viewtopic.php?t=67749

You don't tell much about your machine in the current post. Hardware info can be important for to help you.

I am no Moderator but if I had that position I would not be so happy about you starting a new thread with exact same problem. Such is usually not encouraged.

Tell me more about what you have tried out. Have you tested to do search in the friendly search machine in my link.

Try words like remapping of key. You should try to find out what number the two keys have in your country.

hope that helps

Edit.

I have now read that thread and I remember that I did read it when it was new too but realized that I have no knowledge how one do such things. But I would be surprised if it was impossible, so you only need to find somebody having had same problem before. if not here in our forum I trust that google should be able to find it in some other forum.

it is a very general question so it should be possible to find a solution.
I would use the search in my signature while you hope for that somebody read here and then use google on every forum and sooner or later you find somebody having same need and there they describe the solution.

I hope you agree that it is not Puppy specific problem. Friendly smile.
I use Google Search on Puppy Forum
not an ideal solution though

User avatar
Dougal
Posts: 2502
Joined: Wed 19 Oct 2005, 13:06
Location: Hell more grotesque than any medieval woodcut

#3 Post by Dougal »

You should have revived the old thread, not started a new one.

Assuming your keyboard uses standard keycodes, these are the ones you care about

Code: Select all

# xmodmap -pk |grep '(Left)'
    100         0xff51 (Left)   
# xmodmap -pk |grep '(Menu)'
    117         0xff67 (Menu)
The ugly way to do it would be to change in /etc/X11/xkb/keycodes/xfree86

Code: Select all

    <LEFT> = 100;
to

Code: Select all

    <LEFT> = 117;
A nicer way would be to use a .Xmodmap file, which should probably include something like

Code: Select all

keycode 117 = Left
or maybe

Code: Select all

keysym Menu = Left
(I've never used xmodmap, so I'm not sure about this... you might need to start with "clear Left" or something)
What's the ugliest part of your body?
Some say your nose
Some say your toes
But I think it's your mind

Mitchellray
Posts: 116
Joined: Mon 07 Dec 2009, 04:30

Key remap successful

#4 Post by Mitchellray »

Hello Dougal and nooby,
Thank you for encouraging me to learn etiquette. I will have to learn how to link threads and how to revive a thread.

Dougal's 'not so pretty' method of editing /etc/X11/xkb/keycodes/xfree86 worked fine for the purpose. That was to avoid spending money on a new keyboard for my eeePc not knowing whether that would solve the issues.

Since my original post, the Ctrl keys also stopped functioning in both XP and puppeee. I mapped the Ctrl function to the RALT key and have regained that function as well.

I was surprised at the simplicity of this band-aid fix because looking for the same fix for XP yielded seemingly much more complicated solutions. Although, I would guess the principle is the same, whether or not the appropriate files are accessible.

Also, in editing the mappings, I commented out the existing lines for both of the borrowed keys, 'Menu' and 'RALT'. So far so good.
Thank you for this solution.
Mitchellray

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#5 Post by nooby »

Cool that Dougals remapping the brute force way worked that well.
Such is good to know.

Hope I did not come through as too unfriendly. To write in a foreign language one fail to hit the right tone and can sound condescending even when one just want to give a nice friendly advice.

Happy it worked out for you.

May I say something that can be easily misunderstood. These small keyboards maybe are not as sturdy and lasting as real free standing ones we are used to handle rather rough? At least I am doing that at times. Hitting hard that is.

I have the cautious notion that what if you and I hit them too hard and that create the unfortunate dead keys?

Just a wild guess I have. What else can create these things. Coffee or somethign :)

Anyway it is always good when things clear up.

So now you can write a happy [Solved] instead of a sad Unresolved :)
I use Google Search on Puppy Forum
not an ideal solution though

aarf

#6 Post by aarf »

spend sometime looking at the threads but still cant get it.
want to map backspace to pause/break in puppeee4.4rc2 also in lupu525.
so far my keys not happening are del, F10, backspace, and left click of the mouse-bar.
cant find key number because when they are pressed nothing happens.

User avatar
Karl Godt
Posts: 4199
Joined: Sun 20 Jun 2010, 13:52
Location: Kiel,Germany

#7 Post by Karl Godt »

from `xev` command : keyboard en_US 104 set to 102keybd in xorg.conf :

keycode 119 (keysym 0xffff, Delete)

keycode 76 (keysym 0xffc7, F10)
keycode 91 (keysym 0xffae, KP_Decimal)

keycode 22 (keysym 0xff08, BackSpace)


ButtonPress event,
state 0x0, button 1, same_screen YES
KeyRelease event, serial 32,
state 0x100, keycode 8 (keysym 0x0, NoSymbol), same_screen YES,
ButtonRelease event,
state 0x100, button 1, same_screen YES

AND for normal keyboards there ( was ) also :
XKeyCaps

The output varies much if you choose xF86 , XAccel or OpenWindowsX86 layout .
XFREE86 : keycode 0x4C =F10; which would give 76 in decimal
XACCEL : keycode 0x4C =F10;
OpenWin : keycode 0x80 =NoSymbol ;! The "F10" key generates NoSymbol
You would have to find one with the same hardware specs to post correct mappings which seems to be quite confusing .

aarf

#8 Post by aarf »

now lupu525
xev

Code: Select all

KeyRelease event, serial 39, synthetic NO, window 0x2200001,
    root 0x62, subw 0x0, time 1077408, (193,340), root:(461,396),
    state 0x0, keycode 110 (keysym 0xff13, Pause), same_screen YES,
    XLookupString gives 0 bytes: 
    XFilterEvent returns: False

Code: Select all

xmodmap -pk |grep '(Pause)'
    110    	0xff13 (Pause)	0xff6b (Break)	0xff13 (Pause)	0xff6b (Break)	
    114    	0xff13 (Pause)	0xff6b (Break)	0xff13 (Pause)	0xff6b (Break)	
# xmodmap -pk |grep '(BKSP)'
#
so in /etc/X11/xkb/keycodes/xfree86 changed now are

Code: Select all

<BKSP> =  110;

Code: Select all

    <PAUS> = 22;
no effect so try

Code: Select all

    <BKSP> =  110;
            <BKSP> =  114;

Code: Select all

<PAUS> = 22;
    <BRK>  = 22;
still no effect.
reboot and xev and xmodmap still same as above. xfree86 holds changes

User avatar
Karl Godt
Posts: 4199
Joined: Sun 20 Jun 2010, 13:52
Location: Kiel,Germany

#9 Post by Karl Godt »

Interesting . Xorg seems to compile the keyboardlayout into
/var/lib/xkb

It might be worth a try to delete some files there and restart X .

Of course running Xvesa does not do anything there .

To check which Xserver is currently running :

Code: Select all

readlink -e `which X`
ps | grep 'X'

aarf

#10 Post by aarf »

solved. thanks Karl Godt and all. :D

Code: Select all

# readlink -e 'which X'
# ps | grep 'X'
 6324 root       0:03 X :0 -br -nolisten tcp
 6485 root       0:01 /usr/local/apps/ROX-Filer/ROX-Filer -p /root/Choices/ROX-Filer/PuppyPin
11382 root       0:00 grep X
# 

Code: Select all

# readlink -e `which X`
/usr/bin/Xorg
# ps | grep 'X'
 6324 root       0:18 X :0 -br -nolisten tcp
 6485 root       0:04 /usr/local/apps/ROX-Filer/ROX-Filer -p /root/Choices/ROX-Filer/PuppyPin
18047 root       0:01 geany /root/Choices/ROX-Filer/PuppyPin
19242 root       0:00 grep X
# 
deleted the wheeled icon files in /var/lib/xkb reverted to just

Code: Select all

<BKSP> =  110; 
 
<PAUS> = 22; 
     <BRK>  = 22; 
i.e. not

Code: Select all

<BKSP> =  110; 
<BKSP> =  114; 
 
<PAUS> = 22; 
     <BRK>  = 22; 
and restart X .

and now have a functioning backspace key. will take a while before i unconsciously use it again instead of highlight and overwrite I've been using for months.
thanks.
Attachments
kk.jpg
(25.6 KiB) Downloaded 1217 times

User avatar
Dougal
Posts: 2502
Joined: Wed 19 Oct 2005, 13:06
Location: Hell more grotesque than any medieval woodcut

#11 Post by Dougal »

aarf wrote:deleted the wheeled icon files in /var/lib/xkb
...
and now have a functioning backspace key.
You probably wouldn't need that if you did it the "proper" way... it would be good if someone verified what I wrote about .Xmodmap, since it's not good to send people to hack the Xorg files.
What's the ugliest part of your body?
Some say your nose
Some say your toes
But I think it's your mind

aarf

#12 Post by aarf »

Dougal wrote:
aarf wrote:deleted the wheeled icon files in /var/lib/xkb
...
and now have a functioning backspace key.
You probably wouldn't need that if you did it the "proper" way... it would be good if someone verified what I wrote about .Xmodmap, since it's not good to send people to hack the Xorg files.
still have lots of puppies save files to play with. type exacly what you want tested or i will play when i get around to it. if you have it typed out you could then test yourself.
was thinking a gui based on PicPuz jigsaw puzzle type interface would be the way to go. click and move the tabs.
was also thinking i need a personal sfs so i dont have to update each pupsave each time. one day i will take the minutes necessary to learn how to do that.

aarf

#13 Post by aarf »

puppeee4.4rc2

Code: Select all

  # keycode 110 = BackSpace
bash: keycode: command not found
# keysym Pause = BackSpace
bash: keysym: command not found
# KeyCode 110 = BackSpace
bash: KeyCode: command not found
# Keysym Pause = BackSpace
bash: Keysym: command not found
# 
 
# xmodmap KeySym Pause = BackSpace
xmodmap: unable to open file 'KeySym' for reading
xmodmap: unable to open file 'Pause' for reading
xmodmap: unable to open file '=' for reading
xmodmap: unable to open file 'BackSpace' for reading
xmodmap: 4 errors encountered, aborting.
#
this command is helpful:

Code: Select all

# xmodmap -pk
xev isnt as simpe because the pause/break key is set to open a calenda.

file in attached image cant be opened with geany.
it is not clear what needs to be done.
Attachments
xo.jpg
(21.4 KiB) Downloaded 1367 times

User avatar
Dougal
Posts: 2502
Joined: Wed 19 Oct 2005, 13:06
Location: Hell more grotesque than any medieval woodcut

#14 Post by Dougal »

aarf wrote:puppeee4.4rc2

Code: Select all

  # keycode 110 = BackSpace
bash: keycode: command not found
# keysym Pause = BackSpace
bash: keysym: command not found
# KeyCode 110 = BackSpace
bash: KeyCode: command not found
# Keysym Pause = BackSpace
bash: Keysym: command not found
# 
that is supposed to go in .Xmodmap, which is then used in a line like

Code: Select all

xmodmap ~/.Xmodmap
in .xinitrc.
# xmodmap KeySym Pause = BackSpace
xmodmap: unable to open file 'KeySym' for reading
xmodmap: unable to open file 'Pause' for reading
xmodmap: unable to open file '=' for reading
xmodmap: unable to open file 'BackSpace' for reading
xmodmap: 4 errors encountered, aborting.
#
To execute an expression you need to use

Code: Select all

xmodmap -e "KeySym Pause = BackSpace"
What's the ugliest part of your body?
Some say your nose
Some say your toes
But I think it's your mind

aarf

#15 Post by aarf »

puppeee4.4rc2

Code: Select all

  # xmodmap -e "KeySym Pause = BackSpace"
xmodmap:  unknown command on line commandline:1
xmodmap:  1 error encountered, aborting.
 
# xmodmap -e "Keysym Pause = BackSpace"
xmodmap:  unknown command on line commandline:1
xmodmap:  1 error encountered, aborting.

# xmodmap -e "keycode 110 = BackSpace"
#
# xmodmap -e "keysym Pause = BackSpace"
# 
testing pause /break immediately afer above still opens a calenda.
however

Code: Select all

# xmodmap -pk

110    	0xff08 (BackSpace)	0x0000 (NoSymbol)	0xff08 (BackSpace)	
this code changes the 110 key:

Code: Select all

# xmodmap -e "keysym Pause = BackSpace"
# 
but it doesnt backspace and doesnt hold through restart X, 110 reverts to previous.

nancy reagan
Posts: 544
Joined: Thu 22 Jan 2009, 14:20

my "z" key died

#16 Post by nancy reagan »

Hi

My z-key is dead

1. What could I type to resolve this and

2. Where - should I type it, terminal ?

Lucid 525

Sorry for being just a wannabee user.

aarf

#17 Post by aarf »

hello nancy reagan

type this

Code: Select all

# xmodmap -pk
in a terminal.

look for something like these lines

52 0x007a (z) 0x005a (Z) 0x007a (z) 0x005a (Z)

110 0xff13 (Pause) 0xff6b (Break) 0xff13 (Pause) 0xff6b (Break)
note the numbers at the beginning of the line are the numbers of the keys on your keyboard maybe different from 52 and 110.

then you have to swap the key numbers in
/etc/X11/xkb/keycodes/xfree86

then delete the wheeled icon files in /var/lib/xkb
reboot.
hopefully that will make your "pause/break" key into a z

User avatar
Dougal
Posts: 2502
Joined: Wed 19 Oct 2005, 13:06
Location: Hell more grotesque than any medieval woodcut

#18 Post by Dougal »

aarf wrote:puppeee4.4rc2

Code: Select all

  # xmodmap -e "KeySym Pause = BackSpace"
xmodmap:  unknown command on line commandline:1
xmodmap:  1 error encountered, aborting.
 
# xmodmap -e "Keysym Pause = BackSpace"
xmodmap:  unknown command on line commandline:1
xmodmap:  1 error encountered, aborting.

# xmodmap -e "keycode 110 = BackSpace"
#
# xmodmap -e "keysym Pause = BackSpace"
# 
Ok, so the capitalization was wrong...
testing pause /break immediately afer above still opens a calenda.
however

Code: Select all

# xmodmap -pk

110    	0xff08 (BackSpace)	0x0000 (NoSymbol)	0xff08 (BackSpace)	
Are there any repeated names? Maybe BackSpace twice?
this code changes the 110 key:

Code: Select all

# xmodmap -e "keysym Pause = BackSpace"
# 
but it doesnt backspace and doesnt hold through restart X, 110 reverts to previous.
Maybe you need to "unset" a different key which holds the same symbol -- for me PrtSc (111) doesn't work with "Print" because it is assigned to a different key first:

Code: Select all

 xmodmap -pk | grep Print
     92         0xff61 (Print)  0xff15 (Sys_Req)        
    111         0xff61 (Print)  0xff15 (Sys_Req)        
#

And doing it in a terminal will obviously not hold past a restart... that's why you put it into ~/.Xmodmap.
What's the ugliest part of your body?
Some say your nose
Some say your toes
But I think it's your mind

Mitchellray
Posts: 116
Joined: Mon 07 Dec 2009, 04:30

?

#19 Post by Mitchellray »

Hello,
As directed, in /etc/X11/xkb/keycodes/xfree86 I just mapped the functions I needed onto keyboard keys that were still working properly, but that I rarely if ever would use.

Then, I thought that I would need to remove the original function mappings from those borrowed keys so I # commented out the lines in /etc/X11/xkb/keycodes/xfree86 that were there for those now borrowed keys.

I did not need to modify any other file. I guess maybe the thread is now redirected to a new question that is more in depth than my original simpler one. I'm glad you were able to help me out in terms I could understand.
I did perform this in Puppeee, not Puppy if that is the difference.
Mitchellray

aarf

#20 Post by aarf »

puppeee4.4rc2 just briefly have /.Xodomap in place. altered .xinitrc .
key alterations hold through reboot in # xmodmap -pk
BUT
/etc/X11/xkb/keycodes/xfree86 remains unchanged at original. break/pause still just produce a calenda..

Post Reply