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

Unknown function at 0xA60

Hello,

I am new to the NRF52 SoC and BLE development. I've been using the ble_app_template and following along this tutorial to learn more about BLE development. I'm having a problem when attempting to connect using the NRF Connect mobile app to my NRF52 DK. The steps are as follows:

  1. Run the compiled binary on the dev board through SEGGER. At this point, LED1 on the NRF52 DK is blinking.
  2. Open the NRF Connect mobile app and locate the NORD device.
  3. Connect to the NORD device on the mobile app

When I connect to the NORD device, LED1 NRF52 DK stops blinking and the mobile immediately brings me to a blank Client tab with the status "DISCONNECTED NOT BONDED". When I step through the program in Segger and get to this point in the execution, I obtain the error Unknown function 0xA60.

Does anyone have any insight as to what this means and how I can fix it?

Thanks in advance for any help.

  • /**@brief Function for handling the Connect event.
     *
     * @param[in]   p_cus       Custom Service structure.
     * @param[in]   p_ble_evt   Event received from the BLE stack.
     */
    static void on_connect(ble_cus_t * p_cus, ble_evt_t const * p_ble_evt)
    {
        p_cus->conn_handle = p_ble_evt->evt.gap_evt.conn_handle;
    
        ble_cus_evt_t evt;
    
        printf("ble_cus.c on_connect entry\r\n");   
        evt.evt_type = BLE_CUS_EVT_CONNECTED;
        printf("ble_cus.c: Set event type to BLE_CUS_EVT_CONNECTED\r\n");
        p_cus->evt_handler(p_cus, &evt); //PROBLEM HERE
        printf("ble_cus.c on_connect exit\r\n");
    }

    I was able to narrow down the problem to the following line of code, (line 15) but still need help in understanding what 0xA60 means.

  • Hi,

    The reason the function is unknown is that this is within the MBR, and the MBR and SoftDevice is only provided as binary without debug symbols, so your debugger cannot make sense of it. That is not an error, it is just how it is.

    Stepping while the SoftDevice is enabled is not supported and will cause problems. If you do this while advertising or in a BLE connection the pause will make the SoftDevice assert when it continues. So to do something similar with a SoftDevice you need to use a breakpoint and run to the breakpoint. I you want to continue a bit / step, then you instead need to move the breakpoint and reset.

  • Hello, thank you for your reply.

    I've read this suggestion from similar posts. The issue still persists even when running the NRF52 DK without Segger IDE. In other words, even in the circumstances where I am not stepping through the SoftDevice, I am getting the same problem (on connect, the mobile application just shows a blank client tab).  That leads me to believe that this might be an actual issue with the code, but I could be mistaken. 

  • What do you see that points to an issue? Don't get me wrong, I am not saying there is no issue in your code (I have no knowledge about it). But the fact that you see the debugger complain about "Unknown function at 0xA60" is not an indication of an issue. And as stated, you cannot step in the code when using a SoftDevice.

    To debug if you see something unexpected I suggest you enable debug logging. If you are using SES, then select the Debug build target and test. In most cases the debug log will show you if an error has been detected. You can also add more logs in your code to see what happens.

  • I am expecting that when I connect to the SoftDevice using the mobile NRF Connect application, it will actually connect and display some of the client data such as Services, Characteristics, etc.. In the current state, the connection does not get established.

    I'll continue to add more logging in my code to better root cause the issue per your suggestion.

    Thanks!

Related