New Posts  All Forums:Forum Nav:

lineak

post #1 of 10
Thread Starter 
I've seen numerous references to the use of lineak to get the "multimedia" keys to work. Can someone here post his lineakd.conf file or something? I don't know which keyboard to choose from among the list and, therefore, can't seem to get things to work.

I'm running RH 9 on a 5660.

If I have one complaint about these laptops, it's the lack of a manual volume control that doesn't require a software interface. I hate having to adjust my volume with a mouse.

Anyway, any help appreciated. Thanks!
post #2 of 10
here are my files.

/etc/lineakkb.def, with the irrelevant portions snipped:
<snip>
[Sager]
brandname = "Sager"
modelname = "NP8887"
[KEYS]
email = 236
www = 178
user = 129
back = 144
forward = 153
play = 162
stop = 164
volumeup = 176
volumedown = 174
[END KEYS]
[END Sager]
<snip>


~/.lineak/lineakd.conf:
# LinEAK - Linux support for Easy Access and Internet Keyboards
# Copyright (c) 2001,2002 Mark Smulders <Mark@PIRnet.nl>
# http://lineak.sourceforge.net
#
# lineakd configuration file
#
# example key configuration:
# play= "xmms --play-pause"
# eject= EAK_EJECT
#
# available special actions:
# EAK_EJECT
# EAK_VOLUP
# EAK_VOLDOWN
# EAK_MUTE
# EAK_SLEEP
#

# LinEAK Configuration file for Sager NP8887

# Global settings
KeyboardType= Sager
CdromDevice= /dev/cdrom
MixerDevice= /dev/mixer

# Specific keys of your keyboard
email= "sylpheed-claws"
www= "links2 -g"
user= "bashish"
back= "xmms --rew"
forward= "xmms --fwd"
play= "xmms --play-pause"
stop= "xmms --stop"
volumeup= EAK_VOLUP
volumedown= EAK_VOLDOWN

# end lineakd.conf


and in .xinitrc:
exec lineakd -b &


you have to add the sager section in lineakkb.def yourself. mine is under the 'laptops' section of the file, but technically it doesn't matter. those numbers are X event numbers - but they may be different from mine on a 5660. it's better to test them yourself. run 'xev' and press each of the buttons, noting the event numbers for each button, and use those in lineakkb.def. (naturally, change model to NP5660, etc.)

let me know if you have any problems.
post #3 of 10
Thread Starter 
Quote:
Originally posted by xiphux
here are my files.
First, thanks! This helped me figure out the root of my problem.

Originally, I couldn't - and get - get klineakconfig to run. When I run lineakconfig and try to say, it complains about the lineakd not running.
When I RUN the lineakd by hand - it runs (according to ps), but lineakconfig fails with a "can't detext lineakd" error.

I then tried to use xev - didn't think of that - in lieu of klineakconfig and it locks up my keyboard (literally just my keyboard) whenever I run it. I have to logout (can't type to kill X) and everything returns to normal.

Thoughts? Thanks again!
post #4 of 10
Thread Starter 
Update to my own note:

I was playing with xmms and the iTouch keyboard control plugin under general. It turns out that it's got a "grab" feature for the keyboard which works like xev. It would appear that the keycombos are the same, at least for the vol up/down switches. It's nice to see THAT work.

However, when I ENABLE the plugin, my keyboard stops working once I use the volume keys. That is, I enable it, get to work, turn down xmms from the front of my laptop, and then my keys stop working. If I disable on the fly, my keys start working again.

Note that turning xmms up and down isn't as nice as turning my MIXER up and down, which is what I want to do :-)

Thanks.
post #5 of 10
i didn't use any of the lineak config programs, i just edited the file by hand. (lineakconfig just edits ~/.lineak/lineakd.conf)

somehow, i don't think the iTouch plugin will work without an iTouch keyboard. with lineakd running, xmms shouldn't even need any plugin.

the EAK_VOLUP and EAK_VOLDOWN functions control the mixer, which (i believe) is what you want. (control the master volume, right? it works for me)

that sucks that xev freezes, i wonder why that happens. maybe check the X log?

if the volume buttons are the same x events as mine, then the rest of the buttons are probably the same, too. try text editing your lineak config files to look like mine (well, the keyboard definition - map the buttons to the commands you want), and running just 'lineakd -v' in a console and testing, and check if there are any messages. (skip the -b flag, which means background. -v for verbose)

... or did i miss something, and did running lineakd configured cause problems for you?
post #6 of 10
Thread Starter 
Quote:
Originally posted by xiphux
i didn't use any of the lineak config programs, i just edited the file by hand. (lineakconfig just edits ~/.lineak/lineakd.conf)
...yes, but that was how I realized something is up with lineakd :-) Actually, it must also restart the daemon.

Quote:
somehow, i don't think the iTouch plugin will work without an iTouch keyboard. with lineakd running, xmms shouldn't even need any plugin.
You're right on both counts - I just thought it was nice that it had a keyboard grabber!


Quote:
...running just 'lineakd -v' in a console and testing, and check if there are any messages. (skip the -b flag, which means background. -v for verbose)
[/b]
OK, here's where it's at. I had already just copied your kb def into place with my adjusted definitions, assuming that they were similar enough to get something. Running lineakd -b dies (an & returns after a few seconds having executed it - which is fine with the -b, right? - but the daemon doesn't persist).

When I run lineakd -v, I get:

CD-ROM init, using /dev/cdrom as the CD-ROM device
Sound init, using /dev/mixer as the mixer device
... master volume stored
Xkb map change done for keycode 144
Xkb map change done for keycode 236
Xkb map change done for keycode 153
Xkb map change done for keycode 162
Xkb map change done for keycode 164
Xkb map change done for keycode 129
Xkb map change done for keycode 174
Xkb map change done for keycode 176
Xkb map change done for keycode 178


Which seems right. NOW, for the first time, if I hit the volDOWN button, the volume goes down and lineakd reports a nice message. However...I can't then volUP *and* my keyboard locks up again. Grrrrr....

I've cleaned up my kkb.def file to have only the play/stop/vol keys defined, still no luck.

Thanks!
post #7 of 10
hmm... what version of lineak are you using?

flipping through the lineak documentation, i found a couple things you could try:

first of all, get rid of your ~/.lineak/lineakd.conf. (you can always create it again later.)

try running 'lineakd -l' and see if it lists the keyboard definition you created. then do 'lineakd -c blah', with blah being the keyboard identifier, to generate a config file. then do 'lineakd -v' and press the buttons. if it reports keycodes/presses correctly, then we know that the problem is not incorrect keycodes, and it's something with the commands for the buttons.

if keycodes are not correctly reported for the buttons you want, try running 'lineakd -c CIK18g'. (what we're trying to do is set up lineakd with a keyboard that has a _lot_ of keys - like the CIK18g. This high number of keys could possibly include yours.) run lineakd in verbose mode, press the buttons, and see if x keycodes are reported. if not, try switching to another keyboard that has lots of keys. (This is, however, not the real way to do it - therefore, it may very well not work at all)

let me know how that works out - if we clear up whether it's the keycode definitions or not, we can decide where to go from there.
post #8 of 10
Thread Starter 
Quote:
Originally posted by xiphux
hmm... what version of lineak are you using?
LinEAK v0.6-alpha2

I'm beginning to wonder whether I ought to downgrade or something.

Quote:
[i]
try running 'lineakd -l' and see if it lists the keyboard definition you created. then do 'lineakd -c blah', with blah being the keyboard identifier, to generate a config file. then do 'lineakd -v' and press the buttons. if it reports keycodes/presses correctly, then we know that the problem is not incorrect keycodes, and it's something with the commands for the buttons.
[/b]
OK, here's what I've learned:

lineakd -l lists the kb I created.

lineakd -c creates a file the way one would expect.

lineakd -v (and lineak) does the following:

Once I run it, if I hit EITHER my volup or voldown buttons, lineak reports the proper button being pressed and the volume goes up/down accordingly.

HOWEVER, I can no longer press any other key on my keyboard. ONLY the key I press first will work. My mouse works fine, so I just have to log out that route and then I'm OK.

I haven't logged into the machine remotely to see what's running, happening, or to try to kill a process, I may do that next.

Thanks!
post #9 of 10
that's really strange...

... but somehow, that 'alpha' in the version number makes me a little suspicious. alpha is probably the least stable version label there is. (besides CVS)

i use lineak v0.4pre3, i don't know if you want to give that one a try or not...
post #10 of 10
Thread Starter 
Quote:
Originally posted by xiphux
that's really strange...

... but somehow, that 'alpha' in the version number makes me a little suspicious. alpha is probably the least stable version label there is. (besides CVS)

i use lineak v0.4pre3, i don't know if you want to give that one a try or not...
Yeah, I grabbed the alpha from the lineak site because it's their "recommended" version.

I just installed the 4pre version myself - same problem. Time to pester those guys, I guess.

Thanks for all your help.
New Posts  All Forums:Forum Nav:
  Return Home
  Back to Forum: Linux & Other OS's