I have noticed, that although my "Bluetooth Headset" works perfectly fine, buttons on it, like Previous, Next, Play etc do not.
Why is that?
I have noticed, that although my "Bluetooth Headset" works perfectly fine, buttons on it, like Previous, Next, Play etc do not.
Why is that?
As of Ubuntu 10.04,
uinput
module that handles such buttons is not started by default. To fix the situation:sudo service bluetooth stop
sudo modprobe uinput
sudo service bluetooth start
That should fix the issue temporarily, until restart. To fix it permanently, run:
Vava's answer did not fix the issue for me alone (Ubuntu 20.04), I had to use, in addition,
xbindkeys
andplayerctl
https://wiki.archlinux.org/title/XbindkeysFirst, disable/unassign the shortcuts for media play and pause via the shortcut editor.
Open
~/.xbindkeysrc
and delete all lines between line 40 and 66 inclusive.Get the raw keycode (e.g.
m:0x0 + c:209
). Your headset might toggle between play and pause keycodes, so runxbindkeys --key
twice to get code for both play and pause.Put the following into your ~/.xbindkeysrc with the correct key codes.
If your headset is already passing XF86Play or some other key (you can use
screenkey
to check, you can use the following instead as an exampleplayerctl play-pause
will control "the first available player". Readplayerctl -h
for more info/options if needed.Open
/etc/X11/Xsession
as root. Add the linexbindkeys
after the linePROGNAME=Xsession
.Reboot.
My headset now correctly controls Youtube videos.