Ubuntu Tutorials & How-To's

Ubuntu 10.10 – Disable Mouse Acceleration

This will show you how to completely disable mouse acceleration and set a much slower or faster mouse speed then what is available with gnome-mouse-properties in Ubuntu 10.10 Maverick. By default Ubuntu enables mouse acceleration even with Acceleration and Sensitivity turn all the way down in Mouse Preferences there will still be some acceleration.

First type the command below which will list the all the input devices you should see your mouse in the list and the device ID next to the name of the device.

1
2
3
4
5
6
7
8
9
10
11
12
13
administrator@Desktop:~$ xinput list
⎡ Virtual core pointer                        id=2    [master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer                  id=4    [slave  pointer  (2)]
⎜   ↳ Microsoft Microsoft 3-Button Mouse with IntelliEye(TM)    id=10    [slave  pointer  (2)]
⎜   ↳ SynPS/2 Synaptics TouchPad                  id=13    [slave  pointer  (2)]
⎣ Virtual core keyboard                       id=3    [master keyboard (2)]
↳ Virtual core XTEST keyboard                 id=5    [slave  keyboard (3)]
↳ Power Button                                id=6    [slave  keyboard (3)]
↳ Video Bus                                   id=7    [slave  keyboard (3)]
↳ Sleep Button                                id=8    [slave  keyboard (3)]
↳ USB2.0 2.0M UVC WebCam                      id=9    [slave  keyboard (3)]
↳ Asus Laptop extra buttons                   id=11    [slave  keyboard (3)]
↳ AT Translated Set 2 keyboard                id=12    [slave  keyboard (3)

Then enter the command below replace the number with the ID of your mouse that was in the list above. This will list the available properties for the mouse. You should see “Device Accel Profile” and “Device Accel Adaptive Deceleration” these are the properties that control the mouse acceleration and mouse speed.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
administrator@Desktop:~$ xinput list-props 10
Device 'Microsoft Microsoft 3-Button Mouse with IntelliEye(TM)':
Device Enabled (121):    1
Coordinate Transformation Matrix (123):    1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
Device Accel Profile (241):    -1
Device Accel Constant Deceleration (242):    2.000000
Device Accel Adaptive Deceleration (243):    1.000000
Device Accel Velocity Scaling (244):    10.000000
Evdev Reopen Attempts (239):    10
Evdev Axis Inversion (245):    0, 0
Evdev Axes Swap (247):    0
Axis Labels (248):    "Rel X" (131), "Rel Y" (132)
Button Labels (249):    "Button Left" (124), "Button Middle" (125), "Button Right" (126), "Button Wheel Up" (127), "Button Wheel Down" (128), "Button Horiz Wheel Left" (129), "Button Horiz Wheel Right" (130)
Evdev Middle Button Emulation (250):    2
Evdev Middle Button Timeout (251):    50
Evdev Wheel Emulation (252):    0
Evdev Wheel Emulation Axes (253):    0, 0, 4, 5
Evdev Wheel Emulation Inertia (254):    10
Evdev Wheel Emulation Timeout (255):    200
Evdev Wheel Emulation Button (256):    4
Evdev Drag Lock Buttons (257):    0

Then create a file in your home folder and add the lines below. Change the name below to the name of your mouse from the list above. If you want to completely disable mouse acceleration set “Device Accel Profile” to -1 like it is below then set “Device Accel Constant Deceleration” to the speed you want your mouse at. For more information on the device properties refer to the X.Org PointerAcceleration documentation.

1
2
3
administrator@Desktop:~$ nano ~/.mousespeed
xinput set-prop 'Microsoft Microsoft 3-Button Mouse with IntelliEye(TM)' 'Device Accel Profile' -1
xinput set-prop 'Microsoft Microsoft 3-Button Mouse with IntelliEye(TM)' 'Device Accel Constant Deceleration' 2

To apply the mouse settings run the command below. Every time you disconnect the mouse and reconnect it the settings will need to be re-applied. To apply the settings when the computer restarts open “System -> Preferences -> Startup Applications” and click add set “Name” to “Mousespeed” and “Command” to “sh /home/USER/.mousespeed” replace “USER” with your username.

1
administrator@Desktop:~$ sh ~/.mousespeed

8 Responses

  1. cpup

    Hi,

    Good tutorial but it doesn’t show how to increase mouse speed after disabling acceleration or i missed something.

    ‘Device Accel Constant Deceleration’ allows only to decrease speed ?

    November 17, 2011 at 12:16 pm

  2. Jason

    A very helpful webpage, indeed.

    November 20, 2011 at 12:05 pm

  3. Chris

    I wish this showed how to issue this command if the same device shows as 2 diff id #s How can I distinguish between the two within this command???

    January 12, 2012 at 11:07 pm

  4. kim

    Thank you, this works!

    February 18, 2012 at 4:53 am

  5. Wow

    Thanks a lot, this worked perfectly!

    May 28, 2012 at 12:35 am

  6. noa

    Now the mouse feels normal again. Thank you.

    July 8, 2012 at 4:02 pm

  7. Moriarty

    You sir are one of the few rare examples that making a a simple understandable guide to anything related to linux is not impossible. Thank you.

    December 5, 2012 at 2:09 pm

  8. marble

    Thank you very much. Worked perfectly.

    December 8, 2012 at 12:09 pm

Leave a Reply

Your email address will not be published.

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

QR Code Business Card