Blocked media key

When AudioRelay is running on my Android and it’s connected to a server, I cannot use the play/pause button on my Bluetooth headphones.
If I kill the app, it works again.
Tested with Youtube Music and Youtube.
I thought it was pausing/resuming AudioRelay instead, but it doesn’t.

Android 12
Pixel 6

AudioRelay 0.24
Windows 11

1 Like

You’re right, I could reproduce it too.
For now, you can work around that by disabling the Media style notification setting.

1 Like

At first, your suggestion seemed to work. But now it’s happening again.
There is no Media style notification.
Weirdly enough, sometimes I can pause audio, but not unpause with the Bluetooth headphones play/pause button.
To reaffirm, this is only while it’s connected to a server (I mentioned last time I had to kill the app, but looks like just disconnecting does it now).
It wouldn’t be surprising if this or part of it, is some Android 12 bugginess.

I made some wrong assumptions and replied too fast before!
We can’t blame Android 12 as it’s a properly documented behavior.

Please try the latest version (0.24.3 as of right now, refresh the page if that’s not the case).

Some explanations for future reference:

On your current version, the app registers a “MediaSession”, regardless of the notification option. Android will send media buttons press to the last app with an active session.

Let’s say you do this:

  • Start and connect to a server in AudioRelay (Registers a MediaSession)
  • Play a song on Spotify (Registers a MediaSession)
  • You press pause via your headset

Spotify receives the event as it has the last active session. Spotify releases its MediaSession and now AudioRelay’s MediaSession is the active one.

Play/Pause events will be lost since AudioRelay receive them. You can no longer unpause Spotify.

It’ll work in the new version because it doesn’t register a MediaSession if you disable the “Media notification style” option.

2 Likes