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

NRF9160DK problems downloading firmware

I've been having lots of issues putting the example projects on the NRF9160 dev kit.  It builds without errors, connects to J-Link, but sometimes fails on the download step.  Sometimes it works without any issues.  I select download Intel Hex file to the device and select merged.hex from the project I just built.  It will get to about 80% finished and give a "Failed to download application.  Undocumented error." error.  Then about 10-15 seconds later the Segger Embedded Studio crashes.  I am using SES v4.20a and it says there is an update available, but it tries to download the non-Nordic version.  Is it possible to not use the SES at all and just flash my device with firmare from the command line?  Is there a guide anywhere on how to do this?  

Any help is much appreciated!

 

Parents
  • You can always try to flash the HEX with nRF Connect - Programmer.

    OR using west
    OR using CMake
    OR using Ninja

    OR just try this:

    cd ${NORDICS}/ncs/nrf/applications/asset_tracker/build_nrf9160_pca10090ns/zephyr/merged.hex
    nrfjprog.exe --program merged.hex --sectorerase -r -f nrf91 --verify
    

  • Thank you for the quick reply.  I've had success flashing using both west and nrjprog. 

    The issue now is the device appears to be in a bad state after flashing with those methods.  The device appears to be continually rebooting.  In the LTE Link Monitor I'm seeing this output:

    SPM: NS image at 0xc000
    
    
    
    
    SPM: NS MSP at 0x2002ad60
    
    
    
    
    SPM: NS reset vector at 0x13db5
    
    
    
    
    SPM: prepare to jump to Non-Secure image.
    
    
    
    
    ***** Booting Zephyr OS v1.14.99-ncs2 *****


    then it shows Flash region and repeats.

    It also says:

    Non-secure callable region 0 placed in flash region 0 with size 32.

    So I'm wondering if maybe I've overwritten an important part of flash.  On a successful SES download, the device appears to be repaired.

    
    
Reply
  • Thank you for the quick reply.  I've had success flashing using both west and nrjprog. 

    The issue now is the device appears to be in a bad state after flashing with those methods.  The device appears to be continually rebooting.  In the LTE Link Monitor I'm seeing this output:

    SPM: NS image at 0xc000
    
    
    
    
    SPM: NS MSP at 0x2002ad60
    
    
    
    
    SPM: NS reset vector at 0x13db5
    
    
    
    
    SPM: prepare to jump to Non-Secure image.
    
    
    
    
    ***** Booting Zephyr OS v1.14.99-ncs2 *****


    then it shows Flash region and repeats.

    It also says:

    Non-secure callable region 0 placed in flash region 0 with size 32.

    So I'm wondering if maybe I've overwritten an important part of flash.  On a successful SES download, the device appears to be repaired.

    
    
Children
Related