Hi Ajith,
Thanks for the hints. I am testing with a no-brand headset while
waiting for some good headsets to be procured.
rfcomm connection is successfully established after I increased the
delay to 1 second.
For others' reference the file is packages/apps/Phone/src/com/android/
phone/BluetoothHeadsetService.java
Function private int waitForConnect(HeadsetBase headset)
I changed this line
//result = headset.waitForAsyncConnect(500,
mConnectedStatusHandler); // default - does not work
result = headset.waitForAsyncConnect(1000,
mConnectedStatusHandler); // increased delay to 1000ms
Thanks,
> Hi
>
> Please put logs in BluetoothHandsfree.java and BluetoothHeadsetService.java
> as to where the connect is getting called
> and once the connect returns pls specify the same
>
> I'm guessing this is because of your Headset, Some headset take a little
> delay to connect
> So if connection terminates it will probably be bacause of it.
>
> Please mention what headset you are using. Also paste the logs after the
> changes
> If you want to go further, introduce a little delay before connect and also
> before audioon()(Sco socket creation)
> may be 1 or 1.5 secs or 2 secs for that matter and send those logs too
>
> Regards,
> Ajith
>
> > unsubscribe:
android-porti...@googlegroups.com<
android-porting%2Bunsu...@googlegroups.com>
> > website:
http://groups.google.com/group/android-porting