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

Strange behaviour

Hello,

I am working on a NRF52 DK with Segger Embedded Studio on Windows.

I have application on Android and Iphone with our custom profil. Applications on smartphone works fine. I can also use NRF Connect application to connect on my application on another phone and see my custom gatt uuid and theirs characteristics.

I copy hrs_c example and change the UUID of hrs to my custom UUID. I disable BAS service.

When i debug the application on the NRF52 dev kit, application find the phone and connect to it, discover services but as you can see in the screenshot :

it put BLE_DB_DISCOVERY_SRV_NOT_FOUND in event_type but it has to put BLE_DB_DISCOVERY_COMPLETE since is_src_found is at TRUE.

Why do it goes in the wrong way ?

Thanks

Parents
  • Hi,

    This kind of behavior usually means that you are either debugging a non-debug build, and/or the value that you see in the debugger is not correctly shown because of optimization. Both of these can be set in "Project Options" (right click on the project in the "Project Explorer" panel, then "Edit Options..."). Under "Code" -> "Code Generation" you will find "Debugging Level" and "Optimization Level". Ensure that Debugging Level is at least 2, and set Optimization Level to Debug.

    Regards,
    Terje

Reply
  • Hi,

    This kind of behavior usually means that you are either debugging a non-debug build, and/or the value that you see in the debugger is not correctly shown because of optimization. Both of these can be set in "Project Options" (right click on the project in the "Project Explorer" panel, then "Edit Options..."). Under "Code" -> "Code Generation" you will find "Debugging Level" and "Optimization Level". Ensure that Debugging Level is at least 2, and set Optimization Level to Debug.

    Regards,
    Terje

Children
Related