Device reset happening and i can't able to upload the code

Hello,

In my project i am using  nrf52840 with my custom board and to upload the code through NRF_CONNECT application with soft device its uploading properly but with  segger emmbedded its giving some error like this .please have look and let me know what is the problem.

after this i have add DEBUG in preprocessor definition and i got this

thank you.

  • Hi

    The error message you're showing is longer than the error window you have opened, can you show the full message so we can see the error code/reason? My first guess is that your path is too long to find the project or some files when trying to flash, or that there are files both in the C:\\ and D:\\ disks. Please try shortening your path and see if that helps, and I'd recommend removing any spaces from your path, as that might cause issues. Can you also provide some information on what kind of debugger/flashing device you're using to flash the project onto your custom board? And how is the custom board connected to the debugger?

    Does the device also run as intended when using the nRFConnect programmer?

    Best regards,

    Simon

  • Hello, thanks for your relpy,

    Can you also provide some information on what kind of debugger/flashing device you're using to flash the project onto your custom board?

    SWD debugger like SWIO and SWCLK through this i am trying to flash the firmware here i am using nrf52840 jlink debugger so its giving the error as i have mentioned above.

    Does the device also run as intended when using the nRFConnect programmer?

    yes , its working properly.

    first i will try to resolve this path problems if it works for me or not will let you know.

    thanks 

  • Hello,

    I have tried to correct the path also but still same error and i don't know what to do.

    the error log from the log terminal will be like this 

    Building ‘ble_app_uart_pca10056_s140’ from solution ‘ble_app_uart_pca10056_s140’ in configuration ‘Release’
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/thumb_crt0.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_log_backend_rtt.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_log_backend_serial.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_log_default_backends.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_log_frontend.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_log_str_formatter.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/app_button.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/app_error.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/app_error_handler_gcc.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/app_error_weak.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/app_fifo.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/app_scheduler.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/app_timer2.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/app_uart_fifo.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/app_util_platform.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/drv_rtc.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/hardfault_implementation.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_assert.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_atfifo.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_atflags.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_atomic.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_balloc.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_fprintf.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_fprintf_format.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_memobj.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_pwr_mgmt.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_ringbuf.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_section_iter.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_sortlist.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_strerror.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/retarget.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/app_pwm.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/app_simple_timer.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/ses_startup_nrf52840.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/ses_startup_nrf_common.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/system_nrf52840.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/boards.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_drv_clock.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_drv_uart.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrfx_atomic.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrfx_clock.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrfx_gpiote.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrfx_prs.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrfx_uart.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrfx_uarte.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrfx_pwm.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrfx_timer.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrfx_ppi.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_drv_ppi.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/bsp.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/bsp_btn_ble.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/main.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/SEGGER_RTT.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/SEGGER_RTT_Syscalls_SES.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/SEGGER_RTT_printf.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/ble_advdata.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/ble_advertising.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/ble_conn_params.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/ble_conn_state.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/ble_link_ctx_manager.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/ble_srv_common.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_ble_gatt.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_ble_qwr.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/utf.o' is up to date
    2> 'Output/Release/Obj/ble_app_uart_pca10056_s140/ble_nus.o' is up to date
    3> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_sdh.o' is up to date
    4> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_sdh_ble.o' is up to date
    1> 'Output/Release/Obj/ble_app_uart_pca10056_s140/nrf_sdh_soc.o' is up to date
    1> Output/Release/Exe/ble_app_uart_pca10056_s140.elf does not exist.
    1> Linking ble_app_uart_pca10056_s140.elf
    1> "C:/Program Files/SEGGER/SEGGER Embedded Studio for ARM 5.40c/gcc/arm-none-eabi/bin/ld" -X --omagic -eReset_Handler --defsym=__do_debug_operation=__do_debug_operation_mempoll -EL --defsym=__vfprintf=__vfprintf_long --defsym=__vfscanf=__vfscanf_long --gc-sections "-TC:/A/DeviceDownload/nRF5SDK1702d674dde/nRF5_SDK_17.0.2_d674dde/examples/ble_peripheral/SiP final editing pwm + timer 02/pca10056/s140/ses/Output/Release/Obj/ble_app_uart_pca10056_s140/ble_app_uart_pca10056_s140.ld" -Map Output/Release/Exe/ble_app_uart_pca10056_s140.map -u_vectors -o Output/Release/Exe/ble_app_uart_pca10056_s140.elf --emit-relocs --start-group "@C:/A/DeviceDownload/nRF5SDK1702d674dde/nRF5_SDK_17.0.2_d674dde/examples/ble_peripheral/SiP final editing pwm + timer 02/pca10056/s140/ses/Output/Release/Obj/ble_app_uart_pca10056_s140/ble_app_uart_pca10056_s140.ind" --end-group
    1> C:/Program Files/SEGGER/SEGGER Embedded Studio for ARM 5.40c/gcc/arm-none-eabi/bin/ld: Output/Release/Obj/ble_app_uart_pca10056_s140/ses_startup_nrf_common.o: in function `InitializeUserMemorySections':
    1> C:\A\DeviceDownload\nRF5SDK1702d674dde\nRF5_SDK_17.0.2_d674dde\modules\nrfx\mdk/ses_startup_nrf_common.s:117: undefined reference to `__RAM1_segment_end__'
    Build failed

    So please help me to resolve this its very urgent.

    thank you.

  • Hi

    From the log you provided it seems like maybe there isn't enough RAM configured for your application, please check out this guide on how to adjust RAM and Flash memory for your application.

    Best regards,

    Simon

  • Hello,

     i have already tried this but no success so i don't know what has been changed but  i have tried  the memory size mentioned in the guide for nrf52840  still i am getting same error . is there any other solution to resolve this problem.??

    thank you.

Related