- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic to the Top
- Bookmark
- Subscribe
- Printer Friendly Page
Guide for setup Performanc e MX mouse on Linux (with KDE)
[ Edited ]
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
11-14-2010 09:13 PM - edited 11-14-2010 09:17 PM
Hi everybody,
Just for people looking for linux options with logitech mice... I have a Performance MX working fantastically on my linux box with KDE4 (kubuntu 10.10). Some interesting points:
1) All buttons are detected with last kernel... at least with
$ uname -a
Linux tuxica 2.6.35-22-generic #35-Ubuntu SMP Sat Oct 16 20:45:36 UTC 2010 x86_64 GNU/Linux
2) So, basically, you only need to map those buttons with desired actions. How to know with button is pressed and the correspondent numeric code? Well, you can use the 'xev' program:
$ xev
This program is a key and mouse events sniffer. When it's running, you can see a window in which you can press mouse buttons and see if they are detected. For example, with the zoom button of the Performance MX you will see something like that:
ButtonPress event, serial 35, synthetic NO, window 0x5800001,
root 0x15a, subw 0x0, time 64521438, (84,117), root
88,144),
state 0x10, button 13, same_screen YES
that means that 13 is the code for that mouse button. You can try every mouse buttons on your hand
... for easy access, here is the map for Performance MX:
Back button: 8
Forward button: 9
Zoom button: 13
Show windows button: 10
the other buttons are well recognized and you don't need to map to actions.
3) Now, you need to install a little program to re-map mouse and keyboard inputs. The magician is 'xbindkeys' ... the easy installation is using:
$ sudo apt-get install xbindkeys
4) Once installed, you can do the magic. The idea is configure the mouse buttons to send key combinations to activate other desktop functionalities (as the matter of fact, xbindkeys can be used for execute any other program when you press a mouse button). For example, the "show windows" button is ideal for KDE's Present All Windows feature (for mac users, something similar to Expose). In KDE you can do that with Ctrl+F10 keys combination. The point is create a xbindkeys' configuration file to do the job.
5) To create the configuration file, just run the following command:
$ xbindkeys --defaults > $HOME/.xbindkeysrc
6) And we need to edit the file to specify your button's mapping:
$ kate $HOME/.xbindkeysrc
'kate' is the KDE's default plain text editor. Of course, you can use your favorite editor.
7) We need to add our button-to-key configurations. For example, I have the following:
# Back
"xte 'keydown Alt_L' 'key Left' 'keyup Alt_L'"
b:8
# Forward
"xte 'keydown Alt_L' 'key Right' 'keyup Alt_L'"
b:9
# Present desktops
"xte 'keydown Control_L' 'key F8' 'keyup Control_L'"
b:13
# Present windows
"xte 'keydown Control_L' 'key F10' 'keyup Control_L'"
b:10
8) There was a new requirement. the 'xte' program, which basically simulates user key press combinations. Install it using:
$ sudo apt-get install xte
Now, if you run on a terminal something like:
$ xte 'keydown Control_L' 'key F10' 'keyup Control_L'
that means simulate a Ctrl+F10 keypress. The idea is using xbindkeys to say: "when I press 13th mouse button, send a Ctr+F10 keyboard press using xte program to generate that"
9) And finally, you need to configure 'xbindkeys' to run automatically on system startup. Just go to System settings / Startup and Shutdown / Autostart / Add program button and type '/usr/bin/xbindkeys' on the dialog.
10) Othe tips: KDE is a very customizable environment, and you have a lot of options to configure exactly what you want. For example, if you want to map the "Zoom button" (or other on a different mouse such as RevolutionMX) with 'next desktop' action:
# Next desktop
"qdbus org.kde.kwin /KWin org.kde.KWin.nextDesktop"
b:13
(qdbus is a very powerful way to communicate with applications in KDE)
Of course, you can use this option with Gnome or any other desktop environment.
Hope this helps someone,
Hugo
EOF
Re: Guide for setup Performanc e MX mouse on Linux (with KDE)
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
12-02-2010 03:06 PM
Cool, thanks.
Unfortunately linux does not seem to recognize the full resolution that this mouse provides. Is there any way to fix that? (Ubuntu 10.04 64bit, Gnome)
Re: Guide for setup Performanc e MX mouse on Linux (with KDE)
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
03-11-2011 02:01 AM
Love you men, works perfect with Ubuntu 10.10
Re: Guide for setup Performanc e MX mouse + G700 on Linux (with KDE & Ubuntu)
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
03-11-2011 02:07 AM
My 2 cents... after you edit the $HOME/.xbindkeysrc you need to refresh the deamon, executing the /usr/bin/xbindkeys otherwise iyour mouse will not recognize the changes.
I'm currently editing my 11 buttons of my g700
Re: Guide for setup Performanc e MX mouse on Linux (with KDE)
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
04-17-2011 03:28 PM
On Kubuntu\Ubuntu work the DPI button?
Re: Guide for setup Performanc e MX mouse on Linux (with KDE)
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
06-09-2011 11:26 AM
This worked greate for Gnome 3 too with one problem. I planned on using the show windows button (button 10) as the button to launch activities. This is either Alt-F1 or the Windows button (Super_L). If I run the xte command in the terminal on its own, this works fine. Running the command through xbindkeys by way of clicking the button does not work. I ran xbindkeys --verbose to ensure that xbindkeys was doing its thing and it was. Any ideas?
Re: Guide for setup Performanc e MX mouse on Linux (with KDE)
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
07-08-2011 10:42 AM
Which, unfortunately, is the reason that I'm not buying another logitech mouse.
If the mouse had memory at least, you could set the resolution and move the mouse to your linux box, but no - it's all done in [closed] driver. The MX Revolution I had before this? You can set which button changes to free scroll, this doesn't change between boxes (but tbh, it can be changed using something like revoco in linux).
BAH to Logitech. They make great mice and in the Windows world, everything is grand. If they at least opened the source of their drivers (even a bit), then someone would build a fully functional driver for them, but no - they are apparently not interested in that.
Re: Guide for setup Performanc e MX mouse on Linux (with KDE)
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
07-10-2011 11:45 AM
G700 has memory and I am able to keep the dpi settings from a windows setpoint build then use the button macro'ing explained above on my lucid 64-bit linux machine.. works great ( I still am hoping logitech will actually make a set point for linux)
Re: Guide for setup Performanc e MX mouse on Linux (with KDE)
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
02-27-2012 10:00 AM
The 'xte' package is called 'xautomation'.
I'm finding that i need to kill and restart the xbindkeys tool each time I make a change, although the man page says it'll monitor the local configuration file for changes.
Re: Guide for setup Performanc e MX mouse on Linux (with KDE)
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
03-05-2012 02:10 PM
I wasn't able to FIND xte ... tried a google search and it matched on KATE!!
I AM using Ubuntu 10.10 Gnome - NOT KDE.
