Guide to build and test NSIB, MCUboot as upgradable bootloader and application

Hi All,

In reference to my earlier ticket(https://devzone.nordicsemi.com/f/nordic-q-a/120183/question-on-immutable-bootloader-support-for-nrf54l15), I see SDK version 3.0 and latest version of SDK has experimental support of NSIB for nrf54l15.

Reference link: nRF Secure Immutable Bootloader

I am trying to build it as per the steps given in Enabling a bootloader chain using sysbuild and I am able to build the code. And able to see multiple hex files. 

I tried to flash merged.hex and checked logs on console, however not able to see anything and looks like issue with the boot process. I am trying to debug it by enabling some logs.

Till the time, can anyone help on this, if I am missing in build, flash and test the code? 

Thanks,

Nilesh

  • Hello Andreas,

    Thank you so much for your input.

    I also came to same link. I again went through DFU dev academy class Exercise 2 - DFU with custom keys - Nordic Developer Academy

    And come to know we need to manually provision the key to KMU.

    With this I am able to see the code is booting.

    Just a summary and please correct me here, I followed below steps and with which I am able to see bootloader validating mcuboot, and then my application is running and getting below console log

    I: Firmware signature verified.
    Firmware version 1I: Setting monotonic counter (version: 1, slot: 0)
    Booting (0x8800).
    
    *** Booting MCUboot v2.1.0-dev-ae1ee57f3906 ***
    *** Using nRF Connect SDK v3.0.1-9eb5615da66b ***
    *** Using Zephyr OS v4.0.99-77f865b8f8d0 ***
    *** Booting My Application v0.1.99-1dc24a14c5b1 ***
    *** Using nRF Connect SDK v3.0.1-9eb5615da66b ***
    *** Using Zephyr OS v4.0.99-77f865b8f8d0 ***
    Address of sample 0x24800
    Hello sysbuild with mcuboot! nrf54l15dk
    

    Steps I followed

    Steps:
    #Build code with sysbuild.
    #It should generate b0, S0, S1, App images
    #Then flash merged hex by erasing complete flash followed by programming merged hex
    nrfjprog -e
    nrfjprog --program build/merged.hex --sectorerase --verify
    
    #Then provision key using below command
    #This step is must to work
    west ncs-provision upload -s nrf54l15 -k b0_private_key_ed25519.pem --keyname BL_PUBKEY
    
    #Please note last option in above command. keyname should be BL_PUBKEY
    #If we use UROT_PUBKEY then it does not work.

    I'll revert all my debug logs and code and will recheck it multiple times to be sure.

    By the time if you get chance to review this then please suggest if any better way or correction to it.

    I am feeling Slight smile at the moment. And sorry for causing you trouble.

    Thanks & Best Regards,

    Nilesh 

  • Great! 

    The device log looks correct and as far as I can see from the description this does also look correct! 

    Happy to help! :) 

    Let me know if this answers your questions related to this case, if you have any followups related to this topic and feel free to open new cases for new topics and we'll help you out as best as we can!

    Kind regards,
    Andreas

Related