This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

PC Repeat Pair

hi

I use nrf52833 and nRF5_SDK_17.0.2_d674dde HID keyborad demo.

1. I pair PC success first , then I erase_bonds ,and repeat pair my pc. with other  address  but PC do not pair OK. if PC delect pair information, it is ok.

2. the same way   repeat pair  android phone is OK.

3. I add PM_EVT_CONN_SEC_FAILED error is BLE_GAP_SEC_STATUS_UNSPECIFIED. 

4. I add

case PM_EVT_CONN_SEC_CONFIG_REQ:
conn_sec_config.allow_repairing= true;
pm_conn_sec_config_reply(p_evt->conn_handle,&conn_sec_config);

break;

But do not run here.

Maybe Have some reason  please or my PC donot support repear pair?

Parents Reply
  • yes,i am sure ,it is after peer_manager_init ,and before advertising_start。

    buffer_init();
    peer_manager_init();
    // Start execution.
    NRF_LOG_INFO("HID Keyboard example started.");
    timers_start();

    error =pm_privacy_get(&myparams);
    myparams.p_device_irk->irk[0]=0x02;
    myparams.p_device_irk->irk[1]=0x02;
    error =pm_privacy_set(&myparams);

    pm_privacy_get(&myparams);

    advertising_start(erase_bonds);

Children
Related