Closed widavies closed 6 years ago
Also, what code triggers a device to list for incoming connections? Or is that automatically done?
Same, any updates on this?
Edit: Added a pull request #8
I merged your pull request and pushed the code to bintray. You should be able to use the new version :
implement 'me.aflak.libraries:bluetooth:1.3.1'
Set the second parameter to true
to use an insecure connection.
bluetooth.connectToDevice(device, true)
I'm having some issues connecting to Bluetooth devices. When I connect, the onError() callback is called with error message:
read failed, socket might closed or timeout, read ret: -1
. I did a little bit of exploring into this issue, and it seems like creating an insecure connection would fix things (https://stackoverflow.com/a/36786031/4779937). Would you be able to add a toggle option for Secure / Insecure connect thread in yourConnectThread
class?If you'd like source code for the bug I'm getting, let me know.