Back to Top

Audio starts up again after BT disconnect

9 posts / 0 new
Last post
jonathono
Offline
Last seen: 8 years 2 months ago
Joined: 02/03/2012 - 12:53
Audio starts up again after BT disconnect

I have a reproducible bug with my Ford Sync. 90% of the time I can get out of my car after using DC over BT and the audio will automatically resume some time after the disconnect. I've tried different settings in DC but it still occurs. Some times I'll pause it after it resumes and it will resume again. It's not likely that it is getting another button push command since I am well away from my shut off car stereo. I'm using Cyanogenmod 10.2.1 (4.3), on a rooted Galaxy Nexus. Yes I have a lot of apps running so it could be a focus issue, but this has become frustrating. I'd like to keep DC on my phone since I want to be able to take calls over BT but the audio starting up at a random amount of time after disconnect can be embarrassing as I unlock my phone to stop the audio. (The onscreen button also usually doesn't respond when this is happening.) I also use variable speed playback. Just want this to be fixed, how can I help? I really like Doggcatcher.

I've been trying to catch this using logcat, and reading after reading the forums I'll be submitting logs through the app. My current log didn't show the issue, but I will reproduce the issue tomorrow and send the log. Here's the most relevant entry I found in logcat:
W/ActivityManager( 410): Activity pause timeout for ActivityRecord{4208e3a0 u0 com.snoggdoggler.android.applications.doggcatcher.v1_0/com.doggcatcher.activity.nowplaying.NowPlayingActivity}

WayneC
Offline
Last seen: 1 month 5 days ago
Joined: 02/23/2011 - 22:28
Check the "Event Log" (In the

Check the "Event Log" (In the DC Navigation Menu) right after the problem happens again to verify if DC is receiving “Play/Pause” event from a BT Headset/device.
Try deleting the BT pairing from you mobile device & the Ford Sync head unit, then re-pair the BT connection again. The problem could also be caused by another app like PowerAmp,

jonathono
Offline
Last seen: 8 years 2 months ago
Joined: 02/03/2012 - 12:53
Event log

Sat, 31 May 2014 17:54:04 -0500 INFO (29022) AudioFocusListener::Focus change: -3
Sat, 31 May 2014 17:54:04 -0500 INFO (29022) Playlist::Updating playlist: All - Sorted by feed/date -> done - [**656ms**]
Sat, 31 May 2014 17:54:04 -0500 INFO (29022) ChannelUpdateThread::Fetching Feed http://feeds.feedburner.com/HanselminutesCompleteMP3
Sat, 31 May 2014 17:54:04 -0500 INFO (29022) NewsList::Refreshing news list -> calculated playlist [5ms] -> 34 articles - [**5ms**]
Sat, 31 May 2014 17:54:05 -0500 INFO (29022) ChannelSorter::Sorting channel with 20 episodes - [1ms]
Sat, 31 May 2014 17:54:05 -0500 INFO (29022) AudioPauser::Resuming due to gained audio focus
Sat, 31 May 2014 17:54:05 -0500 INFO (29022) ChannelFetcher::fetchChannel() -> fetching feed xml [324ms] -> parsing feed [228ms] - [618ms]
Sat, 31 May 2014 17:54:05 -0500 INFO (29022) HeadsetButtonBroadcastReceiver::Registering media button receiver
Sat, 31 May 2014 17:54:05 -0500 INFO (29022) DoggCatcherWidgetProvider::Updating widget - [262ms]
Sat, 31 May 2014 17:54:05 -0500 INFO (29022) AndroidUtil::WakeLock acquired: [flags: 1] [lockName: AudioPlayingWakeLock] [timeout: -1]WakeLock{41a55630 held=true, refCount=1}
Sat, 31 May 2014 17:54:05 -0500 INFO (29022) MediaPlayerController::Prepared - [305ms]
Sat, 31 May 2014 17:54:05 -0500 INFO (29022) AudioFocusListener::Requesting audio focus
Sat, 31 May 2014 17:54:05 -0500 INFO (29022) MediaPlayerController::PlayOrPause - [title: #1420: Eggs Prestone position: 434651] -> VariableSpeedMediaPlayer [8ms] - [321ms]
Sat, 31 May 2014 17:54:05 -0500 INFO (29022) AudioFocusListener::Focus change: 1
Sat, 31 May 2014 17:54:05 -0500 INFO (29022) DoggCatcherService::KeepAliveCount: 7 -

WayneC
Offline
Last seen: 1 month 5 days ago
Joined: 02/23/2011 - 22:28
The log shows DC losing

The log shows DC losing audio focus & regaining focus, the problem you're experiencing could be caused by an app with headset priority set higher than 0 - check the "About" screen (In the DC Menu) if one app is higher than 0 - uninstall to see if that resolves the problem.

jonathono
Offline
Last seen: 8 years 2 months ago
Joined: 02/03/2012 - 12:53
Headset Priority

Flipboard - 0
Amazon MP3 - 0
Google Play Music - 0
Pandora - 0
DoggCatcher - 0

I removed everything there but DoggCatcher. I think it may be the notification sounds causing this. What priority do they have?
The audio should be stopped or paused when this is happening. Why is Doggcatcher automatically playing after regaining focus?

WayneC
Offline
Last seen: 1 month 5 days ago
Joined: 02/23/2011 - 22:28
That's how Android is set to

That's how Android is set to do, when an app loses focus and then regains focus it will start playback at the last paused position.
Try changing the "Play Audio" settings to "Disabled" and "Connect Screen" to "None", then disable "Stat Application" in DC's headset settings (In the DC Menu>Settings>Headset/Lockscreen "Bluetooth/Wired")

Then disable “OK Google” Hotword Detection" Press Google Now>Menu>Settings>Voice>"OK Google” Hotword Detection>Disable

If you run another log with aLogcat or press "Report Problem" (In the DC Menu) right after the problem happens again

here is sample entry of what to look for
03-20 17:15:38.008 I/DoggCatcher(16263): HeadsetButtonBroadcastReceiver::HeadsetButton: Processing play/pause, outside of connect quiet period: 497514
03-20 17:15:38.008 I/DoggCatcher(16263): EventLogAdapter::Application log: Event: Headset event - BUTTON_PRESS - [Button: headset_button_play_pause] [action: PLAY_PAUSE]

jonathono
Offline
Last seen: 8 years 2 months ago
Joined: 02/03/2012 - 12:53
I had "Play Audio" disabled.

I had "Play Audio" disabled. I changed "Connect Screen" to "None" and disabled "Start Application". I've also disabled OK Google. The connect screen and start application settings are obvious settings I hadn't tried. This might be the fix. I do have button press events in the log, around the time this happened yesterday.
Sat, 31 May 2014 17:53:07 -0500 INFO (29022) HeadsetButtonBroadcastReceiver::HeadsetButton: Processing play/pause, outside of connect quiet period: 1356318
Sat, 31 May 2014 17:53:07 -0500 INFO (29022) EventLogAdapter::Application log: Event: Headset event - BUTTON_PRESS - [Button: headset_button_play_pause] [action: PLAY_PAUSE]
Exception:
Sat, 31 May 2014 17:53:07 -0500 INFO (29022) HeadsetObservers::com.snoggdoggler.android.mediaplayer.headset.HeadsetEvent@421bb380 - [Button: headset_button_play_pause] [action: PLAY_PAUSE]

Maybe the button press occurs/registers as the phone disconnects from SYNC? Then it takes a moment for the phone to process. There is definitely no headset connected when the audio resumes. The phone is very slow to respond when this issue occurs so it's possible the action is in queue.

jonathono
Offline
Last seen: 8 years 2 months ago
Joined: 02/03/2012 - 12:53
I sent some logs to support

I sent some logs to support@doggcatcher.com from yesterday. I tried to catch the logs right after the audio resumed, the events at the end of the log should be most relevant, but the problem had occurred several times yesterday.

jonathono
Offline
Last seen: 8 years 2 months ago
Joined: 02/03/2012 - 12:53
So far so good. The changes

So far so good. The changes you suggested seem to have solved the audio starting back up problem. I did have one instance where the audio didn't stop on disconnect, but I can deal with that. It's the starting up that's more frustrating.