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

peer_manager_handler: Connection security failed: role: Peripheral, conn_handle: 0x0, procedure: Encryption, error: 4102

SDK16.0

nRF52DK

HTS example

I got this error msg in the RTT log while running the example:

peer_manager_handler: Connection security failed: role: Peripheral, conn_handle: 0x0, procedure: Encryption, error: 4102

What shall I do to fix it?

Thanks,

Parents
  • From the log below: 

    <debug> nrf_ble_gq: Registering connection handle: 0x0000

    <info> app: Connected.

    <info> app: start timer here

    <info> app: pm_evt_handler, event id: 0x1

    <info> app: pm_evt_handler, event id: 0x3

    <info> peer_manager_handler: Connection security failed: role: Peripheral, conn_handle: 0x0, procedure: Encryption, error: 4102

    <info> app: ble_cube_on_ble_evt, evt: 0x14

    We can see that the error happened after the ble connected. When the p_evt ->evt_id is 0x3, it reported this error.

    Please give me some hints on how to fix it. 

    Thanks,

  • I don't know what numbers the events are coming from, but what I am interrested in is the log messages coming from the peer_manager_handler. 

    Now. Did you try to erase the bonding information both on the nRF and on the connected device? Please let me know if you are not sure how to do that. Also, please let me know what you are trying to connect to.

  • On the nRF, the easiest is to run the Nordic Command Line Tools command:
    "nrfutil --eraseall"

    and the reprogram your application. Let me know if you are having trouble doing this. If so, what IDE do you use?

    What is your other device? If it is a phone, you must enter your bluetooth settings and select something like "Forget Device". If it is another nRF52810 you are trying to connect to, then you should erase that chip and reprogram it like the other one. 

    Best regards,

    Edvin

Reply
  • On the nRF, the easiest is to run the Nordic Command Line Tools command:
    "nrfutil --eraseall"

    and the reprogram your application. Let me know if you are having trouble doing this. If so, what IDE do you use?

    What is your other device? If it is a phone, you must enter your bluetooth settings and select something like "Forget Device". If it is another nRF52810 you are trying to connect to, then you should erase that chip and reprogram it like the other one. 

    Best regards,

    Edvin

Children
No Data
Related