This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

(Zephyr / NCS) "Just Works" Bonded Pairing with nRF Connect for Mobile iOS

I am trying to get "just works" bonded pairing to work using the peripheral_uart sample code. I have modified it following this support ticket: https://devzone.nordicsemi.com/f/nordic-q-a/77391/allow-lesc-just-works-pairing-bonding-with-nrf-connect-sdk-zephyr-after-pressing-button

However, I am unable to bond to my dev kit running modified (or unmodified) peripheral_uart code using nRF Connect for iOS. It is my understanding that iOS will initiate bonding if trying to read a secured characteristic. That is not happening with my device. Is there some way I can force bonding? Is there something I'm missing in the steps to bond to my "just works" peripheral with iOS?

There is a similar question (below), but it does not solve my issue when trying to bond.

devzone.nordicsemi.com/.../nrf-connect-app-in-ios-don-t-have-bond-option

Here is my conn_auth_callbacks:

static struct bt_conn_auth_cb conn_auth_callbacks = {
	.passkey_display = NULL,
	.passkey_confirm = NULL,
	.cancel = auth_cancel,
	.pairing_confirm = NULL,
	.pairing_complete = pairing_complete,
	.pairing_failed = pairing_failed
};

Parents
  • Hi Eric, 

    Could you let me know how do you define the NUS characteristics and service (in nus.c) ? How did you define the permission to access the RX and TX characteristics ? 
    By default they doesn't require any security so it's normal that IOS doesn't trigger the bonding process. 
    Instead of BT_GATT_PERM_READ or  BT_GATT_PERM_WRITE you would need to use BT_GATT_PERM_READ_ENCRYPT or BT_GATT_PERM_WRITE_ENCRYPT for example

    I have a blog here that partly described about this. 

Reply
  • Hi Eric, 

    Could you let me know how do you define the NUS characteristics and service (in nus.c) ? How did you define the permission to access the RX and TX characteristics ? 
    By default they doesn't require any security so it's normal that IOS doesn't trigger the bonding process. 
    Instead of BT_GATT_PERM_READ or  BT_GATT_PERM_WRITE you would need to use BT_GATT_PERM_READ_ENCRYPT or BT_GATT_PERM_WRITE_ENCRYPT for example

    I have a blog here that partly described about this. 

Children
No Data
Related