I am working in sdk14 nrf52832 ble_app_hids_keyboard_pca10040_s132. I set the .allow_repairing flag to true :
static void pm_evt_handler(pm_evt_t const * p_evt) { case PM_EVT_CONN_SEC_CONFIG_REQ: { // Reject pairing request from an already bonded peer. pm_conn_sec_config_t conn_sec_config = {.allow_repairing = true}; pm_conn_sec_config_reply(p_evt->conn_handle, &conn_sec_config); } break; .....
Then manually disconnect nrf52832 from the phone. Debug mode enter app_error_fault_handler,but is working in sdk12.2.