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

Implementing buttonless_dfu to hrs_freertos

Hi,

I am developing the 'buttonless dfu' to the 'hrs freertos' using the SDK v15.3.0.

However, after I compiled the modified code and loaded to the target broad, I got the below error.

    <info> app: nrf_sdh_ble_enable() err:0 ram_start:0x20002258
    <error> app: Fatal error

Is there any example for this application?

Thanks

  • Hi Terry, 

    Try to add "DEBUG" to your preprocessor definitions, and see what the log says then. 

    1. Let me know if you are not sure how to define DEBUG in your preprocessor definitions. If you use the segger, you can compile with Debug mode. 

    2. The log will probably point to somewhere in your code where it says APP_ERROR_CHECK(err_code); What function call returned that err_code? 

    3. Your next mission is to find out why it returned that err_code. 

    -Amanda H.

  • Hi Amanda,

    Thanks for your help.

    Yes. I am using SEGGER Embedded Studio in my development.

    After enabled the DEBUG mode, I got more information about this issue as below.

        <info> app: nrf_sdh_ble_enable() err:0 ram_start:0x20002210
        <error> app: ERROR 4 [NRF_ERROR_NO_MEM] at /home/15v3_0/sdk/examples/ble_peripheral/ble_app_hrs_freertos_dfu/main.c:648
    PC at: 0x0002DF83
        <error> app: End of error report

    And, the error was reported after calling sd_ble_uuid_vs_add().

  • Hi Amanda,

    Finally, I found out the solution by setting NRF_SDH_BLE_VS_UUID_COUNT to 1.

    However, after I built and programmed the 'sdk/examples/dfu/secure_bootloader' to the development board, I got the below error returned by fds_init() in the appliction FW.

    <info> app: nrf_sdh_ble_enable() err:0 ram_start:0x20002220
    <error> peer_manager_pds: Could not initialize flash storage. fds_init() returned 0xB.
    <error> peer_manager: pm_init failed because pds_init() returned NRF_ERROR_STORAGE_FULL.
    <error> app: ERROR 3 [NRF_ERROR_INTERNAL] at /home/15v3_0/sdk/examples/ble_peripheral/ble_app_hrs_freertos_dfu/main.c:940
    PC at: 0x0002E1A3
    <error> app: End of error report

    Is it related to the project configuration file .emProject?

  • Hi Terry, 

    fds_init() return 0x0B meaning FDS_ERR_NO_PAGES.

    Which board are you using? Are you using pca10040e on nRF52832 DK?

    -Amanda H.

Related