[android-developers] Re: Bluetooth SPP Service Discovery Intermittent but Persistent failures

2012-07-27 Thread Konny
I noticed the same on a Galaxy S2 running 4.0.3. So I tried to check the 
UUIDs prior to connect() by calling BluetoothDevice#fetchUuidsWithSdp(). 
This works good for some time, but at some point my BroadcastReceiver stops 
to receive the ACTION_UUID intents (although fetchUuidsWithSdp returned 
true). The same code worked on a Motorola and a Samsung Pad without any 
problems.

On Monday, July 9, 2012 5:44:49 PM UTC+2, Justin Stander wrote:

 I am having a very similar problem on the Samsung Galaxy S3 running Ice 
 Cream Sandwich. I can connect and disconnect reliably until the device the 
 phone is connecting to is unavailable. After the connection times out or 
 returns the rightful 'Unable to start Service Discovery' error (obviously 
 due to the device being offline), I can never connect again to that device 
 unless I power cycle the Phone.

 I am also explicitly cancelling service discovery before all connections. 
 I can exit and restart the Android app a million times as long as the 
 device I am connecting to is still powered on and its Bluetooth radio is 
 powered on. The minute the Android phone fails to see my target device, 
 that's the end of the road until I reboot Android.

 On Thursday, August 4, 2011 10:17:00 AM UTC-4, ole! wrote:

 Update:
 I've had so many problems with Bluetooth connections that I am updating 
 this thread in hopes that others will be helped and a person
 with more Bluetooth knowledge can respond.

 Experimentation with other phones and BT devices indicates to me that the 
 problem is not with the phones that I mentioned even though
 they have the symptoms. I believe that the response of the BT device to a 
 service discovery request is erratic and the success of service discovery 
 has
 some timing dependence.

 Bottom line is that if steps 1-4 (in original post) are repeated as soon 
 as an exception is detected, I eventually get connected (within about 5 
 repeats).
 A single service discovery request has a success rate of 1/3.
 Note that I was repeating steps 1-4 if a user selected a menu item and 
 this does not work well presumably due to some timing issue.

 Repeating just step 4 (connect method) always fails, if the first 
 connect() failed.




-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Bluetooth SPP Service Discovery Intermittent but Persistent failures

2012-07-10 Thread Justin Stander
I am having a very similar problem on the Samsung Galaxy S3 running Ice 
Cream Sandwich. I can connect and disconnect reliably until the device the 
phone is connecting to is unavailable. After the connection times out or 
returns the rightful 'Unable to start Service Discovery' error (obviously 
due to the device being offline), I can never connect again to that device 
unless I power cycle the Phone.

I am also explicitly cancelling service discovery before all connections. I 
can exit and restart the Android app a million times as long as the device 
I am connecting to is still powered on and its Bluetooth radio is powered 
on. The minute the Android phone fails to see my target device, that's the 
end of the road until I reboot Android.

On Thursday, August 4, 2011 10:17:00 AM UTC-4, ole! wrote:

 Update:
 I've had so many problems with Bluetooth connections that I am updating 
 this thread in hopes that others will be helped and a person
 with more Bluetooth knowledge can respond.

 Experimentation with other phones and BT devices indicates to me that the 
 problem is not with the phones that I mentioned even though
 they have the symptoms. I believe that the response of the BT device to a 
 service discovery request is erratic and the success of service discovery 
 has
 some timing dependence.

 Bottom line is that if steps 1-4 (in original post) are repeated as soon 
 as an exception is detected, I eventually get connected (within about 5 
 repeats).
 A single service discovery request has a success rate of 1/3.
 Note that I was repeating steps 1-4 if a user selected a menu item and 
 this does not work well presumably due to some timing issue.

 Repeating just step 4 (connect method) always fails, if the first 
 connect() failed.




-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Bluetooth SPP Service Discovery Intermittent but Persistent failures

2011-08-04 Thread ole!
Update:
I've had so many problems with Bluetooth connections that I am updating this 
thread in hopes that others will be helped and a person
with more Bluetooth knowledge can respond.

Experimentation with other phones and BT devices indicates to me that the 
problem is not with the phones that I mentioned even though
they have the symptoms. I believe that the response of the BT device to a 
service discovery request is erratic and the success of service discovery 
has
some timing dependence.

Bottom line is that if steps 1-4 (in original post) are repeated as soon as 
an exception is detected, I eventually get connected (within about 5 
repeats).
A single service discovery request has a success rate of 1/3.
Note that I was repeating steps 1-4 if a user selected a menu item and this 
does not work well presumably due to some timing issue.

Repeating just step 4 (connect method) always fails, if the first connect() 
failed.


-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en