Question

When i connect my device to my peripheral, he asks me a passkey (a pop-up is shown on the device). I want to send this passkey programmatically during the connection.

I'm using CBCentralManager but I can't find a way to send it.

Any suggestions?

Was it helpful?

Solution

You can't do this. This is part of the security model. If your BLE peripheral specifies that encryption is required to access one of its characteristics then pairing is required. The passkey is collected by iOS, not your application, and your application does not have any access to the passkey or the pairing/bonding process

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top