I use it. nRF52832 PCA10040 I have coded based on NUS.
However, I failed to pair with my Android device.
Even with ble_app_uart, the result is the same.
I use it. nRF52832 PCA10040 I have coded based on NUS.
However, I failed to pair with my Android device.
Even with ble_app_uart, the result is the same.
Hi,
You are setting the security status as: BLE_GAP_SEC_STATUS_PAIRING_NOT_SUPP in the line below. err_code = sd_ble_gap_sec_params_reply(m_conn_handle, BLE_GAP_SEC_STATUS_PAIRING_NOT_SUPP, NULL, NULL);
Changing it to: err_code = sd_ble_gap_sec_params_reply(m_conn_handle, BLE_GAP_SEC_STATUS_SUCCESS, NULL, NULL);
might solve the problem.
Couldn't pair with PGMEDEM_NRF_52 (CC88) because of an incorrect PIN or passkey.
The above message has occurred. T.T
Try to set the security parameters as below and check if works: static ble_gap_sec_params_t m_sec_params;
m_sec_params.bond = 1;
m_sec_params.mitm = 0;
m_sec_params.io_caps = 3;
m_sec_params.oob = 0;
m_sec_params.min_key_size = 7;
m_sec_params.max_key_size = 16;
and then this: err_code = sd_ble_gap_sec_params_reply(m_conn_handle, BLE_GAP_SEC_STATUS_SUCCESS, &m_sec_params, NULL); check the infocenter for the details about setting the right values into m_sec_params. hope this works!
I applied this, but it does not work. Do I need a peer manager?
Thank you. I tried several times and it succeeded.