I bought a bluetooth headphone that always works in my Android, but in my Ubuntu when I connect it and try to play any video, be it in youtube or a .mp4 opened locally, it won't play. If I disconnect the bluetooth, it plays. I discovered a ritual that needs to be done in order for the headphone to work:
I first connect the bluetooth, then I move its profile in sound settings from High Fidelity Playback to Headset Head Unit, and I click "Test Sound", play a sound an hear some noises. Then I disconnect the bluetooth and connect it again and change to High Fidelity Playback again and test the sound, now it works and I hear "front, left" when I test the sound. Then everything works fine.
Is there a way to fix it? It's very annoying to do it every time I disconnect from my PC.
UPDATE: even now that I updated to Zetsy it still have this same problem
Bluetooth on Linux always has been a pain. I would suggest either doing a fresh install of Zesty, buy a new Bluetooth headset that can just be used with the Ubuntu device, and/or buy a new wired headset/phone.
I have similar problems with Bluetooth.
Luckily pylover has turned the ritual into a program.
See here:
https://gist.github.com/pylover/d68be364adac5f946887b85e6ed6e7ae
This program generally works for me.
Try this: I saw this somewhere, but I dont remember the source now.
hcitool dev - shows the mac of the bluetooth device You would need this to insert it later in the file below ( if not available, create it )
Another file ( if not available, create it )
This below command will fetch an user interface and many things can be done.
The Python program in this GitHub gist fixes problems playing videos in web browsers while connected to Bluetooth audio devices.
To use it, run a2adp.py in any IDE (such as VS Code).