Ubuntu – How to get a wireless USB keyboard to to wake Ubuntu 13.10 from suspend

power-managementsuspend

My PC with Ubuntu 13.10 is set to suspend after 30 minutes of inactivity. Up until it suspends I can resume working at any time using my Logitech K400r wireless USB keyboard.

The OS defect/problem is that once it suspends – the wireless keyboard can no longer wake the suspended Ubuntu 13.10. This appears to be a Ubuntu specific problem because the same PC when booted up with MS Windows 7 always wakes up from sleep mode when you press any key on the Logitech keyboard.

I imagine something in Ubuntu is causing the USB to go into a different state from what Windows 7 puts it in. Does anyone have any ideas how to overcome this issue as the only way to wake the PC is to walk up to it and push the power button for a short period once.

While this power button wakes up the PC it then displays a number of error messages about sound, networking etc being down ….which do go away after a few minutes of what seems to be the OS recovering from Suspend. Not sure if this is normal Linux behaviour due to my short experience with this OS.

Again could anyone help with some details on whether there is any setting that would help keep the wireless usb keyboard alive just enough to wake the pc?

Many thanks.

Best Answer

I found an open source project that provides extra functionality for devices on the Logitech Unified Receiver. Installing that application and a udev rule from a fork of that project allows me to wake Ubuntu 14.04 from suspend using a wireless Logitech keyboard.

Install solaar from the (now) author's PPA.

sudo apt-add-repository ppa:daniel.pavel/solaar
sudo apt update
sudo apt install solaar

If you don't have git, install it

sudo apt-get install git

Clone the fork with a corrected /udev rule

git clone https://github.com/3v1n0/Solaar.git ~/solaar

Install the /udev rule that will enable resume via the unified receiver

cd ~/solaar/rules.d
./install.sh

At this point, I unplugged the receiver and plugged it back in (as per instructions on the repo). Next, I launched solaar through the Dash and verified that my keyboard was communicating with the app. Finally, I rebooted and tested the Sleep button on the keyboard. After the machine was asleep, I was able to resume using any key.

Related Question