LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Laptop and Netbook
User Name
Password
Linux - Laptop and Netbook Having a problem installing or configuring Linux on your laptop? Need help running Linux on your netbook? This forum is for you. This forum is for any topics relating to Linux and either traditional laptops or netbooks (such as the Asus EEE PC, Everex CloudBook or MSI Wind).

Notices

Reply
 
Search this Thread
Old 08-29-2006, 04:35 AM   #1
odcheck
Member
 
Registered: Aug 2006
Distribution: Fedora, CentOS, RHEL, Debian
Posts: 978

Rep: Reputation: 30
HowTo Dell Lat.D410, DX10 Fn-Keys working?


Hi to All I've checked google , and other Forums and I tried to offer a lot of people in this forum my help before I decided to ask THIS question for me and all other Dell Notebook Users.

I am running FedoraCore 5 on a Latitude D410.
Using KDE Desktop. But I also want to know for GNOME Users
mostly regarding those Volume things.


FN+F2 work out of the Box (Wireless Devices on/off)
FN+Up and Down for Brightness works also Out of the Box
FN+ALT+F12 (to get PRINTSCREEN) works also Out of the Box
FN+F8 works also out of the BOX (some adjustments regarding the 2nd Monitor in xorg.conf but no config needed regarding the button)
FN+F4 for NUM


I want the following keys be recognized and I need someday who tells us (me ...) you to bind them to a file, script, application whatever.
fn+pageup (increase volume)
fn+pagedown (decrease volume)
fn+end (mute)
fn+esc (standby)
fn+f1 (hibernation)
fn+f5 (scroll lock)

I tried xbindkeys, linEAK, acme but nothing really works or I am to stupid to adjust or use them correctly.
Also the command xev didn't give me a clue. If I start xev must a single press only on fn already give an output? It doesn't. fn+f1 only recognized F1 same with the other combinations.

Maybe someone out there has got a clue on how to setup this keys.
I don't need the answer to the suspend scripts but they are also welcome

So feel free to answer or join this Thread
 
Old 08-29-2006, 05:45 AM   #2
odcheck
Member
 
Registered: Aug 2006
Distribution: Fedora, CentOS, RHEL, Debian
Posts: 978

Original Poster
Rep: Reputation: 30
Already 8 Views but no hints.
In New York it must be something around 6am.

:-)
 
Old 08-29-2006, 04:26 PM   #3
zetabill
Member
 
Registered: Oct 2005
Location: Rhode Island, USA
Distribution: Slackware, Xubuntu
Posts: 348

Rep: Reputation: 30
I have a Dell Inspiron 8200 and I've been trying to tackle this problem recently. I've tried xbindkeys and now that you've mentioned it I'm going to give linEAK a shot because I haven't gotten very far. Your key definitions are a little different and more modern than mine but the concept, fortunately, is the same.
Quote:
Originally Posted by odcheck
FN+F2 work out of the Box (Wireless Devices on/off)
FN+Up and Down for Brightness works also Out of the Box
FN+ALT+F12 (to get PRINTSCREEN) works also Out of the Box
FN+F8 works also out of the BOX (some adjustments regarding the 2nd Monitor in xorg.conf but no config needed regarding the button)
FN+F4 for NUM
Luckily the BIOS takes care of these so you shouldn't ever have to worry about them.
Quote:
Originally Posted by odcheck
I want the following keys be recognized and I need someday who tells us (me ...) you to bind them to a file, script, application whatever.
fn+pageup (increase volume)
fn+pagedown (decrease volume)
fn+end (mute)
fn+esc (standby)
fn+f1 (hibernation)
fn+f5 (scroll lock)
There seems to be such an incredible amount of knowledge on this out there yet, like you, I haven't been able to get them to work. If you haven't already found it try the Gentoo HowTo Use Multimedia Keys. Obviously this isn't for your distro but it does the best job on playing with .Xmodmap, xev, and setkeycodes. It tells you how to recognize the xev output and map keycodes to those buttons.

Me personally I've got to the point where those function combos and the media buttons generate a keycode but I cannot get them to correspond to a command. I, too, hope someone out there can help to get them to work in X. I have done hours of google searching and a bunch of trial and error but none of it actually gets the damn volume to go up and down, suspend the system, etc. etc.

At least the computer recognizes the buttons... hopefully they can actually do something!

Good luck... and post back if you get somewhere with it. I will, too.
 
Old 08-30-2006, 05:13 AM   #4
odcheck
Member
 
Registered: Aug 2006
Distribution: Fedora, CentOS, RHEL, Debian
Posts: 978

Original Poster
Rep: Reputation: 30
okay If you're using a Latitude D410, D510, D610, D810 or Precission M60
I've got a fix for KDE using the Volume Keys on the Panel of the keyboard where the power button considers.
you'll need this Xmodmap in your homedir
It will look like ~/.Xmodmap (if the file doesn't exist you've to create it. I had..)
----------------------------------------------------
! Volume Up
keycode 176=F20
! Volume Down
keycode 174=F21
! Mute
keycode 160=F22
----------------------------------------------------
Then you open KMIXER and you simply adjust your KMIXER Global Shortcut Settings.
Just select Volume Up and then click on user define only with pressing the buttons decribed above it automaticly puts F20 in this Field. Do the rest with Volume Down and Mute. It works directly!
!!! If your .Xmodmap is not executed on startup you have to do this:
Here is how you get it loaded automatically:
You've got to open
$KDEDIR/share/config/kdm/Xsession

and insert the following code at the beginning of the file (but after the shebang #!/bin/sh):

if [ -f $HOME/.Xmodmap ]; then
/usr/X11R6/bin/xmodmap $HOME/.Xmodmap
fi
----------------------------------------------------------------------------

I still work on it and I will never surrender! RUN TO THE HILLS
 
Old 08-30-2006, 10:35 PM   #5
zetabill
Member
 
Registered: Oct 2005
Location: Rhode Island, USA
Distribution: Slackware, Xubuntu
Posts: 348

Rep: Reputation: 30
Quote:
Originally Posted by odcheck
! Volume Up
keycode 176=F20
! Volume Down
keycode 174=F21
! Mute
keycode 160=F22
Fantastic.

Just to let you know I know exactly why I couldn't get it to work.

I highlighted odcheck's syntax of what he needed to put in .Xmodmap. I'm so used to the average everyday bash syntax that I was commenting my file with hashes (#). Apparently X doesn't recognize it for that function and if you want to put comments in your file you have to use the bang (!) instead.

And that is the only reason why I couldn't get it to work. I deleted those comments and it worked fine.

Also... just of note to Slackware users. A similar implimentation of this code:
Quote:
Originally Posted by odcheck
Code:
if [ -f $HOME/.Xmodmap ]; then
/usr/X11R6/bin/xmodmap $HOME/.Xmodmap
fi
is located in the .xinitrc file in the home directory. It is ALSO located in the global .Xsession file. There is no .xsession file to put that code into in the home directory. So just make sure that the $KDEDIR/share/config/kdm/Xsession and the ~/.xinitrc file has that xmodmap call in it before going through more trouble than is needed making extra files. Pat was very kind in modifying the generic X setup to take this into account for us.

There is also a /usr/X11R6/lib/X11/xinit/.Xmodmap file that gets loaded when X starts so if you want to set this up globally for extra users then that's the .Xmodmap file to which you want to put those keycode definitions. This should be good for all distros.

Enjoy Linux everyone!
 
Old 08-31-2006, 01:39 AM   #6
odcheck
Member
 
Registered: Aug 2006
Distribution: Fedora, CentOS, RHEL, Debian
Posts: 978

Original Poster
Rep: Reputation: 30
Great INPUT zetabill !!!!
And maybe anybody can tell me how to get the keycode for "fn" ?
I am working on it. xev doesn't recognize it.
Somebody told that it's maybe recognized by acpi event? But how can I grep that?
You know what is strange? For example in order to make a screenshot on such a Dell System you'll have to press fn+F11(PrintScreen) in this case fn must be recognized
like fn+F2 so with the correct cubbi kernel and a good working hibernation script
should it be possible to get the fn+F1 working! All the F1-F12 have got keycodes but I don't know how to set them together in conjuction with fn?
Let's all have a look at what xev shows regarding the example of PrintScreen:

This is if fn+F11 is pressed:


KeymapNotify event, serial 31, synthetic NO, window 0x0,
keys: 2 0 0 0 0 0 0 0 0 0 0 0 0 4294967168 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0

KeyRelease event, serial 31, synthetic NO, window 0x2200001,
root 0x4c, subw 0x0, time 1659790257, (-357,389), root317,418),
state 0x0, keycode 111 (keysym 0xff61, Print), same_screen YES,
XLookupString gives 0 bytes:

FocusOut event, serial 31, synthetic NO, window 0x2200001,
mode NotifyNormal, detail Notif

This is when only F11 is pressed:

KeyPress event, serial 31, synthetic NO, window 0x2200001,
root 0x4c, subw 0x0, time 1659556654, (-177,425), root497,454),
state 0x0, keycode 95 (keysym 0xffc8, F11), same_screen YES,
XLookupString gives 0 bytes:
XmbLookupString gives 0 bytes:
XFilterEvent returns: False

So is it just keycode 111 for the fn+F11 thing?
---------
But when I tried fn+F1 nothing "really" happens... once something happend
keycode 67 was printed and the time within this output starts to run very quickly and didn't stop until I stopped it using CRTL+C.
But Keycode 67 is only F1 you can see this if you run xmodmap -pke
 
Old 08-31-2006, 02:17 AM   #7
zetabill
Member
 
Registered: Oct 2005
Location: Rhode Island, USA
Distribution: Slackware, Xubuntu
Posts: 348

Rep: Reputation: 30
The fn button itself isn't recognized by anything but ACPI (or the BIOS in my case). So it doesn't really matter. If you did an xev for a and then A (shift+a), you would get two different keycodes. It's simply a modifier key. What's important isn't what fn registers, but what is registered when fn is complimented to some other key.

Here's the deal. With these "special" keyboards that laptops have, buttons other than what is normally on an average keyboard have uncommon scancodes. The scancodes for these odd buttons generally come from either the BIOS or ACPI and are picked up by specialized software. That's why it works so wonderfully in Windows.

Example: In order for my kernel to even recognize that my volume buttons were sending a scancode, I had to compile a module for my kernel made to recognize events for the Inspiron 8000 series. My 8200 has problems with the IrDA port button so I just ignore it... but the scancodes for the buttons weren't even registering in dmesg until compiled that module.

To answer your question, the keycode 111 is the combination of fn+F11. Once that function button is used the keycodes come from ACPI alone. The kernel knows that it's a scancode so now you can assign that scancode to a keycode and so on. When you did fn+F1 it didn't register with the kernel because the kernel most likely has no idea the event that just passed was a scancode and ignored it. What you'll need is a kernel module that will allow the kernel to recognize the scancode ACPI offers when that function is called. Once you can get the kernel to recognize all the scancodes your keyboard has, then you can go about with the keycodes assignments, etc.

Good luck with that one though. I have not found anything for an 8200 but then again the 8000 series was relatively short lived about 4 years ago. You will probably have a much better chance at finding a module for your hardware that I will.

Good luck and may this be helpful to everyone.
 
Old 08-31-2006, 02:23 AM   #8
odcheck
Member
 
Registered: Aug 2006
Distribution: Fedora, CentOS, RHEL, Debian
Posts: 978

Original Poster
Rep: Reputation: 30
Thanks zetabill, for your models Inspirion 8000 and 8100 you can use everything from the Latitude C800 and C810, Inspirion 8200 is Latitude C840 the only diffrents are in the most cases the Video Card. I know that cause I've worked there, before the moved to the east of germany.
 
  


Reply

Tags
control, d510, d610, dell, fn, hibernate, keys, latitude, suspend, volume


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
GRUB Error 18 on a Dell Lat D600 Zen_71 Suse/Novell 1 06-06-2006 08:23 AM
problem : suspend to ram on Dock - d410 dell Vince-ubuntu Linux - Laptop and Netbook 0 04-18-2006 02:47 PM
ALSA with Dell Lat CPi-D266XT phekno Linux - Laptop and Netbook 14 01-24-2006 03:05 PM
Dell D600 lat having monitor issues..help hypnotiks Linux - Laptop and Netbook 1 08-23-2005 05:43 PM
howto enable win keys for mandrake spikeyklitske Linux - Software 0 10-31-2004 06:40 AM


All times are GMT -5. The time now is 06:58 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration