vBulletin Search Engine Optimization
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Okay, so I recently got one of those new keyboards that has all sorts of weird proprietary extra keys on it, marked with things on them like "e-mail" and "favorites" and so on. With the vendor- supplied driver, these do things in Windows, but of course they don't do anything with the generic keyboard driver for linux. I know that in theory I can figure out what the key codes are that are sent when I press them. The question I have is, does there exist some sort of method in linux for watching the keyboard globally, and reacting to certain keycodes with global actions I can define arbitrarily? What would be nice would be something crontab-like. "If you see this particular keycode, then run this command. If you see that keycode, then run that command." something like: (These are made-up keycodes - not the real thing) 000 120 /usr/local/bin/mozilla # Web Browser button 000 121 /usr/local/bin/soffice # Office button 001 150 aumix -v + # volume-up button 001 151 aumix -v - # volume-down button ...etc.. Does such a thing exist already? I'd RTFM, but I don't know where to FTFM on this one. |
| |||
| In comp.os.linux.setup, Steve Mading uttered these immortal words: > Okay, so I recently got one of those new keyboards that has all > sorts of weird proprietary extra keys on it, marked with things > on them like "e-mail" and "favorites" and so on. With the vendor- > supplied driver, these do things in Windows, but of course they > don't do anything with the generic keyboard driver for linux. If you use KDE and it supports your keyboard, the easiest way is to set up KHotkeys. > I > know that in theory I can figure out what the key codes are that are > sent when I press them. xev will tell you. > The question I have is, does there exist > some sort of method in linux for watching the keyboard globally, > and reacting to certain keycodes with global actions I can define > arbitrarily? IIRC xbindkeys (http://hocwp.free.fr/xbindkeys/xbindkeys.html) will help here. Since KDE introduced KHotkeys I haven't had to use xbindkeys any more. > Does such a thing exist already? I'd RTFM, but I don't know where > to FTFM on this one. Assuming xbindkeys is what you're looking for you now know which FM to R. ;-) -- Andy. |
| |||
| On Thu, 13 Jan 2005 23:32:19 +0000, Andy Fraser <andyfraser31@hotmail.com> wrote: > >Assuming xbindkeys is what you're looking for you now know which FM to >R. ;-) Thanks. Your post was helpful. I'll be playing with this later tonight. |
| |||
| Steve Mading wrote: > > Okay, so I recently got one of those new keyboards that has all > sorts of weird proprietary extra keys on it, marked with things > on them like "e-mail" and "favorites" and so on. With the vendor- > supplied driver, these do things in Windows, but of course they > don't do anything with the generic keyboard driver for linux. I > know that in theory I can figure out what the key codes are that are > sent when I press them. The question I have is, does there exist > some sort of method in linux for watching the keyboard globally, > and reacting to certain keycodes with global actions I can define > arbitrarily? Yes. I see Andy Fraser has given you some ideas on how to do this in X-windows (something I know nothing about) so I'll tell you what to look at if you want to do this at the console. man showkeys man dumpkeys man loadkeys man keymaps Gord Torrie ----== Posted via Newsfeeds.Com - Unlimited-Uncensored-Secure Usenet News==---- http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+ Newsgroups ----= East and West-Coast Server Farms - Total Privacy via Encryption =---- |
| |||
| In comp.os.linux.setup, Steve Mading uttered these immortal words: >>Assuming xbindkeys is what you're looking for you now know which FM to >>R. ;-) > > Thanks. Your post was helpful. I'll be playing with this later tonight. I've just stumbled upon my old .xbindkeysrc file so that was what I used to use. :-) -- Andy. |
| |||
| Steve Mading wrote: > Okay, so I recently got one of those new keyboards that has all > sorts of weird proprietary extra keys on it, marked with things > on them like "e-mail" and "favorites" and so on. With the vendor- http://lineak.sourceforge.net/ .... PERIOD (.) -- << http://michaeljtobler.homelinux.com/ >> Millihelen, adj: The amount of beauty required to launch one ship. |
| |||
| On Thu, 13 Jan 2005 21:49:41 -0500, Gordon Torrie <who@where.why> wrote: >Steve Mading wrote: >> >> Okay, so I recently got one of those new keyboards that has all >> sorts of weird proprietary extra keys on it, marked with things >> on them like "e-mail" and "favorites" and so on. With the vendor- >> supplied driver, these do things in Windows, but of course they >> don't do anything with the generic keyboard driver for linux. I >> know that in theory I can figure out what the key codes are that are >> sent when I press them. The question I have is, does there exist >> some sort of method in linux for watching the keyboard globally, >> and reacting to certain keycodes with global actions I can define >> arbitrarily? > >Yes. >I see Andy Fraser has given you some ideas on how to do this in >X-windows (something I know nothing about) so I'll tell you what >to look at if you want to do this at the console. > >man showkeys >man dumpkeys >man loadkeys >man keymaps Is there a way that works regardless of whether it's console or X? Something a bit more low-level perhaps? (By the way, thanks for the info.) |
| ||||
| Steve Mading wrote: > Is there a way that works regardless of whether it's console or X? > Something a bit more low-level perhaps? > > (By the way, thanks for the info.) Yes in theory, possibly in practice. Many years ago my employer purchased some Key Tronic KB 3270 Plus keyboards. These keyboards are programmable. A MS-DOS program, supplied with the keyboard (and available from Key Tonic's web site, I have just now checked) was used to program the keys with any character or character string one wished. In my employer's case, various accented characters and commonly used typesetting commands were stored onto the keys. Subsequently, my employer was sold to another company who had a different method of typesetting and threw out the existing keyboards and computers. This is how I obtained them. I thought I would use these keyboards with my, then new, Pentium class computer running Windows 98. Well, the keyboard works with the default key layout and the MS-DOS program runs in a DOS window *but* the program did not communicate with the keyboard After a call to Key Tronic's technical support I learned that the keyboard interface used on the motherboard had changed from that which was used on 80386 motherboards and this is what prevented the program from communicating with the keyboard. Worse, the new style interface did not have a way for the computer to send data to the keyboard. Possibly this situation has changed again and perhaps a call to Key Tronic or other keyboard manufacturer would be worthwhile. And before you ask. No, you can't plug the keyboard into a 80386 machine, program the keyboard then disconnect it and plug it into a Pentium machine. Well, you can, but the keyboard reverts to the default layout when you disconnect it from the 80386. Gord Torrie ----== Posted via Newsfeeds.Com - Unlimited-Uncensored-Secure Usenet News==---- http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+ Newsgroups ----= East and West-Coast Server Farms - Total Privacy via Encryption =---- |