Jump to content

Headset skipping/previous track button combos problems when phone is locked


dws_nz

Recommended Posts

On Android 11, Pixel 5

When phone is unlocked and Poweramp is active I can double click headphone button to jump forward a track or triple click to go back to previous track, but when the phone is locked (in my pocket or whatever) the same actions are causing jumping back and forward two tracks. Very irritating. Any clues or fixes?

Link to comment
Share on other sites

  • Replies 57
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

First when screen is locked I clicked once to resume, then dbl clicked forward then triple clicked back (and two tracks were skipped each way)... the final commands were when I'd unlocked the phone and repeated the same experiment (where it worked as expected)

 

==================
10:25:41.399 PlayerService RESUME
from PSMediaButtonReceiver resumePlaying 
==================
10:25:42.942 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=578029 flags=0x40000000 playerState=1
==================
10:25:42.944 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=578032 flags=0x40000000 playerState=1
==================
10:25:43.185 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=578274 flags=0x40000000 playerState=1
==================
10:25:43.187 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=578275 flags=0x40000000 playerState=1
==================
10:25:43.427 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=578515 flags=0x40000000 playerState=1
==================
10:25:43.428 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=578517 flags=0x40000000 playerState=1
==================
10:25:43.439 PlayerService PREVIOUS
from PSMediaButtonReceiver 
==================
10:25:43.645 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PREVIOUS ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=578734 flags=0x40000000 playerState=1
==================
10:25:43.645 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PREVIOUS ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=578734 flags=0x40000000 playerState=1
==================
10:25:44.270 PlayerService PREVIOUS
from PSMediaButtonReceiver 
==================
10:25:50.030 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=585118 flags=0x40000000 playerState=1
==================
10:25:50.033 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=585120 flags=0x40000000 playerState=1
==================
10:25:50.643 PlayerService TOGGLE_PLAY_PAUSE
from PSMediaButtonReceiver pausePlaying 
==================
10:25:59.785 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=594862 flags=0x8 playerState=2
==================
10:25:59.786 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=594869 flags=0x8 playerState=2
==================
10:25:59.790 PlayerService RESUME
from PSMediaButtonReceiver resumePlaying 
==================
10:26:02.366 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=597449 flags=0x8 playerState=1
==================
10:26:02.505 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=597589 flags=0x8 playerState=1
==================
10:26:02.547 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=597629 flags=0x8 playerState=1
==================
10:26:02.714 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=597789 flags=0x8 playerState=1
==================
10:26:03.341 PlayerService NEXT
from PSMediaButtonReceiver 
==================
10:26:08.110 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=603190 flags=0x8 playerState=1
==================
10:26:08.246 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=603329 flags=0x8 playerState=1
==================
10:26:08.328 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=603409 flags=0x8 playerState=1
==================
10:26:08.427 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=603510 flags=0x8 playerState=1
==================
10:26:08.507 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=603589 flags=0x8 playerState=1
==================
10:26:08.651 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=603730 flags=0x8 playerState=1
==================
10:26:08.662 PlayerService PREVIOUS
from PSMediaButtonReceiver 
==================
10:26:14.239 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=609311 flags=0x8 playerState=1
==================
10:26:14.406 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=609490 flags=0x8 playerState=1
==================
10:26:15.018 PlayerService TOGGLE_PLAY_PAUSE
from PSMediaButtonReceiver pausePlaying 

Link to comment
Share on other sites

For clarity I repeated the same experiment starting at 10:35 just with the phone locked with the intent to single click Pause, then Resume - then dbl click the skip track, then triple click jump back a track 

 

 

==================
10:35:04.087 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1139175 flags=0x40000000 playerState=1
==================
10:35:04.090 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1139178 flags=0x40000000 playerState=1
==================
10:35:04.701 PlayerService TOGGLE_PLAY_PAUSE
from PSMediaButtonReceiver pausePlaying 
==================
10:35:09.232 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1144319 flags=0x40000000 playerState=2
==================
10:35:09.238 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1144325 flags=0x40000000 playerState=2
==================
10:35:09.245 PlayerService RESUME
from PSMediaButtonReceiver resumePlaying 
==================
10:35:12.729 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1147818 flags=0x40000000 playerState=1
==================
10:35:12.730 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1147819 flags=0x40000000 playerState=1
==================
10:35:12.957 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1148045 flags=0x40000000 playerState=1
==================
10:35:12.958 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1148047 flags=0x40000000 playerState=1
==================
10:35:13.589 PlayerService NEXT
from PSMediaButtonReceiver 
==================
10:35:13.592 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1148680 flags=0x40000000 playerState=1
==================
10:35:13.594 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1148682 flags=0x40000000 playerState=1
==================
10:35:14.213 PlayerService NEXT
from PSMediaButtonReceiver 
==================
10:35:20.554 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1155641 flags=0x40000000 playerState=1
==================
10:35:20.557 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1155645 flags=0x40000000 playerState=1
==================
10:35:20.780 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1155869 flags=0x40000000 playerState=1
==================
10:35:20.781 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1155870 flags=0x40000000 playerState=1
==================
10:35:21.000 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1156089 flags=0x40000000 playerState=1
==================
10:35:21.000 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1156089 flags=0x40000000 playerState=1
==================
10:35:21.009 PlayerService PREVIOUS
from PSMediaButtonReceiver 
==================
10:35:21.219 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PREVIOUS ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1156308 flags=0x40000000 playerState=1
==================
10:35:21.219 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PREVIOUS ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1156309 flags=0x40000000 playerState=1
==================
10:35:21.848 PlayerService PREVIOUS
from PSMediaButtonReceiver 

Link to comment
Share on other sites

And here is the same actions when the phone was unlocked at 10:46 - intent single click Pause, Resume - then dbl click skip track, then triple click back 


10:46:00.981 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=1796056 flags=0x8 playerState=1
==================
10:46:01.156 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=1796235 flags=0x8 playerState=1
==================
10:46:01.763 PlayerService TOGGLE_PLAY_PAUSE
from PSMediaButtonReceiver pausePlaying 
==================
10:46:05.540 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=1800616 flags=0x8 playerState=2
==================
10:46:05.550 PlayerService RESUME
from PSMediaButtonReceiver resumePlaying 
==================
10:46:05.672 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=1800755 flags=0x8 playerState=1
==================
10:46:07.881 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=1802956 flags=0x8 playerState=1
==================
10:46:08.016 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=1803095 flags=0x8 playerState=1
==================
10:46:08.092 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=1803175 flags=0x8 playerState=1
==================
10:46:08.236 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=1803315 flags=0x8 playerState=1
==================
10:46:08.860 PlayerService NEXT
from PSMediaButtonReceiver 
==================
10:46:15.759 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=1810835 flags=0x8 playerState=1
==================
10:46:15.875 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=1810952 flags=0x8 playerState=1
==================
10:46:15.949 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=1811032 flags=0x8 playerState=1
==================
10:46:16.096 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=1811172 flags=0x8 playerState=1
==================
10:46:16.214 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=1811293 flags=0x8 playerState=1
==================
10:46:16.351 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Google Pixel USB-C earbuds source=0x101 virt=false repeat=0 actionTime=1811433 flags=0x8 playerState=1
==================
10:46:16.364 PlayerService PREVIOUS
from PSMediaButtonReceiver 
 

Link to comment
Share on other sites

TLDR; When unlocked I see the text name=Google Pixel USB-C earbuds source=0x101 virt=false  in the button presses and things work properly...

and when phone is locked I see additional repeated ghost commands and only the following in the button presses  name=Virtual source=0x0 sources=0x301 virt=true

 

Something odd going on

Edited by dws_nz
just added clarification
Link to comment
Share on other sites

  • 3 weeks later...

Hi all,

i have exactly the same issue, when Poweramp is playing with the phone unlocked in full screen, everything is going fine.

When Poweramp is running in background or with the phone locked, same pb than dws_nz.

it happens only with a wired headset, with a bluetooth headset it's working fine.

I have a galaxy S10+.

Thanks for your help.

Link to comment
Share on other sites

Since the last Android OTA update on my phone (Samsung Galaxy A70, Android 11, 1-April-2021 patch level) I've been having similar issues with wired headset buttons failing to trigger the correct actions while the screen is off. Everything works fine with Poweramp visible in the foreground, but as soon as the screen goes to sleep or PA is running in the background, headset button clicks seem to arrive at PA delayed or even in the wrong order.

For example with Poweramp on screen, these are the expected responses for double-click and triple-click on the hook button. As you can see, the physical DOWN/UP events for each click arrive around quarter of a second apart.

Double-click:

==================
11:13:35.718 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_HEADSETHOOK ACTION_DOWN name=sm6150-idp-snd-card Button Jack source=0x101 virt=false repeat=0 actionTime=41051496 flags=0x8 playerState=1
==================
11:13:35.722 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_HEADSETHOOK ACTION_UP name=sm6150-idp-snd-card Button Jack source=0x101 virt=false repeat=0 actionTime=41051496 flags=0x8 playerState=1
==================
11:13:35.987 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_HEADSETHOOK ACTION_DOWN name=sm6150-idp-snd-card Button Jack source=0x101 virt=false repeat=0 actionTime=41051762 flags=0x8 playerState=1
==================
11:13:35.994 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_HEADSETHOOK ACTION_UP name=sm6150-idp-snd-card Button Jack source=0x101 virt=false repeat=0 actionTime=41051763 flags=0x8 playerState=1
==================
11:13:36.659 PlayerService NEXT
from PSMediaButtonReceiver 

Triple-click:

==================
11:13:31.316 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_HEADSETHOOK ACTION_DOWN name=sm6150-idp-snd-card Button Jack source=0x101 virt=false repeat=0 actionTime=41047084 flags=0x8 playerState=1
==================
11:13:31.324 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_HEADSETHOOK ACTION_UP name=sm6150-idp-snd-card Button Jack source=0x101 virt=false repeat=0 actionTime=41047084 flags=0x8 playerState=1
==================
11:13:31.596 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_HEADSETHOOK ACTION_DOWN name=sm6150-idp-snd-card Button Jack source=0x101 virt=false repeat=0 actionTime=41047347 flags=0x8 playerState=1
==================
11:13:31.600 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_HEADSETHOOK ACTION_UP name=sm6150-idp-snd-card Button Jack source=0x101 virt=false repeat=0 actionTime=41047347 flags=0x8 playerState=1
==================
11:13:31.854 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_HEADSETHOOK ACTION_DOWN name=sm6150-idp-snd-card Button Jack source=0x101 virt=false repeat=0 actionTime=41047606 flags=0x8 playerState=1
==================
11:13:31.868 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_HEADSETHOOK ACTION_UP name=sm6150-idp-snd-card Button Jack source=0x101 virt=false repeat=0 actionTime=41047607 flags=0x8 playerState=1
==================
11:13:31.890 PlayerService PREVIOUS
from PSMediaButtonReceiver 


However with the screen OFF, those same actions seem to get mashed up impossibly close together, occasionally even arriving in the wrong order completely, and thus PA misinterprets them.

Double-click with screen OFF - gets treated as a single-click (Pause):

==================
12:54:17.193 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1217887 flags=0x40000000 playerState=1
==================
12:54:17.195 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1217889 flags=0x40000000 playerState=1
==================
12:54:17.197 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1217890 flags=0x40000000 playerState=1
==================
12:54:17.198 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1217892 flags=0x40000000 playerState=1
==================
12:54:17.210 PlayerService TOGGLE_PLAY_PAUSE
from PSMediaButtonReceiver pausePlaying 

Triple-click with screen OFF - gets treated as a single-click (Resume):

==================
12:54:30.626 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PREVIOUS ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1223695 flags=0x40000000 playerState=2
==================
12:54:30.628 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1223698 flags=0x40000000 playerState=2
==================
12:54:30.631 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PREVIOUS ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1223700 flags=0x40000000 playerState=2
==================
12:54:30.633 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1223702 flags=0x40000000 playerState=2
==================
12:54:48.082 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1230748 flags=0x40000000 playerState=2
==================
12:54:48.125 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=1230794 flags=0x40000000 playerState=2
==================
12:54:48.386 PlayerService RESUME
from PSMediaButtonReceiver resumePlaying 

Double-click with screen OFF - the events arrive out of order so nothing happens at all:

==================
12:29:05.675 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=686591 flags=0x40000000 playerState=1
==================
12:29:05.676 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=686594 flags=0x40000000 playerState=1
==================
12:29:05.678 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=686596 flags=0x40000000 playerState=1
==================
12:29:05.679 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=686597 flags=0x40000000 playerState=1

Double-click with screen on the Home page rather than in PA - events also out of order, and PA skips to the Next track and then Pauses:

==================
19:05:34.784 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=13050628 flags=0x40000000 playerState=1
==================
19:05:34.793 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=13050639 flags=0x40000000 playerState=1
==================
19:05:34.795 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=13050641 flags=0x40000000 playerState=1
==================
19:05:34.796 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=13050643 flags=0x40000000 playerState=1
==================
19:05:34.816 PlayerService NEXT
from PSMediaButtonReceiver 
==================
19:05:35.403 PlayerService TOGGLE_PLAY_PAUSE
from PSMediaButtonReceiver pausePlaying 


Max, any ideas, can you duplicate this issue? It has only started happening with the most recent OTA Android updates.

Andre

Link to comment
Share on other sites

Hi, currently, I have the same issue with my phone Xiaomi 9T Pro, android 10.

When I double press, Poweramp pauses instead of playing next song. Only happen when device is locked or Poweramp is running in background.

I've never met this issue before. 😢

Link to comment
Share on other sites

I have this problem  too. Using the wired headset (any of various) when the phone has the lockscreen engaged, a double-click results in a pause action instead of a skip. A triple click is the same. But sometimes it skips to the next song, and pauses at the same time. I have to click again to get the song to play. The beeps are confused, sometimes only one, sometimes both together, sometimes none at all, and no action. Sometimes I pause, and it takes a, couple of seconds for the command to be processed. This did NOT happen before v905-uni. I enter settings, and set skip to long click, then back to double-click again, and it works OK for a couple of songs, then back to the problem again. 

Double-click works with the rest of my audio apps: Smart Audiobook player, Black player, Spotify, just not PA. 

Moto G9 plus, Android 10. But there haven't been any recent updates to Android, not even a security update since March, and the problem is more recent. 

Link to comment
Share on other sites

3 hours ago, gmandese said:

This did NOT happen before v905-uni.

I had put this down to my Android 11 OTA update, but as it is being independently reported by people on Android 10 too, I'm wondering if it's something to do with PA 905 as that update happened at roughly the same time.

@maxmp there is definitely something strange going on here, as per my logs above - can you duplicate it?

Andre

Link to comment
Share on other sites

Thanks for the reports. Probably, when phone is locked, android headset button handler or some other intermediate component runs on very low priority or otherwise throttled and player doesn’t get events in time to consider multiple clicks as double or triple.

May be increasing double/triple click time window will help for these devices - will be added to the next beta.

Link to comment
Share on other sites

It's not only when the phone is locked, it can also happen when PA is not the front app.

And it's not just that clicks are delayed and appear to arrive within a few milliseconds of each other, sometimes the clicks turn up in PA's list in the wrong sequence completely, such as this double-click:

==================
19:05:34.784 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=13050628 flags=0x40000000 playerState=1
==================
19:05:34.793 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=13050639 flags=0x40000000 playerState=1
==================
19:05:34.795 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=13050641 flags=0x40000000 playerState=1
==================
19:05:34.796 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=13050643 flags=0x40000000 playerState=1

Have a look at my earlier post for other examples. Let me know if I can provide any other log data.

Andre

Link to comment
Share on other sites

I noticed that PA and PA Equalizer both have the battery being optimized in the Android system. I'm going to try something as a test. I'll disable the optimization to see if it makes a difference. At least as, a workaround. But it'll have to wait for a bit, I don't have any wired headphones with me. 

Edit: didn't make any difference. 

Edited by gmandese
Update to message
Link to comment
Share on other sites

button not responding when lock screen triggered(screen off).

 pressing twice the button on wired headset when screen is off tends to pause only the current song. pressing once does not do anything. thrice only pause then immediately playing the song. this problem was not present on PA earlier version.

tried the fresh installation seems cannot solve the problem.

i'm using PA 905 uni.

stock rom, not rooted.

Asus Device running android 9.0

Screenshot_20210601-061917964_1.jpg

Link to comment
Share on other sites

I noticed exactly the same issue on my Samsung A71 running Android 11 - double and triple clicks on a wired headset don't work as intended when Poweramp is not the front app (even when phone is unlocked)

Other aps like Podcast Addict or Spotify work fine.

 

Thanks

Bart

Link to comment
Share on other sites

Что-то вы изменили, видимо, стало совсем все плохо.

Тело - Xperia XZ1 Compact. Прошивка стандартная, не рутованная. Уши - Sony mdr-1a. Двойной клик кнопки на гарнитуре в 99% распознается как одинарный, тройной - то же самое.

Сначала грешил на свои уши - точнее, на кнопку на гарнитуре, но нет - при включенном экране все распознается и переключается корректно.

Переключать треки с кнопки на кабеле теперь просто невозможно.

 

Google Translation:

You have changed something, apparently, everything has become very bad.

Body - Xperia XZ1 Compact. The firmware is standard, not rooted. Ears - Sony mdr-1a. A double click of a button on the headset is 99% recognized as a single, triple - the same.

At first I sinned on my ears - more precisely, on the button on the headset, but no - when the screen is on, everything is recognized and switches correctly.

Switching tracks from the button on the cable is now simply impossible.

Edited by andrewilley
Added translation
Link to comment
Share on other sites

What Android version?

A number of people have reported the same problem recently, please also see: 

 

The results from PA Settings > Headset/Bluetooth > Last Processed Commands might help diagnose, just after you double-click the button.

Andre

Link to comment
Share on other sites

Android 9

Screen turned off:

==================
11:10:41.696 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=97126488 flags=0x40000000 playerState=1
==================
11:10:41.700 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=97126494 flags=0x40000000 playerState=1
==================
11:10:41.705 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=97126497 flags=0x40000000 playerState=1
==================
11:10:41.709 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=97126502 flags=0x40000000 playerState=1
==================
11:10:41.718 PlayerService TOGGLE_PLAY_PAUSE
from PSMediaButtonReceiver pausePlaying

 

Unlocked screen:

==================
11:11:46.370 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_HEADSETHOOK ACTION_DOWN name=msm8998-tasha-snd-card Button Jack source=0x101 virt=false repeat=0 actionTime=97191158 flags=0x8 playerState=1
==================
11:11:46.383 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_HEADSETHOOK ACTION_UP name=msm8998-tasha-snd-card Button Jack source=0x101 virt=false repeat=0 actionTime=97191158 flags=0x8 playerState=1
==================
11:11:46.619 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_HEADSETHOOK ACTION_DOWN name=msm8998-tasha-snd-card Button Jack source=0x101 virt=false repeat=0 actionTime=97191407 flags=0x8 playerState=1
==================
11:11:46.637 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_HEADSETHOOK ACTION_UP name=msm8998-tasha-snd-card Button Jack source=0x101 virt=false repeat=0 actionTime=97191407 flags=0x8 playerState=1
==================
11:11:47.251 PlayerService NEXT
from PSMediaButtonReceiver

Both are double taps.

Link to comment
Share on other sites

Merged new report into existing thread.

@maxmp Any progress on tracking this down? It does not seem to be Android version related (which I had initially assumed, however users on 9, 10 and 11 have now reported it) but something that has happened fairly recently in a Poweramp update.

Andre

Link to comment
Share on other sites

i had this problem too.

button is not responding properly when screen is off.

tried to seek last command logs but it seems does not log the problem. it logs only the surface of the problem but when screen lock triggers button headset does not responding accordingly.

 

this problem is not present on 903-904, but has problem regarding skip track using volume button.

 

905 fixed the skip track by volume button but triggers the problem on wired/Bluetooth headset button

Link to comment
Share on other sites

I had this problem too. when the screen is off, the wired headset button does not work,  same as the problem described above

Have tried to installed several older versions (version 8XX) and tested , still have the same problems.

I have this problem after OTA update from android 10 to android 11,  My phone is Samsung Galaxy M31 .

Link to comment
Share on other sites

Yeah i bougut this player today, and have same issue - if player is on background, then headset button not working propertly, only pause/play working, and on other players i don't have this issue.

 

==================
17:38:48.801 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174714724 flags=0x40000000 playerState=2
==================
17:38:48.808 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174714731 flags=0x40000000 playerState=2
==================
17:38:48.816 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174714739 flags=0x40000000 playerState=2
==================
17:38:49.081 PlayerService TOGGLE_PLAY_PAUSE
from PSMediaButtonReceiver resumePlaying 
==================
17:38:51.539 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174717462 flags=0x40000000 playerState=1
==================
17:38:51.543 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174717465 flags=0x40000000 playerState=1
==================
17:38:51.546 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174717468 flags=0x40000000 playerState=1
==================
17:38:51.551 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174717472 flags=0x40000000 playerState=1
==================
17:38:54.012 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174719935 flags=0x40000000 playerState=1
==================
17:38:54.018 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174719941 flags=0x40000000 playerState=1
==================
17:38:54.024 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174719944 flags=0x40000000 playerState=1
==================
17:38:54.036 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174719958 flags=0x40000000 playerState=1
==================
17:38:54.047 PlayerService NEXT
from PSMediaButtonReceiver 
==================
17:38:54.646 PlayerService TOGGLE_PLAY_PAUSE
from PSMediaButtonReceiver pausePlaying 
==================
17:38:58.169 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174724092 flags=0x40000000 playerState=2
==================
17:38:58.175 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY_PAUSE ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174724097 flags=0x40000000 playerState=2
==================
17:38:58.179 PlayerService RESUME
from PSMediaButtonReceiver resumePlaying 
==================
17:39:00.236 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174726159 flags=0x40000000 playerState=1
==================
17:39:00.243 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174726163 flags=0x40000000 playerState=1
==================
17:39:00.246 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174726168 flags=0x40000000 playerState=1
==================
17:39:00.249 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174726172 flags=0x40000000 playerState=1
==================
17:39:00.267 PlayerService TOGGLE_PLAY_PAUSE
from PSMediaButtonReceiver pausePlaying 
==================
17:39:03.820 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174729742 flags=0x40000000 playerState=2
==================
17:39:03.828 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174729748 flags=0x40000000 playerState=2
==================
17:39:03.831 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174729753 flags=0x40000000 playerState=2
==================
17:39:03.835 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174729757 flags=0x40000000 playerState=2
==================
17:39:03.850 PlayerService TOGGLE_PLAY_PAUSE
from PSMediaButtonReceiver resumePlaying 
==================
17:39:06.866 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174732789 flags=0x40000000 playerState=1
==================
17:39:06.870 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174732792 flags=0x40000000 playerState=1
==================
17:39:06.872 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174732794 flags=0x40000000 playerState=1
==================
17:39:06.874 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=174732796 flags=0x40000000 playerState=1
==================
17:39:08.771 PlayerService TOGGLE_PLAY_PAUSE
from NotificationHelperViaBuilder pausePlaying 

 

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...