Jump to content

Poweramp won't take focus from radio on Android HU


Bammer

Recommended Posts

I'm having some strange audio focus issues with Poweramp and the stock FM radio app on my Android head unit.  Other music players do not have these issues, but I would prefer to use Poweramp. 

  1. When playing the radio, if I try to play something in Poweramp, the radio keeps playing.  Poweramp looks like it is playing but will not take the audio focus from the stock radio app.  I can open the radio app and exit out so that it stops playing, then open PA and it will play fine.  
  2. If playing something in PA and I open the radio, audio focus changes to the radio correctly, but PA doesn't actually pause the song (even though I can't hear it).  It will still move through the playlist and update the widget.
  3. Sometimes, when playing in PA, focus will just randomly change back to the radio.  This could be something that the radio app or HU is doing, but it doesn't happen with other players. 

The HU is supposed to be Android 10, but I suspect it may actually be 9.  It is PX6, Rockchip RK3399, and MCU firmware is STM32-based. 

Are there any settings in PA that may help?

Link to comment
Share on other sites

  • Replies 27
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

  • 1 year later...

I have this issue with and android head unit. when I open the stock radio app the radio plays, when I open the stock music player the radio mutes and the music plays,  this is the desired effect. 
when I use Poweramp eg, stock radio app and open Poweramp the radio does not mute and I’m treated to mixed audio streams of the radio and Poweramp. I have to manually close the radio app before opening Poweramp. It appears Poweramp is not taking the audio focus away from the radio app. When I’m running Poweramp and I open the stock radio app the radio will take the audio focus from Poweramp, but not vice versa Using the latest full version of Poweramp on an android head unit. Any ideas? If you need any files let me know. Cheers 

Link to comment
Share on other sites

On 12/17/2021 at 9:45 PM, KerryJGilbert said:

I have this issue with and android head unit. when I open the stock radio app the radio plays, when I open the stock music player the radio mutes and the music plays,  this is the desired effect. 
when I use Poweramp eg, stock radio app and open Poweramp the radio does not mute and I’m treated to mixed audio streams of the radio and Poweramp. I have to manually close the radio app before opening Poweramp. It appears Poweramp is not taking the audio focus away from the radio app. When I’m running Poweramp and I open the stock radio app the radio will take the audio focus from Poweramp, but not vice versa Using the latest full version of Poweramp on an android head unit. Any ideas? If you need any files let me know. Cheers 

Hi there I am also having this issue it started about a month ago, all was fine before then? The only way I can get my phone to not play through the phone speaker and any Bluetooth device at the same time is to power on the Bluetooth device and let it connect then reboot the phone and connect again this time the music plays to the Bluetooth device only and not the phone speaker simultaneously. Anyone know why this may be happening? Or is there a repository of old PA apks I can go to and get a version from a month or so ago to test. 

 

A point to note this only happens with Poweramp all other apps I have tried play to the devices only as we would expect? 

 

Cheers all

Link to comment
Share on other sites

So I have reverted back to this version from apkmirror - Poweramp Music Player build-911--play (arm64-v8a) (nodpi) (Android 5.0+)

And all is working as before December updates? 

 

Here is the commands processed this time with this version

Screenshot_20211229-154208274.jpg

Link to comment
Share on other sites

I'm guessing that the reason for the change in behaviour between PA 911 to the more recent builds is that much of the long period of development before the release of PA 912 was to switch up to the latest SDK level (30) which Google is now requiring for new app releases on the Google Play Store. Even though there were relatively few actual added features, the new SDK requirement sadly removed some functionality (such as access to root folders) and added many more restrictions. It also required build tool changes, some refactoring, and a lot of low-level changes.

Hopefully Max may be able to work around some of these issues in time, but in-car head units are some of the least compliant and most modified Android variants out there (along with some specialised DAPs) so it might be a lengthy process to track them down. For now, if 911 still works for you, feel free to continue using it (make sure to turn auto-updates off if your device has an internet connection).

Andre

Link to comment
Share on other sites

Thanks Andre when I have more time I will see if I can pinpoint the exact version of PA this started on. With it happening on every Bluetooth device I had I was starting to wonder if it was the phone itself at one point. To be clear this issue happened when connecting to my car's Bluetooth interface to play music and make calls, my wireless headphones and my wireless speaker 🔊). 

If I can send anymore useful information for Max to maybe l help him understand this issue better (logs etc) I will update the app and look to get any if that info, just let me know. 

It shows how good this app has always been I haven't had a requirement post in here in many many years haha, brilliant app Max 👍

Link to comment
Share on other sites

@hoppi05 the last log has media button events which are processed, the previous logs have no such. Poweramp is a receiving side here, it doesn’t generate those button presses. Generally the button presses and API commands were tested and do work 100% for the latest Poweramp builds.

Also the log from 911 shows that there are no audio focus events, so this API is not used at all by your radio app.

There was a behavior change recently in Android though, not in Poweramp - now when a player app is in background/not playing, Google assistant app intercepts and processes all media key events, redirecting events to the other apps (or not).

Either Assistant intercepted the key or did not is visible from the Full log available in Developer settings (this log has like the last 1 minute of events, so it should be taken immediately after the issue arises). Feel free to send this to gpmaxmpz@gmail.com for the further investigation. Thanks!

Link to comment
Share on other sites

No problem Max I will find some time and do this. It's so odd this has happened as I have never experienced this with this app or android but these things are sent to test us haha. Just to be clear my car head unit us a standard unit just with a Bluetooth dongle plugged in to the aux port, the app is only installed on this phone and plays via this phone to all my Bluetooth devices. As I say currently back on this version all is back to normal and working. 

Link to comment
Share on other sites

19 hours ago, maxmp said:

@hoppi05 the last log has media button events which are processed, the previous logs have no such. Poweramp is a receiving side here, it doesn’t generate those button presses. Generally the button presses and API commands were tested and do work 100% for the latest Poweramp builds.

Also the log from 911 shows that there are no audio focus events, so this API is not used at all by your radio app.

There was a behavior change recently in Android though, not in Poweramp - now when a player app is in background/not playing, Google assistant app intercepts and processes all media key events, redirecting events to the other apps (or not).

Either Assistant intercepted the key or did not is visible from the Full log available in Developer settings (this log has like the last 1 minute of events, so it should be taken immediately after the issue arises). Feel free to send this to gpmaxmpz@gmail.com for the further investigation. Thanks!

Hey Max I have had a look but I cannot see where to grab this log from? Can you point me in the right direction please. 

Also I can confirm now back on the old version the car stereo aux Bluetooth device is working like it is expected to too. But when I upgrade to the latest version if PA the issues of dual sound output start again? 

Link to comment
Share on other sites

I have extreme logcat installed and root so I could take a snip from there and send that if that would capture the correct logs for you?

 

 

20 hours ago, maxmp said:

@hoppi05 the last log has media button events which are processed, the previous logs have no such. Poweramp is a receiving side here, it doesn’t generate those button presses. Generally the button presses and API commands were tested and do work 100% for the latest Poweramp builds.

Also the log from 911 shows that there are no audio focus events, so this API is not used at all by your radio app.

There was a behavior change recently in Android though, not in Poweramp - now when a player app is in background/not playing, Google assistant app intercepts and processes all media key events, redirecting events to the other apps (or not).

Either Assistant intercepted the key or did not is visible from the Full log available in Developer settings (this log has like the last 1 minute of events, so it should be taken immediately after the issue arises). Feel free to send this to gpmaxmpz@gmail.com for the fu

Hey Max I have had a look but I cannot see where to grab this log from? Can you point me in the right direction please. 

Also I can confirm now back on the old version the car stereo aux Bluetooth device is working like it is expected to too. But when I upgrade to the latest version if PA the issues of dual sound output start again? 

Link to comment
Share on other sites

Hi Max but in my developer options I don't see anything near the top that suggests it's s log file as such? See screenshot below. 

 

On 12/29/2021 at 6:14 PM, maxmp said:

@hoppi05 the last log has media button events which are processed, the previous logs have no such. Poweramp is a receiving side here, it doesn’t generate those button presses. Generally the button presses and API commands were tested and do work 100% for the latest Poweramp builds.

Also the log from 911 shows that there are no audio focus events, so this API is not used at all by your radio app.

There was a behavior change recently in Android though, not in Poweramp - now when a player app is in background/not playing, Google assistant app intercepts and processes all media key events, redirecting events to the other apps (or not).

Either Assistant intercepted the key or did not is visible from the Full log available in Developer settings (this log has like the last 1 minute of events, so it should be taken immediately after the issue arises). Feel free to send this to gpmaxmpz@gmail.com for the fu

 

Screenshot_20211230-220758994.jpg

Link to comment
Share on other sites

12 hours ago, hoppi05 said:

Hi Max but in my developer options I don't see anything near the top that suggests it's s log file as such?

Not sure why your device is different, but on Android 11 you should see:

image.png

It can also be done remotely from a connected PC using the ADB package (Android Debug Bridge) but Max would have to let us know what log detail command he requires to be collected from there.

Andre

 

Link to comment
Share on other sites

Hahaha oh why are devices sometimes so different! Not sure where it is on my decide then...

On 12/29/2021 at 6:14 PM, maxmp said:

@hoppi05 the last log has media button events which are processed, the previous logs have no such. Poweramp is a receiving side here, it doesn’t generate those button presses. Generally the button presses and API commands were tested and do work 100% for the latest Poweramp builds.

Also the log from 911 shows that there are no audio focus events, so this API is not used at all by your radio app.

There was a behavior change recently in Android though, not in Poweramp - now when a player app is in background/not playing, Google assistant app intercepts and processes all media key events, redirecting events to the other apps (or not).

Either Assistant intercepted the key or did not is visible from the Full log available in Developer settings (this log has like the last 1 minute of events, so it should be taken immediately after the issue arises). Feel free to send this to gpmaxmpz@gmail.com for the fu

 

Link to comment
Share on other sites

Man.... I don't have that setting either!? I am on a Poco x2 or redmi k30. This is the issue running custom ROMs, if it helps I am on corvus 16.8 android 11 base.

On 12/29/2021 at 6:14 PM, maxmp said:

@hoppi05 the last log has media button events which are processed, the previous logs have no such. Poweramp is a receiving side here, it doesn’t generate those button presses. Generally the button presses and API commands were tested and do work 100% for the latest Poweramp builds.

Also the log from 911 shows that there are no audio focus events, so this API is not used at all by your radio app.

There was a behavior change recently in Android though, not in Poweramp - now when a player app is in background/not playing, Google assistant app intercepts and processes all media key events, redirecting events to the other apps (or not).

Either Assistant intercepted the key or did not is visible from the Full log available in Developer settings (this log has like the last 1 minute of events, so it should be taken immediately after the issue arises). Feel free to send this to gpmaxmpz@gmail.com for the fu

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...