Several years ago I bought a Saitek R.A.T v5 and had countless problems getting it working under Linux.

It would occasionally work but more often than not I wouldn’t be able to select windows and sometimes I couldn’t click on anything at all. After some searching I found a solution which disables the mode button on the mouse and this worked until I sold it for a Razer Deathadder.

Recently I was after a new mouse and came across a R.A.T TE going cheap. Having completely forgotten about my previous issues with R.A.T mice I snapped it up.

The mouse worked perfectly for several months but more recently the same issues have started to crop up again. I’m not sure if it was caused by a kernel regression or another package update or is simply coincidence but whatever the cause I needed a solution.

I tried the fix I had previously used for the R.A.T v5 but as the branding has changed from Saitek to Mad Catz and it’s a different model I didn’t have much success.

Here’s what I did to fix it:

Using xinput list | grep "id" I got the id of the mouse:

5:⎜   ↳ Mad Catz Mad Catz R.A.T.TE                  id=8    [slave  pointer  (2)]


I then ran xinput query-state ID in each of the mouse’s “modes” (where ID is the id from the previous command, in my case “8”). The mode is changed using the mode button and changes color for each mode (Usually Red, Blue and Purple).

This outputs an array of the buttons on the mouse, each button having the value “up” or “down”. When the outputs for each mode are compared, the only buttons that have their values change are the ones that correspond to the mode button. In my case they were buttons 13, 14 and 15.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
Red mode:
...
button[13]=down
button[14]=up
button[15]=up
...

Blue mode:
...
button[13]=up
button[14]=down
button[15]=up
...

Purple Mode:
...
button[13]=up
button[14]=up
button[15]=down
...

I took the fix I had used for the R.A.T v5 and set the values for those buttons to “0”. I also changed the device name to the name from the first command.

This left me with the following:

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

As I no longer have an xorg.conf I decided to use the more modern convention of placing the above in a separate configuration file under /etc/X11/xorg.conf.d/ called 50-vmouse.conf.

Upon restarting xorg the problem seems fixed. Hopefully it’ll stay that way, until I buy another fancy gaming mouse.

And here’s the mouse in question. It may look like a bit of a gimmick but it’s certainly very comfortable to use.

RAT TE