tag:blogger.com,1999:blog-89878749563391212.post100599828775882389..comments2024-03-25T17:53:11.127-07:00Comments on Android-er: Bluetooth LE example - connect to Bluetooth LE device and display GATT ServicesUnknownnoreply@blogger.comBlogger9125tag:blogger.com,1999:blog-89878749563391212.post-62724286569992946412018-12-18T22:34:27.675-08:002018-12-18T22:34:27.675-08:00Thankyou same problem i was facing because of your...Thankyou same problem i was facing because of your solution i got the result.Anonymoushttps://www.blogger.com/profile/02206138631863137757noreply@blogger.comtag:blogger.com,1999:blog-89878749563391212.post-67730150250708193602018-10-02T15:04:55.741-07:002018-10-02T15:04:55.741-07:00Thanks anonymous I have the same problem but your ...Thanks anonymous I have the same problem but your solution works greatAnonymoushttps://www.blogger.com/profile/00066568205279328357noreply@blogger.comtag:blogger.com,1999:blog-89878749563391212.post-62764438096057322622017-09-15T07:40:45.778-07:002017-09-15T07:40:45.778-07:00Find this:
if (mBluetoothAdapter == null)...Find this:<br /><br /> if (mBluetoothAdapter == null) {<br /> Toast.makeText(this,<br /> "bluetoothManager.getAdapter()==null",<br /> Toast.LENGTH_SHORT).show();<br /> finish();<br /> return;<br /> }<br /><br />AND put after:<br /> <br /><br />// Quick permission check<br /> int permissionCheck = this.checkSelfPermission("Manifest.permission.ACCESS_FINE_LOCATION");<br /> permissionCheck += this.checkSelfPermission("Manifest.permission.ACCESS_COARSE_LOCATION");<br /> if (permissionCheck != 0) {<br /><br /> this.requestPermissions(new String[]{Manifest.permission.ACCESS_FINE_LOCATION, Manifest.permission.ACCESS_COARSE_LOCATION}, 1001); //Any number<br /> }Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-89878749563391212.post-70611160012543044572017-05-23T13:25:10.337-07:002017-05-23T13:25:10.337-07:00Hi, thanks for your tutorial!
I copied the code e...Hi, thanks for your tutorial!<br /><br />I copied the code except for the ScanFilter part and tried to run it on three different devices using a phone as ble peripheral. However, the code didnt work and didn't list any device. When I used a ble scanner app from Google Play Store it worked. Do you know what the problem behind that could be?<br /><br />Thanks in advance!Anonymoushttps://www.blogger.com/profile/07522458229451074273noreply@blogger.comtag:blogger.com,1999:blog-89878749563391212.post-66157700474134060122017-05-16T21:16:07.549-07:002017-05-16T21:16:07.549-07:00Im having the same permissions issue as Reza, stil...Im having the same permissions issue as Reza, still havent figured it out and ive tried api levels from 16-23.. I have the use feature of permissions added to my android manifest.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-89878749563391212.post-15954383084573900332017-04-30T05:18:11.577-07:002017-04-30T05:18:11.577-07:00Hello Reza,
Please refer the post Bluetooth LE Ga...Hello Reza,<br /><br />Please refer the post Bluetooth LE Gatt Example, step-by-step (http://android-er.blogspot.com/2016/06/bluetooth-le-gatt-example-step-by-step.html).<br /><br />Edit AndroidManifest.xml to add uses-feature of "android.hardware.bluetooth_le", uses-permission of "android.permission.BLUETOOTH", "android.permission.BLUETOOTH_ADMIN" and "android.permission.ACCESS_COARSE_LOCATION".Erikhttps://www.blogger.com/profile/04983894331825656853noreply@blogger.comtag:blogger.com,1999:blog-89878749563391212.post-19552531435259178162017-04-29T12:41:04.860-07:002017-04-29T12:41:04.860-07:00Hi! Thank you for the good code. How can I solve &...Hi! Thank you for the good code. How can I solve "java.lang.SecurityException: Need ACCESS_COARSE_LOCATION or ACCESS_FINE_LOCATION permission to get scan results" that is displayed in Logcat when I hit SCAN? Any help would be highly appreciated. I have added both of them in manifest by the way.Rezahttps://www.blogger.com/profile/03642639867161632280noreply@blogger.comtag:blogger.com,1999:blog-89878749563391212.post-26582090491735466252016-12-03T02:04:34.825-08:002016-12-03T02:04:34.825-08:00Fix rotation(landscape or Portrait) Pragmatically....Fix rotation(landscape or Portrait) Pragmatically.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-89878749563391212.post-14992066614073655152016-11-10T13:03:50.631-08:002016-11-10T13:03:50.631-08:00Hi Eric,
your tutorial is extremely helpful, and ...Hi Eric,<br /><br />your tutorial is extremely helpful, and your source code worked very fine, now I facing another problem, what do I do to maintain the Bluetooth connection on screen rotation change? whenever I rotated the screen, my connection was destroyed and recreated, thanks in advance.<br /><br />BryanAnonymoushttps://www.blogger.com/profile/00292736140327141417noreply@blogger.com