I am using my iPhone as a central device and connecting to a peripheral to read a protected characteristic.
In my scenario, for pairing, the Central (iPhone) has both Keyboard and Display, and the peripheral responds with no input and no output capabilities.
That forces the Central (iPhone) to perform Just Works pairing.
As per Wikipedia- "Just works: As the name implies, this method just works, with no user interaction. However, a device may prompt the user to confirm the pairing process."
On the iOS device, unfortunately, the BLE stack automagically pops up an alert view to prompt the user to confirm or cancel the pairing process, and as such at least the first time a user intervention is required (AFAIK, this alert view is generated by the iOS BLE stack and we cannot prevent it from appearing, from an application programming level).
My question is- is there a way I can silent this alert view so that the pairing goes through without any user intervention?
I am running iOS8.3 on an iPhone6.
That's how 'Just Works' behaves on iOS. As you noted it removes the pass-key requirement but there's no removing the user-interaction step for bonding.
The accepted answer isn't correct as a pass-key isn't required & there's no public Apple API for out-of-band bonding. This answer covers it in more detail; https://stackoverflow.com/a/29338255/232113
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With