Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I have a Logitech MX5500 mouse and keyboard combo. When I press down on the mouse wheel it releases the scroll clicker and allows the wheel to spin freely. Clicking down again on the mouse wheel turns freespin off and relocks the wheel or causes it to click with every scroll.

Back when I used to use Windows, the Logitech drivers installed a piece of software that allowed me to easily select key bindings, customize display settings on the keyboard (which I've never even looked at and know nothing about; I don't even really use the keyboard) and MOST IMPORTANTLY an option to toggle between treating the middle mouse button as MOUSE3 or as a toggle between free spin and click-scrolling.

I believe this software is call Logitech SetPoint. Normally you would choose to set the binding on the mouse wheel and change it from 'Shift scroll modes' to 'Middle Button' but Logitech doesn't provide any Linux support. Upon doing some research I discovered a piece of software called HIDPoint designed to emulate SetPoint for Linux systems but it seems to have not been updated or supported in the last couple years as it lists the latest supported version of Ubuntu as 10.10. I tried to install it was but not successful. From what I can tell it looks like this project has been abandoned. Such a shame considering how useful it would be.

I couldn't find any online documentation regarding this issue however I did find some about setting custom mouse bindings. One guide using imwheel outlined here:

https://help.ubuntu.com/community/ManyButtonsMouseHowto

was kind of confusing regarding how I would be able to know which commands carried out which tasks. Also I got errors trying to run imwheel.

This guide made a little more sense:

How to configure extra buttons in Logitech Mouse

and I was able to use it to figure out my mouse bindings but I was again at a loss for how to figure out what commands or scripts to bind to which key.

=========================================

On a side note

=========================================

Is there an application similar to xev that displays a command output for an action done? This way someone could obtain the action they want to bind to a script as easily as the mouse binding.

For example: using xev I click each button on my mouse to see which binding it has. If I want to bind a mouse button to ctrl I would add:

"xte 'key Control_L'" b:1

to my .xbindkeysrc file or if I wanted to bind a key to switch workplaces (in KDE, copied from another tutorial) I would add:

"qdbus org.kde.kwin /KWin org.kde.KWin.previousDesktop"

b:6

"qdbus org.kde.kwin /KWin org.kde.KWin.nextDesktop"

b:7

but the people who wrote those tutorials knew those commands or were able to figure them out in some way. Say b:6 and b:7 are my forward and backward mouse buttons and I wanted to bind them to previous track and next track in VLC. Is there a program like xev where I could have it running and then with VLC open, when I press the next button in VLC it outputs a command to the terminal that was delivered to VLC? That way one could copy the command from the terminal to .xbindkeysrc

So far as I can tell, the best solution alluded to here:

http://blog.hanschen.org/2009/10/13/mouse-shortcuts-with-xbindkeys/

Is to set up a keyboard shortcut in whatever program you want to use and then bind a mouse button to a combination of keyboard keys. Is this the best working solution for people who are doing custom mouse bindings?

There seems to be very little interest and support for custom mouse bindings in Linux and Ubuntu which seems especially weird to me. I would think this to be a much more popular issue which leads me to believe there is some sort of documentation surrounding this that I haven't seen that clarifies everything or makes everything easier.

As of right now, I understand how to set custom mouse bindings but have no idea how one would figure out what to bind the mouse button to. The Logitech SetPoint software made this as easy as selecting buttons then selecting applications and specific functions (like media player > next track or media player > previous track for the previously mentioned track skipping in VLC).

=====================================

End of side note

=====================================

Sadly this whole key binding thing doesn't even help me any closer to solving my issue because clicking on my mouse wheel in xev returns absolutely no output. All the other buttons give output along with moving the mouse or the wheels. Wheel up is registering button 4 and wheel down button 5 but clicking on the wheel just switches the scrolling mode but doesn't do anything in xev.

So I thought I might be able to find the command for mouse3 or middle click and bind that to... b:3 (I guess?) but I imagine that might not even work since I don't have a mouse binding for my mouse wheel.

I remember when I first install Ubuntu 12.10 from Windows 7, I had the mouse drivers installed in windows 7 and set the mouse wheel binding to the middle button. I then erased windows 7 and installed Ubuntu 12.10 and the mouse was the same. After a re-installation of 12.10 (or it may have been an upgrade to 13.04) my mouse wheel went back to switching scroll modes. Every subsequent installation has resulted in the same configuration and I have not been able to resolve it since.

My computer knowledge tells me this has something to do with some read-only memory in the mouse itself i.e., a switch that gets turned on/off by a command from the computer. I imagine the switch was turned off by the drivers in windows (turning the wheel back to a middle click as opposed to a scroll mode switcher) and maybe reset at some point during a Ubuntu installation. I guess I would be looking for some sort of command to send a message to the mouse to flip the switch?

Any help would be appreciated. I'm not really sure how to go about trying to fix this and I've exhausted all my internet searching abilities. I can't seem to find any way to set my mouse wheel back to a middle click instead of switching scroll modes. Thanks.

share|improve this question

1 Answer 1

up vote 0 down vote accepted

I have been searching for a solution this problem for the better part of a year.

I have a solution that will solve the main problem posed in the question and fix the middle mouse button functionality for the MX5500 revolution.

I don't know how to use key bindings to fix it or really have any help to offer regarding your key binding questions.

I was able to restore the middle mouse button to my MX5500 revolution by installing a piece of software called revoco and using that to change a firmware setting on the mouse to set the number of autospin clicks before freespin is released. Freespin locks again when the wheel stops.

There was a guide here: http://ensourced.wordpress.com/2011/10/24/linux-mx-revolution-and-the-middle-mouse-button/

that was a little out-dated and with broken links, but I will post here what I did, step for step and hopefully it will help out some other people.

So the guide link to download revoco is broken. Luckily a commenter posted an updated link to a version that still works. I will link to this in my guide below.

1. So first open a terminal and create a folder for making revoco (ctrl+alt+t for terminal in Ubuntu) and download the necessary files (I used wget, you can do this however you like) by typing:

mkdir revoco
cd revoco
wget http://maemo.cloud-7.de/mx-revolution/revoLUTIONconTROL/Makefile
wget http://maemo.cloud-7.de/mx-revolution/revoLUTIONconTROL/bonoboware.txt
wget http://maemo.cloud-7.de/mx-revolution/revoLUTIONconTROL/mx-revo-full-lsusb.txt
wget http://maemo.cloud-7.de/mx-revolution/revoLUTIONconTROL/revoco
wget http://maemo.cloud-7.de/mx-revolution/revoLUTIONconTROL/revoco-orig.c
wget http://maemo.cloud-7.de/mx-revolution/revoLUTIONconTROL/revoco.c
wget http://maemo.cloud-7.de/mx-revolution/revoLUTIONconTROL/revoco.o

2. Now you need to locate you hid2hci.rules file and set the MX5500 Revolution HID to Raw.

The file can be located like this:

locate hid2hci.rules

My file is /lib/udev/rules.d/97-bluetooth-hid2hci.rules

Now edit this file as root

gksu gedit /lib/udev/rules.d/97-bluetooth-hid2hci.rules

And locate this line

# Logitech devices
KERNEL=="hiddev*", ATTRS{idVendor}=="046d", ATTRS{idProduct}=="c70[345abce]|c71[3bc]", \
  RUN+="hid2hci --method=logitech-hid --devpath=%p"

And change "hiddev*" to "hidraw*" then close and save.

3. Now make revoco and copy into a directory we can run from and make it executable:

cd revoco
make
sudo mv revoco /usr/bin
cd /usr/bin
chmod +x revoco

4. The last step is to use revoco to set the number of autospin clicks.

I like 20 because it means I can unlock freespin with 2 strong swipes, but it will never unclock when I'm trying to quickly click scroll (basically locks and unlocks exactly when /I/ want, but you should play with the number of clicks until you find exactly what works best for you).

revoco auto=20

And that's it. Set auto to 100 or something if you never want freespin. Either way this brings back MOUSE3 aka middle mouse click functionality. I hope this helps everyone out there.

This was tested on a couple different machines in Ubuntu 13.10 Saucy Salamander with MX5500 Revolution bluetooth mouse and keyboard combo.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.