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

DFU Bootloader Porting from SDK 6.0.0 to SDK 6.1.0.

Hi,

I want to add DFU OTA feature for my project, I use SDK 6.1.0 and S110 7.1.0, I found a sample Bootloader code for different version of SDK (SDK 6.0.0), from Github [https://github.com/NordicSemiconductor/nrf51-dfu-bootloader-for-gcc-compiler] , The changes I have done is changing the board (to PCA10001) and changing the I/O's, but it seems to not even advertise, finally found that Pstorage register function returned "invalid Parameter Error" , so requested extra bytes(~2 bytes) of memory and the device was advertising as DFUTarg, but when I select my application hex file, uploading status goes halt, and DFU Timeout occurs and gets disconnected, Is there anything changes to be made to port to SDK 6.1.0 and also I need it to be ported to support Single Bank mode, How is it done, is there any procedure to be followed to port. I use Eclipse IDE, nRF Tool Android app.

  • Over flow error was due to allocating more memory of RAM in make file, I solved it, but didn't help much, so I later tried to port the Dual Bank Project to Single bank by replacing the .c files from Single bank as you advised, Worked fine but not as expected, Total flash Size is 256Kb, in that ->88K is for S110 (v7.1.0), ->Bootloader of 40KB(altered the Bootloader Start Address to 0x00036000), ->To store Bootloader settings 1 KB is allotted, ->Application Data of 4KB(Assumed). So remaining space is for Application ie, (256 - (88+40+1+5) ) which is equal to 122K, which means I can load the application of max size 122K, I have 2 application files of size(BIN File Size) 55474 bytes and 59300 bytes, 55474 bytes size file was successfully getting uploaded where the other (59300 bytes Bin file) was not. Is it that still I am using Dual Bank mode DFU, I didn't include the Dual Bank c file in make file. So why the 59300 bytes Bin file didn't successfully get uploaded ?, Is there anything to change in the DFU Project? or is there anything to change in the application part?.

  • Hi Raghu,

    I assume you have updated the makefile to include the dfu_single_bank.c instead of the dfu_dual_bank.c. Anyway, I have tested and made a project based on the 2 examples on Github, please test and let me know if it works. The project is attached in the answer.

    nrf51822_v6.0.0 - GCC_Bootloader_singlebank.zip

  • Thanks for the time working on that, I correctly included dfu_single_bank.c in Makefile, I was using hex file of my application, where sometimes nrf Tools Android App(Version 1.15.1) was not accepting all time, later tried with BIN files of the same project and was taking all time without fail and was uploading the application successfully, also tested with the max size of ~127KB application size, and was OK. Thanks for your assistance.

  • Hi Raghu,

    There is a chance that nRFToolbox for Android wasn't made to work with hex file more than 127kB. I will check with developer. I hope everything goes fine with the .bin file.

Related