11

I'm having some problems with a new R.A.T 3 gaming mouse that I bought today. It works flawlessly under Windows 7, but under Ubuntu 11.10 it keeps misbehaving.

What happens is this:

  1. I connect the mouse to a USB port. The mouse works as expected for a while.
  2. The mouse starts misbehaving: I can still move the pointer around, but it doesn't react to clicking any buttons (at least not right, left, middle, browser forward or browser back...). Furthermore, my trackpad starts behaving the same way - moving works, but no clicking.
  3. I disconnect the mouse. Trackpad starts working again.
  4. I re-connect the mouse. It works for a while, before collapsing (just as the first time I connected it).

I haven't manually changed any settings anywhere, and I've noticed that even when the mouse misbehaves, it shows up in cat /proc/bus/input/devices with the following information:

I: Bus=0003 Vendor=06a3 Product=0ccc Version=0111  
N: Name="Saitek Cyborg R.A.T 3 Mouse"  
P: Phys=usb-0000:00:1d.0-1.4/input0  
S: Sysfs=/devices/pci0000:00/00:1d.0/usb2/2-1.4/2-1.4:1.0/input/input18  
U: Uniq=  
H: Handlers=mouse0 event4  
B: PROP=0  
B: EV=17  
B: KEY=3ff0000 0 0 0 0  
B: REL=103  
B: MSC=10  

I've googled around a bit and found this forum post, but I find it quite messy and it is unclear whether there is actually any solution to my problem in it. Also, I feel uncomfortable editing Xconf without knowing what I'm doing - and I'm quite new on Ubuntu, so I don't know what I'm doing... Finally, the product web site doesn't appear to have any drivers for Ubuntu and I've found no updates available through the standard sources.

1
  • This appears to work (RAT7). Here are the right button refinements for RAT5. Just add the section in the above links to the end of an otherwise unaltered xorg.conf.
    – user42536
    Jan 20, 2012 at 18:17

6 Answers 6

9

The reason (as I understand) that this particular mouse misbehaves on Linux is because of the mode button. In terms of key presses, each mode corresponds to a different button being held down. For my mouse (R.A.T.7) the mode buttons are 13, 14, and 15 for red, blue, and purple respectively.

I don't know if yours are going to be the same, but there's a nice and easy way to figure it out. Open a terminal and type:

xinput list | grep "id"

Find the entry that has the corresponding label (for me it's "Saitek Cyborg R.A.T.7 Mouse") and note the ID to the right. Then, type:

xinput query-state ID

(Where ID corresponds to the ID of your mouse)

Note which mode color is currently active, switch it to the next one, and retype the above command. Do that one more time.

Now that you know which buttons correspond to the modes, you should be able to edit your xorg.conf file appropriately. Type:

gksu gedit /etc/X11/xorg.conf

(Obviously you can use a different text editor if you feel more comfortable with one. If you use a command-line text editor, use sudo instead of gksu.)

You'll want to insert a block that's similar to this:

Section "InputClass"
    Identifier      "Mouse Remap"
    MatchProduct    "Saitek Cyborg R.A.T.7 Mouse"
    MatchDevicePath "/dev/input/event*"
    Option      "ButtonMapping" "1 2 3 4 5 6 7 8 9 10 11 12 0 0 0"
EndSection

The important thing is the "ButtonMapping" part. Just go through the list of buttons sequentially until you get to the buttons that correspond to the modes and enter 0s instead.

You'll have to restart your X server for the changes to work, but this should fix it up!

2
  • 1
    I spoke too soon. The solution worked until restart and then the same problem returns again. Anyone know what is going on with this mouse ?
    – user42536
    Jan 19, 2012 at 20:30
  • This seems to have fixed the problem with my RAT 9 mouse. However, I had to include enough zeros for all the buttons (the RAT 9 has 21 buttons), else I just got a black screen as Xorg wouldn't start anymore.
    – jmiserez
    Jan 1, 2015 at 19:48
1

Add this to your xorg.conf:

Section "InputClass"
Identifier "Mouse Remap"
MatchProduct "Saitek Cyborg R.A.T.3 Mouse"
MatchDevicePath "/dev/input/event*"
Option "ButtonMapping" "1 2 3 4 5 6 7 8 9 10 11 12 13 14"
EndSection
1

I bought the mouse 30 December 2013 in The Netherlands

R.A.T.3

Tested on Ubuntu 13.04 && 13.10

I used the following settings:

//    Command gksudo gedit /etc/X11/xorg.conf

Section "InputClass"
Identifier "Mouse Remap"
MatchProduct "Madcatz Mad Catz R.A.T.3 Mouse"
MatchDevicePath "/dev/input/event*"
Option "ButtonMapping" "1 2 3 4 5 6 7 8 9 0 0 0 0 0 0 0 0 0"
EndSection

I'm not sure but I think you need to start with the '0' where "button[int]=down" So in my case 10 was down and after the update it was up.

"button[int]=down" is related from:

xinput query-state 'int'

'int' is the ID of the mouse that can be found with the following command:

xinput list | grep "id"

Sometimes Europe demands other hardware configuration thus it'll be best if you check it once.

Would you be so kind to notify if it works or not works for you?

If you use unity, use the following command to restart the x-server:

sudo restart lightdm

Else if you use Gnome 3

sudo service gdm3 restart
0

for me with RAT 3, I used :

Section "InputClass"
    Identifier "Mouse Remap"
    MatchProduct "Madcatz Mad Catz R.A.T.3 Mouse"
    MatchDevicePath "/dev/input/event*"
    Option "ButtonMapping" "1 2 3 4 5 6 7 8 0 0 0 0 0 0 0 0 0 0 0"
EndSection
0

What is really works in Ubuntu/Mint etc... is:

First type in the command to find out which product you have:

xinput -list

Once you find out what mouse you have:

sudo gedit /etc/X11/xorg.conf

For me I have the Madcatz Mad Catz R.A.T.3; type in:

Section "InputClass"
Identifiers "Mouse Remap"
MatchProduct "Madcatz Mad Catz R.A.T.3 Mouse"
MatchDevicePath "/dev/input/event*"
Option "ButtonMapping" "1 2 3 4 5 0 0 8 9 0 0 0 0 0"
EndSection

For Madcatz Saitek Cyborg R.A.T.3; type in:

Section "InputClass"
Identifier "Mouse Remap"
MatchProduct "Saitek Cyborg R.A.T.3 Mouse"
MatchDevicePath "/dev/input/event*"
Option "ButtonMapping" "1 2 3 4 5 0 0 8 9 0 0 0 13 14"
EndSection

After you typed the lines in and SAVED, make sure to reboot your computer!

Or if you use ubuntu you can just type: sudo restart lightdm

0

Actually, all of the provided solutions mean that your horizontal wheel might not work. I found the following solution works. Create a file /etc/X11/xorg.conf.d/20-cyborgrat.conf with the following content:

Section "InputClass"
        Identifier "Mouse Remap"
        MatchProduct "Saitek Cyborg R.A.T.3 Mouse|Saitek Cyborg R.A.T.5 Mouse|Saitek Cyborg R.A.T.7 Mouse|Saitek Cyborg R.A.T.9 Mouse"
        MatchDevicePath "/dev/input/event*"
        Option "Buttons" "17"
        Option "ButtonMapping" "1 2 3 4 5 0 0 8 9 7 6 12 0 0 0 16 17"
        Option "AutoReleaseButtons" "13 14 15"
        Option "ZAxisMapping" "4 5 6 7"
EndSection

I use this with a Saitek Cyborg R.A.T.7 Mouse and verified that the following things work:

  • Left and right mouse button (button 1/3)
  • Pushing down vertical mouse wheel for middle mouse button (button 2).
  • Vertical mouse wheel scrolls vertically (button 4/5).
  • Horizontal mouse wheel scrolls horizontally (button 6/7).
  • Forward / Backward button (button 8/9).
  • Red button (button 12).
  • Speed button (button 16/17).

The color switch button does not work with this config.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .