Disconnected, reason 62 in nrf5340 DK kit

hi,

                  i am trying to connect  peripherials ( blood pressure, pulseox meter) with nrf5340 dk ( development kit from nordic PCA10095) using uuid and mac, initially using uuid filter are used to scan the devices around and store the mac of the device. once the mac is stored we use address filter to  filter the device based on the mac address that was stored earlier.

once the mac address matches with the stored mac address  the connect with the device is established and gatt discovery is initialed and the handles are collected and data is received and subscribing to them. everything works as expected.  and we could get the vitals from the blood pressure and pulse oximeter.

but we face issue where all of sudden in-between the continuous reading nrf5340 fails to discover the services after starting the discovery and gets disconnected with the reason 62. it seems like the code goes into a endless loop and hence the nrf5340 controller comes to normal operation only after a reset

with reference to the devzone thread https://devzone.nordicsemi.com/f/nordic-q-a/82647/nrf5340-peripheral-ble-connections-always-fail-with-reason-0x3e-62

we are not sure if this is due to the external clock of 32kHz , for whch we have to add the config bit disable the external clock and enable RC in both the application core ane network core.

CONFIG_SOC_ENABLE_LFXO=n

CONFIG_CLOCK_CONTROL_NRF_K32SRC_RC=y 

how ever, we can only add the config bit in the proj.config file for the application core we could not find how we can add the config bit to the network core.

if we try to add the config bit only to the proj.config file of the application core we get error as 

<err> bt_hci_driver: Endpoint binding failed with -11 

<err> bt_hci_core: HCI driver open failed (-11)

how can we add the config file to the network core. 

or is it due to timeout to get the services, since  BT_HCI_ERR_CONN_FAIL_TO_ESTAB ( reason 62) might be due to time out  since the issue arises only after the discovery fail due to which the device gets disconnected stating that the reason is 62 we tried to increse the conn timeout but still we get the issue . 

what would be the cause for the issue how to proceed further

kindly tel us know which of the two opinions are correct 

Parents
  • Hi,

    It it is not very likely to be related to clock drift if you are testing with a nRF5340 DK on both ends of the link, but you can rule out this possibility by changing to the internal RC oscillator. Please let me know the SDK version you are on so I explain the steps for changing the clock source on the netcore.

    Best regards,

    Vidar

  • hi vidar, thank you for the mail the nrf sdk I'm currently using is 2.6.0 . kindly let me know the steps

    moreover if the clock drift is not the issue since I'm using the nordic DK kit then what else would be the issue because i even tried increasing the maximum time out time to 10 sec form default 3 sec using the configuration bit but still i get this error hoe can i determine what exactly causes this error. 

  • Hi,

    In v2.6.0 you can create a folder named 'child_image' in your project root to apply configuration changes to the child images. Like in the throughput sample here: https://github.com/nrfconnect/sdk-nrf/tree/v2.6.3/samples/bluetooth/throughput/child_image (Permanent configuration changes to child images). Alternatively, you can change the default clock source in your board file if you have defined your own board instead of building for the nRF5340 DK.

    The BT_HCI_ERR_CONN_FAIL_TO_ESTABL error is raised by the controller when the peer device does not respond to the CONNECT_IND packet after six connection events. In your previous ticket, I suggested capturing a BLE sniffer trace to help troubleshoot this.

  • Hi,

               thank you for the mail, i tried to use sniffer to capture the events during the error reason 62 using nrf dongle. since I'm a new to the controller, I'm not sure how to identity the issue looking into the log. i'm not sure how to add the log file in the chat since there is no option to add a file i'm providing the snap of the log.

    Moreover i tried to add the config bit to enable internal RC as per the example you have mentioned in added the config file under the directory child and also have added a folder called boards and added nrf5340dk_nrf5340_cpuapp.conf as well but still i get the error 62 and i gets a warning as CONFIG_SOC_ENABLE_LFXO was already disabled. Missing dependencies:
    SOC_NRF5340_CPUAPP can u plz tel what is difference between using conifg file in board folder , child folder and directly in the project as .confg file 

Reply
  • Hi,

               thank you for the mail, i tried to use sniffer to capture the events during the error reason 62 using nrf dongle. since I'm a new to the controller, I'm not sure how to identity the issue looking into the log. i'm not sure how to add the log file in the chat since there is no option to add a file i'm providing the snap of the log.

    Moreover i tried to add the config bit to enable internal RC as per the example you have mentioned in added the config file under the directory child and also have added a folder called boards and added nrf5340dk_nrf5340_cpuapp.conf as well but still i get the error 62 and i gets a warning as CONFIG_SOC_ENABLE_LFXO was already disabled. Missing dependencies:
    SOC_NRF5340_CPUAPP can u plz tel what is difference between using conifg file in board folder , child folder and directly in the project as .confg file 

Children
Related