[Q] A2DP bluetooth autoconnect immediately disconnects? - Samsung Galaxy Nexus

Hi, I've got a small issue with my bluetooth a2dp device. The device is this one:
BlackBerry Remote Stereo Bluetooth Gateway. It is made by RIM, but works with any device supporting a2dp. My issue with the Galaxy Nexus is that it no longer auto connects.
My setup is in my vehicle, I keep the bluetooth receiver connected to the aux power jack and aux audio in in the center console. This way, when I start the car, the receiver powers up and tries to auto-connect to the last device. On my vibrant with Android 2.1/2.2 this worked fine. When I dabbled with CyanogenMod and some other custom roms, it stopped working but I chalked it up to some problem with the custom rom.
Now, I'm seeing the same sort of problem: if I keep the screen of my nexus on, I can see the bluetooth icon change blue, and then immediately change back to gray. To me, this indicates that the receiver succeeds in connecting but is then disconnected for some reason. The device only supports a2dp, not the handsfree profile. When I looked into the Android kernel code, I found a place where the kernel will try to connect the handsfree profile if the a2dp profile is auto-connected, but it wasn't clear if that was the actual problem or not.
Anyone else have any similar experiences?

I have the same device in my 2008 Accord coupe which is placed in the center arm console. I had an Evo 3D that would automatically connect when I would start the car and BT was already enabled on my phone. I too switched to a different ROM and would have issues auto connecting so I switched back to a different ROM. Now on my stock GN, I have to manually go into settings and click the device to connect. I see no settings about auto connecting when in range. I will have to see if the BT icon turns blue and then back to gray... haven't looked for that. If anyone has thoughts on this, I'm all ears!!

bigdawgr6 said:
I have the same device in my 2008 Accord coupe which is placed in the center arm console. I had an Evo 3D that would automatically connect when I would start the car and BT was already enabled on my phone. I too switched to a different ROM and would have issues auto connecting so I switched back to a different ROM. Now on my stock GN, I have to manually go into settings and click the device to connect. I see no settings about auto connecting when in range. I will have to see if the BT icon turns blue and then back to gray... haven't looked for that. If anyone has thoughts on this, I'm all ears!!
Click to expand...
Click to collapse
I suspect it has something to do with Android's attempts to auto connect to the headset profile when a A2DP profile is connected.
See:
# Automatically connect both A2DP and HFP/HSP profiles for incoming
# connections. Some headsets that support both profiles will only connect the
# other one automatically so the default setting of true is usually a good
# idea.
#AutoConnect=true
Click to expand...
Click to collapse
from https://github.com/android/platform_system_bluetooth/blob/master/data/audio.conf
I have seen the code where this happens and it seemed that if the headset profile failed to connect, the A2DP connection was also disconnected. Though, I can't recall what file it was.

jjohns63 said:
I suspect it has something to do with Android's attempts to auto connect to the headset profile when a A2DP profile is connected.
See:
from https://github.com/android/platform_system_bluetooth/blob/master/data/audio.conf
I have seen the code where this happens and it seemed that if the headset profile failed to connect, the A2DP connection was also disconnected. Though, I can't recall what file it was.
Click to expand...
Click to collapse
Strangely enough, the phone paired with the device twice without issue yesterday and failed once later on that same day. I'm toggling BT off and then on to get connection for now.

It seems like the phone and device are connecting without issue but I know I haven't done anything to change it. I'm on AOKP M3 and Leankernel V1.8 if that helps. When I first flashed those two, I still had connections issues, so switching to them wasn't a resolution.

I am not sure this really helps your issue but it is related. I wrote an app that will auto-connect Bluetooth devices. It is free on the market and is called A2DP Volume. The current implementation of auto-connect looks for one device connection and then connects another. I started another widget that will simply connect a Bluetooth device but I have not finished that one. A2DP Volume is free, open source, and ad free. You can find the open source project on Google Code. Just search for A2DP Volume.

I have been trying this for weeks and this app solved it!!! Thanks for making the app!
jroal said:
I am not sure this really helps your issue but it is related. I wrote an app that will auto-connect Bluetooth devices. It is free on the market and is called A2DP Volume. The current implementation of auto-connect looks for one device connection and then connects another. I started another widget that will simply connect a Bluetooth device but I have not finished that one. A2DP Volume is free, open source, and ad free. You can find the open source project on Google Code. Just search for A2DP Volume.
Click to expand...
Click to collapse

jjohns63 and bigdawgr6,
Any update on this problem? I don't have the Nexus, but I have Droid Incredible 2. I also run into the same problem when I use CyanogenMod 7.2, which is a AOSP based ROM. The connection is fine with the stock ROM. I have tried to change things in the audio.config but it does not seem to help. I think I ran into a post somewhere saying HTC stock ROM uses a propietary bluetooth stack and AOSP and CyanogenMod uses BlueZ open source stack, and that is where the problem is.
Anyway, it would be nice if you guys can share some info.
Thanks!

Related

[Q] Bluetooth Upgared / Fix

can anyone tell me if I can update the Bluetooth in my HTC Desire or have more profiles. the phone is branded o2 but can be rooted. I dont want to change anything else in the ROM just make the bluetooth connect automaticaly & reliably to the car.
There are newer software builds available but have no mention of updating bluetooth.
Ther are no OTA updates available.
Software Number is 2.14.207.1
Andriod 2.2
Thanks for any advice in advance.
Trampsdad
Can't you just pair the 2 devices together? I personally don't use Bluetooth so no idea on that aspect. Also, the software is so out of date because o2 cba to release and update. There are major updates since yours. It might be worth considering to root so then you can flash a newer ROM, or infact, you don't need to root and just use an RUU. With the newest software. No need to root it then and less chance of it mess up.
Hope this helps
I still have some strangeness with Bluetooth. From what I read there are some updates in Honeycomb and maybe gingerbread. But I don't have a feeling what you are looking for is in FroYo
Sent from my HTC Desire using XDA App
Well I have a Kenwood Headunit with Bluetooth and the connection to that using stock Froyo and LeeDroid showed some interesting results. Gaps in the phonebook for instance. However, putting a 2.3 ROM (Ginger Villain) sorted that out, its fine now.
Bluetooth depends on the other device too.
What exactly is the problem you are having?
What Car do you have?
What Bluetooth system is installed (is it standard)?
I have used my desire in a number of cars (Vauxhall, Ford, BMW) without any isses with pairing, using the Phonebook,etc. is a different matter.
Personally, I have just received a new BMW 528i, and it doesn't get on well with my Desire at all.
It pairs OK and can use both the phone and music, but when I leave and return to the car, it just refuses to auto-connect again, and I have to go through the pairing procedure again.
Oh, except one - the time I went back to the garage to 'complain' about it and ask for advice, when it worked perfectly. Until I got home again!
Have experimented with my old Nokia N85, and that works fine, too. So it's either the Desire or an incompatibility between it and the car.
Oh, my Desire is running MCR r9 (FroYo) at the moment. Are there known issues with this? Info on any Bluetooth updates I could apply would be gratefully received!
i have to enter my pairing code every time i connect my bt headset - i took this to be a quirk for the moment - hoping its fixed in 2.2.2/2.3.x etc.
Lothaen said:
i have to enter my pairing code every time i connect my bt headset - i took this to be a quirk for the moment - hoping its fixed in 2.2.2/2.3.x etc.
Click to expand...
Click to collapse
Im having this same problem also with a Pioneer Head Unit in my car.
Bluetooth has always been troublesome as it doesn't auto connect. It will connect if I either manually click on "Pioneer Head Unit" or turn Bluetooth off and on (which I automate with tasker).
The pin thing is new and happens with all roms I have tried except LeeDroid, (which I prefer not to use as I don't like sense much). Leedroid still has the auto connect problem.
daveaus said:
Bluetooth has always been troublesome as it doesn't auto connect. It will connect if I either manually click on "Pioneer Head Unit" or turn Bluetooth off and on (which I automate with tasker).
Click to expand...
Click to collapse
Some good hints there - thanks!
I can connect far more reliably if I initiate the connection from the phone than from the car.
Likewise, if BT is switched off on the phone and then turned on after the car is on, then it sometimes works, too. Certainly don't need to re-pair anywhere near as often.
Can I ask how you use Tasker to automate the BT switching? I've not used that (I use Setting Profiles instead which I understand does roughly the same thing), so am curious what kind of rule you have that's useful for this.
Cheers.
TheMegaMan_ said:
Can I ask how you use Tasker to automate the BT switching? I've not used that (I use Setting Profiles instead which I understand does roughly the same thing), so am curious what kind of rule you have that's useful for this.
Click to expand...
Click to collapse
I use the following rules:
On wifi connection turn off bluetooth
On wifi disconnection wait 30 seconds and turn bluetooth on.
If not wifi connected & not bluetooth connected turn bluetooth off and on every 5 minutes.
If not wifi connected & not bluetooth connected and incoming call turn bluetooth off and on.
If not wifi connected & not bluetooth connected when display switched on turn bluetooth off and on.
The battery drain hasn't been a problem, if I go away or won't be using my car for a while I disable tasker. Of course this doesn't help when it keeps asking for the pin.
daveaus said:
I use the following rules:
Click to expand...
Click to collapse
Ah, cunning! Of course...toggle it when it's not already connected. Prifile Settings doesn't seem to let me toggle things like BT directly, although I could probably do so by setting some appropriate profiles.
I'll have to experiment...or just buy Tasker, instead!
daveaus said:
Of course this doesn't help when it keeps asking for the pin.
Click to expand...
Click to collapse
True, but so far in my case, I've only had that when I've tried to initiate connection from the car. Hopefully your trick will mean I don't need to do that so often.
Anyone found a gingerbread rom (or any rom!) with improved Bluetooth?
I have found the bluetooth to be terrible on the desire. I have got about 3 devices that my phone just refuses to pair with.
Currently I am trying to get it to connect with an Elm 327 Obd scanner. No luck, it asks for a pin, then I enter the pin, but it immediately rejects it.
I have tried oxygen rom, leedroid, stock froyo, everything...
I also have a parrot hands free kit that does the same thing, asks for pin, then does nothing...
Something makes me think it might be the radio or something. Except that my phone DOES connect with my scala motorbike helmet... So frustrating
Sent from my HTC Desire using XDA App

[Q] BlueTooth & Cars

I've tried to connect my phone via BT to two different cars and have no luck. It will scan for devices but won't find them at all. Does this happen to anyone else with the SIII? Strangely enough, it finds and connects to my JamBox is just fine.
What ROM are u on ? Stock or rooted?
What kind of cars I know my Audi A8 will connect but I always have to connect manually and enter the 1234 paswrd.
Sent from my SAMSUNG-SGH-I747 using xda premium
bbgt2 said:
What ROM are u on ? Stock or rooted?
What kind of cars I know my Audi A8 will connect but I always have to connect manually and enter the 1234 paswrd.
Sent from my SAMSUNG-SGH-I747 using xda premium
Click to expand...
Click to collapse
Still rocking the stock and unrooted for the phone. I tried on a Lexus GS and a Scion xB but no results show up. How do you connect manually? I should try that
Phone calls and bluetooth streaming works fine in my 2009 Mazda 6 (GT, no navigation). My phone is stock + root.
I use Slacker Radio everyday, launched by Automateit Pro when the connection to my car is established.
IIRC, I had to input a PIN on my phone, then in my car to do the pairing, and after that, I had to connect the phone manually to the stereo, but only once. After that, it's automatic when I start the car. Watch out for the "Only visible to paired devices" setting on your phone. It must not be checked.
I too have major issues with bluetooth, my phone connects whenever it feels like. I had to flash to cm9 to be able to listen to music in my G37. No problems in my other car (it has aftermaket pioneer system).
PS Just flashed the CM10 since they finally figured out A2DP, but the image is broken. (Note to myself: "Read the thread before flashing") Will wait for the next nightly build.
Nissan's always had a horrid BT stack in it. I'm in an 09 Altima and BT just sucks. I know it's not the phone as I've tried multiple phones from multiple vendors and they all suck. Nissan won't fix it either.
[Q] Bluetooth issue with Cars
I have AKOP Rom and KT Kernel. My bluetooth connectin to Mazda Cx-5 is fine. However, the problem I have is a lot of phone information (Song title, Battery Status) I used to have on stock, now are gone. Previously, I can fast foward or Rewind a song, also, once BT is connected, the default music player will start automatically
Can someone suggest a BT manager app which can change and enhance BT setting?
I have a 2009 Mercedes B200. My phone connects to the car just fine, but no sound comes from the speakers and no sound goes into the microphone. Same thing with my car and the HTC One X, although that was fixed with a stock ROM update. Bluetooth on cars can be very hit and miss.

[Q] Bluetooth Auto-Connect?

Quick question whether there is an app, mod, or even build.prop edit that would allow my Note II to automatically try to connect to my car's single din Kenwood KDC‑BT952HD. Only thing the head unit tries to do when connected is re-download contacts, but it turns on as soon as my car turns on and it'd be a lot faster if my Note automatically attempted to connect to the head unit instead of the bluetooth popup with listed devices, which I don't even have considering I'm running Whompasaurus V2.9. so if there's any way I could even get the pop up that'd be great too!
I use Tasker to turn on Bluetooth and connect to my earpiece. But I need a trigger and I need to turn on my earpiece. The trigger I use is activating my map app.
So without a trigger, I don't know how to do that.
I'm new to tasker and I'm not sure how to enable the auto-connect through tasker.
I am new to Tasker too.
Task / Net / Bluetooth
will turn on/off/ toggle Bluetooth
Task / plugin / Secure Settings (separate app) / BT Connect
Will connect to your chosen Bluetooth device.
My best advice is to play around. Also, here is the first of a 3 video series on Tasker.
http://www.youtube.com/watch?v=BEhnOJl5mTo&feature=youtube_gdata_player
maybe I'm missing something here, so may suggestion by be complete off.
Maybe leaving BT tunred on your GN2 before you get in your car. Or turned it on before you get in the car. I'm assuming the ROM you're using has a BT toggle. The thinking is that your headunit will try to automatically connect to any paired BT devices. If so, the GN2 should automatically connect when the deck does it's search.
This works for me when I try connecting to Jawborn Big Jambox or Jawbone Era or other BT devices I have paired on my GN2. It may be worth nothing I'm on a deoxidized stock rom. But I this also worked when I ran AOSP roms on my Evo 4G such as CM.
If the headunit does not do a pair device search and connect when it turns on, then I would definitely try suggest above. I have no clue, and that's better than nothing.
no autoconnect on GN2
Once you had a BT connection with your car and leave it at the gas station e.g. it won't reconnect when you're back!
Sad, but since then I tried the mighty Tasker and similar apps, but was happy with the app called "Bluetooth Auto Connect".
You can define the simple trigger, when display on....
So whenever I get back into the car, I hit either the menu or start button, that's it. Without unlocking you are back connected.
The only other annoying thing that you might be able to fix with Tasker is, that right after the A2DP establishes the connection the player starts playing the last song, which I obviously don't want most of the time.
Also Play Pause Next etc over BT doesn't work too well on android.
I have a Alpine head unit and as long as my bt is on before I start the car everything syncs automatically.
Sent from my SPH-L900 using Tapatalk 2
Lord Sekhmet said:
I am new to Tasker too.
Task / Net / Bluetooth
will turn on/off/ toggle Bluetooth
Task / plugin / Secure Settings (separate app) / BT Connect
Will connect to your chosen Bluetooth device.
My best advice is to play around. Also, here is the first of a 3 video series on Tasker.
http://www.youtube.com/watch?v=BEhnOJl5mTo&feature=youtube_gdata_player
Click to expand...
Click to collapse
That's interesting, I always wonder what exactly secure settings does, but this example helps.
Sent from my SPH-L900 using xda premium
1FstYOTA said:
I have a Alpine head unit and as long as my bt is on before I start the car everything syncs automatically.
Sent from my SPH-L900 using Tapatalk 2
Click to expand...
Click to collapse
I have a Kenwood Dnx6980, and my experience has been that once my phone has been setup to sync ... The Kenwood will talk to it automagically.
This is using AOSP or non stock roms. Ofc.
Sent from my SPH-L900 using Tapatalk 2
Tasker worked for me
Skripka said:
I have a Kenwood Dnx6980, and my experience has been that once my phone has been setup to sync ... The Kenwood will talk to it automagically.
This is using AOSP or non stock roms. Ofc.
Sent from my SPH-L900 using Tapatalk 2
Click to expand...
Click to collapse
Guys I have a Chinese brand double din...MobileVision...or something like that and using Tasker along with Bluetooth autoconnect worked for me. The posts above describe exactly how to set it up and it worked for me.
[email protected] said:
Guys I have a Chinese brand double din...MobileVision...or something like that and using Tasker along with Bluetooth autoconnect worked for me. The posts above describe exactly how to set it up and it worked for me.
Click to expand...
Click to collapse
Bluetooth autoconnect's main feature works for my xperia pro (turn on bluetooth, connect to your selected devices in automatic)
Bluetooth autoconnect's tasker plugin is not working for me. I can use it, sort off, but it does nothing. Like, "Press the button, but there was no reply!"
Well that is odd. I have a Pioneer unit and my phone connects to it as soon as it detects it in range. Even if I turn off BT and then power it on, the phone automatically connects to the head unit without any intervention on my part. Sounds like an issue with your stereo.
No stereo issue. On some of the touch wiz based roms bluetooth DOES NOT auto connect. On most (if not all) aosp roms bluetooth DOES auto connect. Currently on ma7 stock with root and it auto connects. When I was on whomp, jellybombed, and labrats
Sent from my SPH-L900 using Tapatalk 4 Beta
Bluetooth Connection
Hi Guys,
Im glad i found this thread, im wondering if anyone could help me out.
My scenario is, my bluetooth is connected to my car radio playing files. When a call comes in, i need it to disconnect from the car radio and connect to my bluetooth headset, all without turning off bluetooth ( preferable )
My possible solutions are:
1 ) By using automagic, ive managed to get alot done with this app, but this seems beyond it.
2 ) Getting automagic to start an application when a call comes in which will force bluetooth connection to a specific bluetooth device and disconnected from other devices.
Anyone got any suggestions?
devilshady said:
Hi Guys,
Im glad i found this thread, im wondering if anyone could help me out.
My scenario is, my bluetooth is connected to my car radio playing files. When a call comes in, i need it to disconnect from the car radio and connect to my bluetooth headset, all without turning off bluetooth ( preferable )
My possible solutions are:
1 ) By using automagic, ive managed to get alot done with this app, but this seems beyond it.
2 ) Getting automagic to start an application when a call comes in which will force bluetooth connection to a specific bluetooth device and disconnected from other devices.
Anyone got any suggestions?
Click to expand...
Click to collapse
not sure of your rom, but both TW and CM allow you to set whether each connection is Media or Phone. put your headset to phone and your car to media only. when you answer the phone the headset should take over.
Lord Sekhmet said:
I use Tasker to turn on Bluetooth and connect to my earpiece. But I need a trigger and I need to turn on my earpiece. The trigger I use is activating my map app.
So without a trigger, I don't know how to do that.
Click to expand...
Click to collapse
Could you share how you did this? I am completely confused by the interface.
I am wanting the same setup but also for music player and Pandora
I haven't found an example to follow that even comes close.
---------- Post added at 09:54 AM ---------- Previous post was at 09:43 AM ----------
Lord Sekhmet said:
I am new to Tasker too.
Task / Net / Bluetooth
will turn on/off/ toggle Bluetooth
Task / plugin / Secure Settings (separate app) / BT Connect
Will connect to your chosen Bluetooth device.
My best advice is to play around. Also, here is the first of a 3 video series on Tasker.
http://www.youtube.com/watch?v=BEhnOJl5mTo&feature=youtube_gdata_player
Click to expand...
Click to collapse
That helps,
I was going task / setting / Bluetooth
Still not sure how to set the trigger however.
[EDIT]
The first few minutes of that video answered my questions.
Sorry, I partied late last night and still kinda loopy.
Sent from my Jedi MasterX Note 2

[Q] Mildwild 5.0 - Bluetooth issue

I'm using Mildwild 5.0 as daily ROM. I noticed that even though bluetooth is on, the phone does not connect to the remote audio device.
The pairing process is successful, however the connection is not automatic.
I need to manually connect the phone to the device using the Wireless settings menu.
Did anybody notice the same behavior?
aaf107 said:
I'm using Mildwild 5.0 as daily ROM. I noticed that even though bluetooth is on, the phone does not connect to the remote audio device.
The pairing process is successful, however the connection is not automatic.
I need to manually connect the phone to the device using the Wireless settings menu.
Did anybody notice the same behavior?
Click to expand...
Click to collapse
It doesn't happen to me. I have a bluetooth headset, and it alwaya connects to it.
abaaaabbbb63 said:
It doesn't happen to me. I have a bluetooth headset, and it alwaya connects to it.
Click to expand...
Click to collapse
i have the same issue, i could not transfer photos to another device through bluetooth, haven't checked a handsfree because i don't have one, but there is a bluetooth issue
I had used this ROM for couple days and I don't have this issue. Maybe try with MV 14.
aaf107 said:
I'm using Mildwild 5.0 as daily ROM. I noticed that even though bluetooth is on, the phone does not connect to the remote audio device.
The pairing process is successful, however the connection is not automatic.
I need to manually connect the phone to the device using the Wireless settings menu.
Did anybody notice the same behavior?
Click to expand...
Click to collapse
I had a similar problem with this ROM and my car's audio/phone system. I suspect the problem was on the side of my car's bluetooth, because after erasing the link on car's side, I was able to setup it again, successfully.
bruno.unna said:
I had a similar problem with this ROM and my car's audio/phone system. I suspect the problem was on the side of my car's bluetooth, because after erasing the link on car's side, I was able to setup it again, successfully.
Click to expand...
Click to collapse
I'm still experiencing the same issue with MW 14.
My car kit is most probably a BT 1.1 device.
Here's the relevant logcat information
Code:
E/BluetoothEventLoop.cpp(167): event_filter: Received signal org.bluez.Device:PropertyChanged from /org/bluez/1081/hci0/dev_00_14_09_13_51_33

Force bluetooth "phone audio" from nexus 7?

Nexus 7 2013 WiFi
Stock 6.0.1 rooted with Timur's Kernel v4
For some reason when I BT connect my tablet to ANY pioneer head unit (tried 3 so far) I don't get the check box in bluetooth options for "phone audio" . I am using the Verizon messages+ app to make calls and receive texts over wifi Hotspot from my phone. This works amazingly but for some reason I can't get it to route through to the pioneer bluetooth connection. I tried a set of bluetooth headphones and the phone audio checkbox is there and it works flawlessly.
I did some Google searching and searched this sub but don't see anything relating to this problem.
edit: see below for update
Is there a way to force a bluetooth profile to use "phone audio"? Is there a Config file anywhere I can manually edit?
I've tried Bluetooth Auto Connect and choosing the phone audio option for the head unit but it did not change anything.
I assume your nexus is lte ?
deadgiveaway said:
I assume your nexus is lte ?
Click to expand...
Click to collapse
Sorry should have put that info in the initial post. No, it is the WiFi model.
I would be wifi tethering my phone to get network connectivity. This is a Nexus 7 carputer type build.
Bit of an update though:
Per a website that I cant post a link to until i make 10 posts.... It looks like the nexus 7 2013 lacks the HFP (Hands Free Profile) by default. Now I'm not entirely sure why the bluetooth headset works if this profile is not present other than its possible the headset uses the HSP (Head Set Profile) but I can't seem to find any documentation on if the N7 actually has the HSP.
Through extensive googling, I ended up at posts talking about Bluez bluetooth stack implementation. This is a bit over my head though and cant really find any solid documentation on implementing it on Stock 6.0.1
I also ended up getting directed to the source.android page that mentions at the bottom:
Custom Bluetooth profiles - If you want to add Bluetooth profiles that do not have HAL interfaces provided by Android, you must supply an SDK add-on download to make the profile available to app developers, make the APIs available in the Bluetooth system process app (packages/apps/Bluetooth), and add them to the default stack (system/bt).
Click to expand...
Click to collapse
But like I said, this is over my head.
Anyone with any sort of experience give me some insight?

Categories

Resources