Jump to content

Multimedia keys [solved]


josk
 Share

Recommended Posts

Hi,

 

I need help to add actions to my multimedia keys. I installed XEV keymapping tool and get following information:

 

volume+ (keycode 176) (no keysym)

mute (keycode 160) (no keysym)

volume- (keycode 174) (no keysym)

media (keycode 129) (no keysym)

stop (keycode 164) (no keysym)

rev (keycode 144) (no keysym)

forw (keycode 153) (no keysym)

play/pause (keycode 144) (no keysym)

 

I dont want add actions like STOP PLAYING.... I just want to add that it works same as putting some alphabetical character like A or B. Thats cause I will teach those keys to work with VDR (video disc recorder) software.

 

Question is: How I add keysym to the those keys? Keysym should be just normal alphabetical character like A or B.

 

-josk, FIN

Link to comment
Share on other sites

Ok! I solved it. I just have to make following file:

 

homedirectory/.kde/Autostart/keycodes

# BEGIN

#!/bin/sh

#This is the file that is going to map my special keys.

#File location: ~/.kde/Autostart

#File Name:keycodes

#This file wil run automatically each time you restart KDE. It assigns a

#keysym to a given keycode

 

 

xmodmap -e 'keycode 176=Prior' #Page Up

xmodmap -e 'keycode 160=BackSpace' #BackSpace

xmodmap -e 'keycode 174=Next' #Page Down

xmodmap -e 'keycode 129=m' #m letter

xmodmap -e 'keycode 164=Up' #Up

xmodmap -e 'keycode 162=Down' #Down

xmodmap -e 'keycode 153=Right' #Right

xmodmap -e 'keycode 144=Left' #Left

# END

and give it permission to execute. Now everything works like it should be!

Edited by josk
Link to comment
Share on other sites

  • 3 months later...

Hello, I have a problem with buttons keys in my laptop (Compaq Armada 1750), because I cant solve asign four keys in gnome (Mandriva 2005).

I´ve made the kernel asignation (dicover with dmesg, asign with setkeycodes , and permanent with file in /etc/rc.local, and I can make the X asignation (discover with xev, asign with xmodmap and gnome shorcut keyboard configuration)

 

But my problem is how to make this last (xmodmap) permanent.

I have tried:

- .Xmodmap file in $HOME

- .xsession in %HOME calling xmodmap with .Xmodmap file

- buttons.sh calling xmodmap and configured in gnome-session to launch on starting gnome session

- modifing fixkeyboard file in /etc/X11/xinit/

- modifing xsession in /etc/X11/ and in /etc/X11/gdm

- modifing xsession in /etc/X11/ and in /etc/X11

- shell script file calling xmodmap in /etc/X11/gmd/Postloging

- shell script file calling xmodmap in /etc/X11/xinit.rc/

- ... and mutch more that I cant remenber

 

 

Could enybody tell me how I can call xmodmap at loging to get work the multimedia keys asignment work automatically in gnome?

 

Thanks in advance. Im little desesperated.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...