Jump to content

Skip songs problem


moba77
 Share

Recommended Posts

Hi, I've recently restored my Samsung S20 Plus and I can't skip songs when I use Poweramp with Android auto. In past I didn't have this problem. Actually if I use a Bluetooth headphones I can skip with double tap, otherwise with Android auto I can move forward or backward into the songs. It happens when I use steering wheel controls or heading buttons. If I use the touch screen of headunit I can skip song . Here attached command list.

 

Thanks for support ūüėä

 

 

Screenshot_20210322-134135_Poweramp.jpg

Link to comment
Share on other sites

That list seems a bit short, could you provide a fuller list with an explanation of what buttons your pressed a which timecode?

For example there's an END_FAST_FORWARD operation, but without the preceding button presses to say what triggered it. There are also some ACTION_DOWN key events without corresponding ACTION_UP events (and vice versa).

Andre

Link to comment
Share on other sites

5 minutes ago, andrewilley said:

That list seems a bit short, could you provide a fuller list with an explanation of what buttons your pressed a which timecode?

For example there's an END_FAST_FORWARD operation, but without the preceding button presses to say what triggered it. There are also some ACTION_DOWN key events without corresponding ACTION_UP events (and vice versa).

Andre

I've attached more commands

 

https://postimg.cc/47KSXMvN

 

thanks for support

Link to comment
Share on other sites

You can copy the whole Last Processed Commands log to the clipboard to paste it here by the way. Just use the menu icon at the top-right of the Last Processed Commands screen. That might be easier than pasting partial screenshots.

But as Max has said, it does look like Poweramp is just responding to the slightly odd commands that your head-unit is sending, A 'DOWN' key event without an almost-immediate 'UP' event may be treated as a long-press for example (so Fast-Forward or Rewind).

Andre

Link to comment
Share on other sites

16 hours ago, maxmp said:

@moba77 thanks for the log. There are multiple MEDIA_BUTTON_KEY_CODE_NEXT within 600ms after seek command. Poweramp must obey this and switches the track.

Here last command from Poweramp:

 

==================

13:30:47.166 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:47.169 PlayerService BEGIN_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:30:47.171 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:47.173 PlayerService END_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:30:49.254 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:49.258 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:49.261 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:49.262 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:49.264 PlayerService BEGIN_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:30:49.265 PlayerService END_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:30:51.864 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:51.882 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:51.883 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:51.885 PlayerService BEGIN_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:30:51.885 PlayerService END_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:30:51.886 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:53.389 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:53.414 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:53.419 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:53.420 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:53.422 PlayerService BEGIN_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:30:53.422 PlayerService END_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:30:53.717 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:53.718 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:53.721 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:53.725 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:30:53.726 PlayerService BEGIN_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:30:53.728 PlayerService END_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:30:59.061 MediaSessionCallback onPause

com.google.android.projection.gearhead

==================

13:30:59.062 MediaSessionCallback onPause

com.google.android.projection.gearhead

==================

13:32:18.540 BTReceiver headset event

disconnection BT=true am mode=0 EONON no_keep_notif_on_dscn=true

==================

13:32:18.540 BTReceiver cmd_player_remove_notif

 

 

Thanks for support

Link to comment
Share on other sites

Very odd sequence of events from your device there, there seem to be several DOWN events (i.e, indicating that a button has been depressed) followed by several UP events (i.e. the button has now been released). What should happen is one DOWN event is sent, followed almost immediately - maybe a tenth of a second later - by an UP event (saying that a button has been tapped, but not 'long-pressed').

For example, this is roughly what you would expect to see from pressing PLAY, then ">> Next Track", then "<< Previous Track", then PAUSE. This shows the keycode events received via Bluetooth, and Poweramp's subsequent reaction to that command:

PRESS PLAY BUTTON (in fact, PA actually reacted before receiving the button UP event here - presumably as there is no point in waiting for a long-press with a PLAY button) :

14:05:11.598 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=211365831 flags=0x0 playerState=2
==================
14:05:11.615 PlayerService RESUME
from PSMediaButtonReceiver resumePlaying 
==================
14:05:11.676 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PLAY ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=211365908 flags=0x0 playerState=1
==================
14:05:11.679 PlayerService RESUME
from PSMediaButtonReceiver IGNORED

PRESS NEXT TRACK BUTTON:

13:59:51.879 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=211046111 flags=0x0 playerState=1
==================
13:59:51.891 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_NEXT ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=211046124 flags=0x0 playerState=1
==================
13:59:51.908 PlayerService NEXT
from PSMediaButtonReceiver 

PRESS PREVIOUS TRACK BUTTON:

14:05:13.360 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PREVIOUS ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=211367592 flags=0x0 playerState=1
==================
14:05:13.376 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PREVIOUS ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=211367608 flags=0x0 playerState=1
==================
14:05:13.403 PlayerService PREVIOUS
from PSMediaButtonReceiver 

PRESS PAUSE BUTTON:

14:05:19.542 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_DOWN name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=211373774 flags=0x0 playerState=1
==================
14:05:19.575 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON
KEYCODE_MEDIA_PAUSE ACTION_UP name=Virtual source=0x0 sources=0x301 virt=true repeat=0 actionTime=211373807 flags=0x0 playerState=1
==================
14:05:19.590 PlayerService PAUSE
from PSMediaButtonReceiver pausePlaying 

Andre

Link to comment
Share on other sites

Please compare the sequence of key events that are generated when you use the head-unit's on-screen buttons, versus the pressing physics buttons. Do they send a similar pattern of events?

Maybe Max can create a work-around to cope with detecting these somewhat quirky key events?

Andre

Link to comment
Share on other sites

AFAIR, there should be a workaround at the UI level. That is a 'skip n-seconds' button for long tracks. It was in the TODO list. But I do not know whether the latest update (901) may have something to do with this. See also: 

 

Link to comment
Share on other sites

Here commands: I've pressed 4 time skip button on steering wheel (no skip song, only forward) and 4 time on screen button ( ok skip)

 

==================

13:42:47.970 PlayerService BEGIN_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:42:47.971 PlayerService END_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:42:49.164 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:49.168 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:49.170 PlayerService BEGIN_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:42:49.201 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:49.204 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:49.205 PlayerService END_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:42:51.313 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:51.314 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:51.316 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:51.319 PlayerService BEGIN_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:42:51.320 PlayerService END_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:42:51.340 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:52.805 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:52.806 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:52.809 PlayerService BEGIN_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:42:52.816 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:52.824 PlayerService END_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:42:52.850 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:55.051 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:55.052 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_DOWN A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:55.053 PlayerService BEGIN_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:42:55.075 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:55.077 PlayerService END_FAST_FORWARD

from PSMediaButtonReceiver 

==================

13:42:55.089 PSMediaButtonReceiver android.intent.action.MEDIA_BUTTON

KEYCODE_MEDIA_NEXT ACTION_UP A2dpOn isAvrcp flags=0x4 playerState=1

==================

13:42:57.796 MediaSessionCallback onSkipToNext

com.google.android.projection.gearhead

==================

13:43:00.772 MediaSessionCallback onSkipToNext

com.google.android.projection.gearhead

==================

13:43:04.329 MediaSessionCallback onSkipToNext

com.google.android.projection.gearhead

==================

13:43:09.266 MediaSessionCallback onPause

com.google.android.projection.gearhead

==================

13:43:23.092 BTReceiver headset event

disconnection BT=true am mode=0 EONON no_keep_notif_on_dscn=true

==================

13:43:23.092 BTReceiver cmd_player_remove_notif

 

Thanks for support)

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...