Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs

Adding Bootloader to be able to perform buttonless DFU

Our existing product (already in the market) at Element Science in San Francisco, CA, USA uses an nRF52832 (BMD-350 module by u-blox) and nRF5 SDK 15.3 as base for the firmware. We used an SPI <==> BLE example. We don't currently have a Bootloader and therefore don't perform DFU.

We're now in the process of adding a Bootloader and performing DFU (using the SDK 15.3 Secure Bootloader pca10040_ble DFU example). We need help with the .icf and possible sdk_config.h files. We are having problems having the Bootloader and Application images co-existing (they don't seem to boot correctly) when we load them using nRF Connect for Desktop.

Could you review theses files for us to make sure that we have the correct mapping for Flash and RAM, please.

I have attached the 4 files.

Thank you,

Gil

ble_app_spi_iar_nRF5x.icf

secure_bootloader_iar_nRF5x.icf

app_sdk_config.h

bootloader_sdk_config.h

Parents Reply Children
  • Hi Amanda,

    Thank you for the information. That was one problem. Also, we use SDK 15.3 but I think that part has not changed.

    We have another problem. It's with the installation of the gcc toolchain to be able to build a library called 

    micro_ecc_lib_nrf52.a

    We will continue with the gcc installation, but in the meantime, if you have the gcc tool installed on your laptop, could you please install SDK 15.3 then run ...\micro-ecc\build_all.bat and attach micro_ecc_lib_nrf52.a here for me. We need it to be able to build the Bootloader. 

    After you run build_all.bat it should be in folder ...\nrf52hf_armgcc\armgcc and/or ...\nrf52nf_armgcc\armgcc

    Thank you! Slight smile

    Regards,

    Gil

  • Update: We were able to install the gcc tools and build the micro_ecc_lib_nrf52.a library.

    Now getting error when downloading "Stack pointer setup to incorrect alignment: Stack addr: 0xFFFFFFFF"

    Investigating...

  • Hi Amanda,

    We generated micro_ecc_lib_nrf52.a, generated the private and public keys, created the bootloader settings hex file, etc.

    Now we have everything working with the SD, Secure Bootloader, Bootloader Settings and the example ble_app_buttonless_dfu App. 

    I can edit the code of the example App, create new bootloader settings, etc and load all 4 hex files with nRF Connect for Desktop. Everything works with the example secure bootloader and buttonless app example.

    Unfortunately, our REAL product app does not work if I follow the same steps. So I think that there is some issue with sdk_config.h or the .icf files as stated in my initial question. Maybe you could look at it and see if something is wrong with them. Maybe missing some DFU #defines ... I don't know.

    Thanks,

    Gil

Related