BTtons

Rating: 
5
Your rating: None Average: 5 (5 votes)

BTtons is a really small application to easily start or stop mpris-proxy.

This enables control (AVRCP) from bluetooth-connected devices like head phones or car stereos for many existing media players that are already using the MPRIS2 Specification (mostly used for lock screen controls). The proxy will continue to run if you close BTtons.

It is meant for devices using Bluez 5, which for example excludes the original Jolla Phone and Jolla Tablet. (To prevent system damage, you won't be able to install this on a "Bluez 4" device, Storeman will greet you with an error message if you try.)

BTtons depends on the package bluez5-tools (containing mpris-proxy), which will be automatically installed from the official repositories (or any other enabled repository that provides it) when you install BTtons.

It is meant as a quick and dirty band-aid-solution for inexperienced or lazy users until Jolla finds the time to fix this part of the bluez integration in Sailfish. This means:

  • There is no daemon or autostart. You'll have to manually start it after a reboot (or possibly, after errors).
  • There is no debugging or logging. If you want to debug when mpris-proxy isn't working, you'll have to run that independently from BTtons.
  • Mpris-proxy may misbehave, for example when using flight mode or disabling bluetooth. You may have to restart it manually (using BTtns) if it stops working.

If you're experiencing any issues or want to contribute otherwise (features/translations/…) you're welcome to do that at https://github.com/jgibbon/harbour-btbuttons (GPLv2). 
 

Screenshots: 
Application versions: 
AttachmentSizeDate
File harbour-btbuttons-0.1-1.armv7hl.rpm62.21 KB02/12/2019 - 18:56
Changelog: 

initial release

Comments

Sanpo's picture

Okay, I tested it with different mediaplayer and it works. Thank you very much for this app and answer :)

velox's picture

Awesome! Glad it worked, after all!
Cheers!

Sanpo's picture

Does not work on xperia 10 plus

velox's picture

Sad to hear that. I've seen it working with some version (don't know exactly) of the  10, so can you elaborate a bit on this?

  • does BTtons start?
  • does BTtons claim to start the mpris-proxy?
  • can you stop the proxy in BTtons and start it (command: mpris-proxy) from Terminal? What does it output?
  • which player did you test with? (jolla mediaplayer does seem to have some own implementation; Deadbeef Silica should definitely work without mpris-proxy. If they don't, I suspect a  compatibility issue with your bluetooth device)

Thanks for checking it out & cheers!

Lustmored's picture

Thank you! This is amazing, one feature that I didn't even know I need and will use so much.

Also FYI - for me at least, managing calls works out of the box (without mpris-proxy) in Car Audio withount any hiccups, so it seems to be out of scope here.

velox's picture

Glad to hear that, thanks for sharing!

Cheers!

tmojo's picture

Thanks a lot for your detailed reply. I was confused that controlling media player worked before for me until I remembered that I installed mpris-proxy before and start it via systemd. Your app is a nice alternative if one doesn't want to mess with systemd.

Answering / hanging up calls stopped working with bluez5 (IIRC) but haven't found out why. I also haven't found out yett how to recognise those key presses on the phone.

velox's picture

Haha, yeah, systemd is the "for inexperienced or lazy" part in the App description. Thanks for trying this, though!

Cheers! 

tmojo's picture

Nice idea. Could you name a few apps that use mpris2?

Would it be possible to extend this proxy to enable the user to answer and hangup calls from BT headsets?

velox's picture

Hi there,
mpris2 is basically used by every player with lock screen controls, so most players having those should more or less work. I've – with the limited bt hardware at my disposal – successfully tested with (shameless plug, oh no!) my audio book player, Talefish. 

App developers can, of course, vary the degree of support for mpris they support and many do. I've, for example, heard that a user (Thanks, "SFOS -Tester" for the YouTube video :D) had problems with spotify, which looked like the android version.
If you find native players (preferably open source and without some kind of account necessary) that totally do not work despite having lock screen controls, I'll do my best to help coordinate finding what may be the problem and communicate it to the app author.

Calls: I do not think this is in the desired scope of mpris-proxy. Since I rarely call nor have a bt car stereo myself, I'm actually a bit surprised to hear that it doesn't work even without mpris-proxy. I would have thought it did.