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

nRF52832 SDK 15.3 Secure UART Bootloader: errors when modifying original project

Hi,

I am currently updating a firmware from SDK 12.1 to SDK 15.3 on a custom board using a nRF52832. Application itself has been upgraded and works well with Soft Device 6.1.1 (from SDK 15.3). But I am also using a secure serial UART bootloader with it. The one developped with SDK 12.1 (from ble dfu example) works fine, and I am now trying to modify the UART bootloader example given in SDK 15.3 (nRF5_SDK_15.3.0_59ac345\examples\dfu\secure_bootloader\pca10040_uart) to do the same thing. I have to modify it because in my case the bootloader first have to turn on a GSM chip (communicating in UART), that will then connect to a server, download the firmware to flash on the MCU, and pass it (still via UART) to the MCU (nRF52832). I am using Keil as IDE, nrf Connect, nrfutil and nrfjprog.

PROBLEM:

It seems like when doing some specific modifications to said bootloader example (like enabling logging with NRF_LOG_ENABLED in sdk_config.h, modifying optimization level or adding preprocessor symbols), a lot of errors are returned when building the project, which are: .\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching filename.o for pretty much all the object (.o) files.

Here is an example of my build output on Keil after I only modified optimization level from 3 to 0.

*** Using Compiler 'V5.06 update 6 (build 750)', folder: 'C:\Keil_v5\ARM\ARMCC\Bin'
Build target 'nrf52832_xxaa_mbr'
compiling public_key.c...
compiling nrf_bootloader_app_start_final.c...
compiling nrf_bootloader_dfu_timers.c...
compiling nrf_bootloader_app_start.c...
compiling nrf_bootloader_info.c...
compiling nrf_crypto_ecc.c...
compiling main.c...
compiling nrf_crypto_ecdsa.c...
compiling boards.c...
compiling oberon_backend_ecc.c...
compiling oberon_backend_ecdsa.c...
compiling oberon_backend_ecdh.c...
compiling oberon_backend_eddsa.c...
compiling nrf_bootloader_fw_activation.c...
compiling nrf_bootloader_wdt.c...
compiling nrf_bootloader.c...
compiling nrf_crypto_shared.c...
compiling dfu-cc.pb.c...
compiling oberon_backend_hmac.c...
compiling nrf_crypto_init.c...
compiling micro_ecc_backend_ecdh.c...
compiling oberon_backend_chacha_poly_aead.c...
compiling nrf_crypto_hash.c...
compiling nrf_sw_backend_hash.c...
compiling micro_ecc_backend_ecdsa.c...
compiling oberon_backend_hash.c...
compiling nrf_dfu.c...
compiling micro_ecc_backend_ecc.c...
compiling nrf_dfu_handling_error.c...
compiling nrf_dfu_settings.c...
compiling nrf_nvic.c...
compiling nrf_dfu_flash.c...
compiling nrf_dfu_req_handler.c...
compiling nrf_dfu_utils.c...
compiling nrf_dfu_mbr.c...
compiling nrf_drv_uart.c...
compiling nrf_dfu_ver_validation.c...
compiling nrf_dfu_serial_uart.c...
compiling nrf_dfu_transport.c...
compiling nrf_soc.c...
compiling nrf_nvmc.c...
compiling nrfx_atomic.c...
compiling app_util_platform.c...
compiling nrf_dfu_validation.c...
compiling nrfx_prs.c...
compiling app_error_weak.c...
compiling app_scheduler.c...
compiling mem_manager.c...
compiling nrfx_uarte.c...
compiling nrfx_uart.c...
compiling crc32.c...
compiling nrf_assert.c...
compiling nrf_atomic.c...
compiling nrf_fprintf.c...
compiling nrf_fstorage_nvmc.c...
compiling nrf_memobj.c...
compiling nrf_fstorage.c...
compiling nrf_ringbuf.c...
compiling pb_common.c...
compiling nrf_strerror.c...
compiling pb_decode.c...
compiling slip.c...
compiling nrf_queue.c...
compiling nrf_balloc.c...
compiling nrf_fprintf_format.c...
compiling nrf_log_str_formatter.c...
compiling system_nrf52.c...
compiling sha256.c...
compiling nrf_log_frontend.c...
compiling nrf_dfu_serial.c...
linking...
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_fstorage_nvmc.o(.constdata).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_dfu_timers.o(i.timer_fire).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.on_cmd_obj_write_request).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_balloc.o(i.nrf_balloc_free).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_lib_uECC.c.o(.text.uECC_vli_cmp_unsafe).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_lib_uECC.c.o(.text.uECC_vli_equal).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_app_start.o(i.nrf_bootloader_app_start).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu.o(i.dfu_observer).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_flash.o(i.nrf_dfu_flash_store).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_settings.o(i.settings_backup_crc_ok).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_utils.o(i.nrf_dfu_bank1_start_addr).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_validation.o(i.dfu_progress_reset).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_validation.o(i.nrf_dfu_validation_init).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_gpio_cfg).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching pb_decode.o(i.find_extension_field).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching pb_decode.o(i.pb_readbyte).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_mbr.o(i.nrf_dfu_mbr_copy_bl).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching pb_decode.o(i.pb_skip_varint).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader.o(i.boot_validate).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader.o(i.bootloader_reset).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_dfu_timers.o(i.nrf_bootloader_dfu_inactivity_timer_restart).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_crypto_ecc.o(i.nrf_crypto_internal_ecc_key_output_prepare).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_flash.o(i.nrf_dfu_flash_erase).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.on_cmd_obj_create_request).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching pb_decode.o(i.buf_read).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching pb_decode.o(i.pb_decode).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching pb_decode.o(i.pb_istream_from_buffer).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching pb_decode.o(.constdata).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching arm_startup_nrf52.o(.text).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_lib_uECC.c.o(.text.uECC_vli_modSub).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_lib_uECC.c.o(.text.uECC_vli_modMult).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching memcpya.o(.text).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching memseta.o(.text).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_crypto_ecc.o(i.nrf_crypto_internal_ecc_key_input_check).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_settings.o(i.crc_ok).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching main.o(i.dfu_observer).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_app_start_final.o(.constdata).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_dfu_timers.o(i.nrf_bootloader_wdt_feed_timer_start).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_fw_activation.o(i.sd_bl_activate).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_wdt.o(i.WDT_IRQHandler).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_crypto_ecc.o(i.nrf_crypto_internal_ecc_raw_input_check).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_crypto_hash.o(i.verify_context).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_crypto_shared.o(i.nrf_crypto_internal_swap_endian_in_place).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_sw_backend_hash.o(i.nrf_sw_backend_hash_sha256_update).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_mbr.o(.constdata).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.nrf_dfu_req_handler_on_req).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_serial_uart.o(.constdata).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_settings.o(i.nrf_dfu_settings_write_and_backup).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_settings.o(i.settings_backup).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrfx_uarte_tx_in_progress).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.tx_done_event).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching system_nrf52.o(i.errata_182).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_lib_uECC.c.o(.text.uECC_vli_modMult_fast).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_lib_uECC.c.o(.text.uECC_vli_modSquare_fast).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_crypto_shared.o(i.nrf_crypto_internal_double_swap_endian).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_backend_ecc.o(i.nrf_crypto_backend_micro_ecc_public_key_from_raw).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_serial_uart.o(i.nrf_drv_uart_rx).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_fstorage.o(i.nrf_fstorage_init).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching pb_decode.o(i.pb_skip_string).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_lib_uECC.c.o(.text.uECC_vli_isZero).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching llshl.o(.text).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_flash.o(i.nrf_dfu_flash_init).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.rx_done_event).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_fstorage.o(i.addr_is_within_bounds).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_fstorage_nvmc.o(i.read).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_crypto_shared.o(i.nrf_crypto_internal_swap_endian).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.ext_err_code_handle).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_settings.o(i.boot_validation_crc_ok).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_gpio_cfg_input).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_lib_uECC.c.o(.text.uECC_vli_set).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_lib_uECC.c.o(.text.uECC_vli_rshift1).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching memcmp.o(.text).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_dfu_timers.o(i.timer_start).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_dfu_timers.o(i.timer_stop).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_crypto_shared.o(i.nrf_crypto_internal_double_swap_endian_in_place).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_sw_backend_hash.o(.constdata).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.on_data_obj_select_request).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_validation.o(i.fw_hash_ok).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_prs.o(i.prs_box_get).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_gpio_cfg_default).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_gpio_cfg_output).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching app_scheduler.o(i.next_index).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching app_util_platform.o(i.app_util_enable_irq).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_serial.o(.constdata).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_lib_uECC.c.o(.text.uECC_vli_clear).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_backend_ecc.o(i.nrf_crypto_backend_micro_ecc_curve_get).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu.o(i.nrf_gpio_pin_set).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_prs.o(i.nrfx_prs_release).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_gpio_pin_set).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_atomic.o(i.nrf_atomic_u32_and).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_atomic.o(i.nrf_atomic_u32_fetch_or).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_serial.o(i.response_ext_err_payload_add).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_wdt.o(i.nrf_wdt_started).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_sw_backend_hash.o(i.nrf_sw_backend_hash_sha256_init).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.cmd_response_offset_and_crc_set).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.on_abort_request).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.on_cmd_obj_select_request).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.on_data_obj_crc_request).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.on_dfu_complete).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_serial_uart.o(i.payload_free).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_serial_uart.o(nrf_balloc).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_settings.o(i.nrf_dfu_settings_backup).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_utils.o(i.nrf_dfu_bank_invalidate).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_validation.o(i.update_requires_softdevice).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrfx_is_in_ram).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrfx_uarte_0_irq_handler).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching app_util_platform.o(i.app_util_disable_irq).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_fstorage.o(i.addr_is_page_aligned).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_fstorage_nvmc.o(i.is_busy).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_fstorage_nvmc.o(i.uninit).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_serial.o(i.uint32_encode).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_flash.o(i.dfu_fstorage_evt_handler).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_settings.o(i.boot_validation_crc).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_validation.o(i.nrf_dfu_validation_activation_prepare).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_ver_validation.o(i.fw_hash_type_ok).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_ver_validation.o(i.fw_version_required).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching pb_decode.o(i.pb_dec_fixed32).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching pb_decode.o(i.pb_dec_fixed64).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_lib_uECC.c.o(.text.uECC_vli_testBit).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader.o(i.loop_forever).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu.o(.constdata).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_handling_error.o(i.ext_error_get).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_handling_error.o(i.ext_error_set).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.nrf_dfu_req_handler_req).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_settings.o(i.settings_crc_get).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_settings.o(i.settings_crc_ok).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_nvmc.o(i.wait_for_flash_ready).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_prs.o(i.UARTE0_UART0_IRQHandler).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_balloc.o(i.nrf_balloc_block2idx).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_fstorage.o(i.addr_is_aligned32).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_fstorage_nvmc.o(i.init).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching system_nrf52.o(i.SystemCoreClockUpdate).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_dfu_timers.o(i.nrf_rtc_event_clear).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_wdt.o(i.nrf_bootloader_wdt_feed).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.on_cmd_obj_crc_request).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_validation.o(i.signature_required).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_validation.o(i.use_single_bank).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_uarte_event_check).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_uarte_event_clear).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_uarte_txrx_pins_set).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_atomic.o(i.nrf_atomic_flag_clear).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_atomic.o(i.nrf_atomic_flag_set_fetch).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader.o(i.flash_write_callback).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader.o(i.nrf_power_gpregret_get).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_fw_activation.o(i.flash_write_callback).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_backend_ecc.o(.constdata).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_validation.o(i.keep_softdevice).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_validation.o(i.nrf_dfu_validation_init_cmd_present).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_uarte_errorsrc_get_and_clear).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_uarte_hwfc_pins_set).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_uarte_shorts_disable).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_balloc.o(i.nrf_balloc_idx2block).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_lib_uECC.c.o(.text.bcopy).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader.o(i.inactivity_timeout).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_uarte_rx_amount_get).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching app_util_platform.o(i.app_util_critical_region_enter).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching app_util_platform.o(i.app_util_critical_region_exit).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader.o(i.wait_for_event).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_app_start_final.o(.emb_text).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_wdt.o(i.wdt_feed_timer_handler).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_serial_uart.o(dfu_trans).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_utils.o(i.nrf_dfu_app_start_address).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrfx_get_irq_number).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching micro_ecc_lib_uECC.c.o(.text.uECC_secp256r1).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching main.o(.constdata).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_dfu_timers.o(i.nrf_rtc_event_pending).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_dfu_timers.o(i.nrf_rtc_int_enable).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_dfu_timers.o(i.nrf_rtc_task_trigger).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_bootloader_dfu_timers.o(.constdata).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.on_mtu_get_request).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.on_ping_request).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.on_protocol_version_request).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_utils.o(i.nrf_dfu_softdevice_start_address).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_uarte_int_disable).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_uarte_int_enable).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrfx_uarte.o(i.nrf_uarte_task_trigger).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_fstorage_nvmc.o(i.rmap).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_fstorage_nvmc.o(i.wmap).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching pb_decode.o(i.decode_pointer_field).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching pb_decode.o(i.pb_close_string_substream).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching main.o(i.app_error_handler_bare).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_settings.o(i.nrf_dfu_settings_additional_erase).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_utils.o(.constdata).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6406E: No space in execution regions with .ANY selector matching nrf_dfu_req_handler.o(i.on_prn_set_request).
.\_build\nrf52832_xxaa_mbr.axf: Error: L6407E: Sections of aggregate size 0x10a8 bytes could not fit into .ANY selector(s).
Not enough information to list image symbols.
Not enough information to list load addresses in the image map.
Finished: 2 information, 0 warning and 185 error messages.
".\_build\nrf52832_xxaa_mbr.axf" - 185 Error(s), 0 Warning(s).
Target not created.
Build Time Elapsed:  00:00:24

By default, I have 0 errors and 0 warnings of course. Problem is, I need those modifications to debug at the very least.

QUESTIONS:

- Where do those errors come from, why are they returned for such little modifications of the project, and how do I get rid of them ?

- In order to then flash the bootloader: I saw that the bootloader is now trying to write its start address into MBR, thus in SoftDevice memory region. Is the solution exposed in this thread (devzone.nordicsemi.com/.../177444) in order to correctly flash SoftDevice than bootloader still the best one ?

- In the serial secure UART bootloader example, is it possible to use UARTE instead of UART ?

Thank you in advance for any help !

  • I am sorry, links seems to not be working. I will just quote here the part that interests me in particular :

    "nrfjprog will have trouble writing to the MBR/Softdevice area. And if you use --sectorerase with nrjfprog it will erase the MBR make the chip firmware stops working. The workaround is to do an erase all, write the MBR/Softdevice and then flash the bootloader without sector erase."

  • Hi,

    - Where do those errors come from, why are they returned for such little modifications of the project, and how do I get rid of them ?

     Because the size of the bootloader code has increased with your changes, you need to adjust IROM settings for the project. If you need more space for the bootloader you can allocate more by reducing the start address (IROM start, and increase the size setting with the same amount). You can see an example on how this is done in the debug variant of the bootloader project.

    - In order to then flash the bootloader: I saw that the bootloader is now trying to write its start address into MBR, thus in SoftDevice memory region. Is the solution exposed in this thread (devzone.nordicsemi.com/.../177444) in order to correctly flash SoftDevice than bootloader still the best one ?

    Yes. See also this post.

    - In the serial secure UART bootloader example, is it possible to use UARTE instead of UART ?

     It's actually using UARTE by default. (NRF_DRV_UART_USE_UARTE -> true)

  • Thank you for your answers, adjusting IROM start address and size indeed made things better.  

Related