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'm using Ubuntu 11.04 64 bit laptop, and I have a Microsoft mouse. When I'm on the battery power the mouse cuts in and out, I have full battery power so it's not because of low power. It never does this in Windows, and in the past when I ran Karmic it never did this either, only when I reinstalled Ubuntu with Natty. As soon as I plug in the power it works perfectly fine.

share|improve this question
    
do you see anything weird happening in dmesg? –  user606723 Aug 3 '11 at 20:47
    
Doesn't look like anything weird is happening, but it's hard to tell, really overwhelming, a lot of info on dmesg. –  KoRnKloWn Aug 5 '11 at 7:11
    
This question appears to be abandoned and unanswered, could you perhaps add more detail to your question? If this question no longer applies then you can either delete it or answer it yourself if you've solved the problem. Thanks! –  Jorge Castro Feb 11 '12 at 22:58

5 Answers 5

It seems like your computer is set to disable USB when iddle as a power saving measure.

This is usually suggested by powertop, but it's a very bad idea if you are using a USB mouse. This command fixes it temporally:

echo -1 | sudo tee /sys/bus/usb/devices/yourmouse/../power/autosuspend

You need to substitute yourmouse for your mouse bus and device number, you can usually find it with:

lsusb

Unluckily this will work only until whatever the program that have changed the setting kicks on again: either at boot time, when you disconnect your computer from electricity, or whatever. You need to discover what package is changing it to resolve the issue.

share|improve this answer
    
There doesn't seem to be anything in that directory with the name of the bus and device numbers –  KoRnKloWn Aug 5 '11 at 7:10
    
Can you post the output of both lsusb and ls /sys/bus/devices/ ?. –  Javier Rivera Aug 5 '11 at 7:52
    
I also changed the command as the autosuspend parameters were wrong and there was a permission problem. –  Javier Rivera Aug 5 '11 at 7:59
    
I managed to find the folder with the autosuspend file using the directory listing you posted above, but the value was already set to 2, and I ran the command directly from that folder anyways on the autosuspend file, but nothing changed because like I said, it was already set to two. –  KoRnKloWn Aug 5 '11 at 19:12
    
Also, it's constantly cutting in and out, and I just noticed in the power folder runtime_status changes to suspended when it cuts out, and switches back to active when it comes back on. –  KoRnKloWn Aug 5 '11 at 19:20

Make sure you don't have the laptop-mode-tools or powertop packages installed. If you do, uninstall them by running

sudo apt-get remove --purge laptop-mode-tools powertop && apt-get autoremove

This solved the issue for me on Mint 13 on an Alienware M14x R2.

share|improve this answer
    
I think it's "powertop" instead of "powertools": sudo apt-get remove --purge laptop-mode-tools powertop && apt-get autoremove –  Mukesh Chapagain Aug 27 '12 at 6:59
up vote 0 down vote accepted

I should note that after 11.10 that problem no longer existed for me. So the answer to this problem is just update! :D

share|improve this answer

This behaviour is caused by laptop-mode-tools. While it's true that removing it completely solves the "problem", you may still want to keep the package on your system.

In order to disable the usb autosuspend feature of laptop-mode-tools for your mouse, you can insert your mouse's USBID (obtainable through lsusb) in

/etc/laptop-mode/conf.d/usb-autosuspend.conf

on the line

AUTOSUSPEND_USBID_BLACKLIST="your-usb-id"

where your-usb-id is of the format 093a:2510 (this is my mouse). If AUTOSUSPEND_USBID_BLACKLIST is already there, simply add the necessary USBID (note this will work only if AUTOSUSPEND_USE_WHITELIST is set to 0).

Finally, reload laptop-mode-tools by executing

# service laptop-mode reload

or

$ sudo service laptop-mode reload
share|improve this answer
    
In case you want to keep laptop-mode-tools but you don't want it to mess with any of your USB devices, you can edit the configuration and set CONTROL_USB_AUTOSUSPEND=0 (the default is "auto"). –  nickie Jan 29 at 18:59

I had a similar problem and I solved it by disabling pm-powersave with

    # pm-powersave false

Then I rebooted my laptop and everything was just fine. I don't know, however, the other implications of this action.

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.