This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Extend flash size of nRF9160 - single slot application

Hi, we use nRF9160 and SDK 1.7.

in one of our applications, we need more than actually available flash. Now we have ~420kB for application - because we use MCUBoot and dual-slot memory in internal flash. To increase available flash size I want to set a single slot in internal flash and in the next step - set a second slot in the external SPI flash (for the bootloader).

So my question is: How to set a single slot in an internal flash and extend available flash for application?

Parents
  • Hi,

     

    in one of our applications, we need more than actually available flash. Now we have ~420kB for application - because we use MCUBoot and dual-slot memory in internal flash. To increase available flash size I want to set a single slot in internal flash and in the next step - set a second slot in the external SPI flash (for the bootloader).

    So my question is: How to set a single slot in an internal flash and extend available flash for application?

    This is a dual slot scenario, just that the second slot is in your external flash.

     

    Here's an example with mcuboot + hello_world that shows the bare minimal implementation of a SPI nor device as mcuboot second slot:

    hello_world_nrf9160_ext_flash.zip

    Note that the pm_static is provided as a reference, and any future updates must match the partition layout of your original project.

     

    Kind regards,

    Håkon

  • Thanks for the answer! Yes, You right - it's still dual-slot scenario.
    But I've got a problem - I'll try to run your project, but it stuck here:

    I use nRF9160-DK (PCA100900.15.0). I spend some time debugging but without any idea.

Reply Children
  • Hi,

     

    Mateusz Gancarczyk said:
    I use nRF9160-DK (PCA100900.15.0)

    My apologies, I should have mentioned that you need to switch in the SPI-flash on the DK.

    This is done by programming the nrf52 device (board nrf9160dk_nrf52840) with any simple example (hello_world or a modified blinky (ie: a empty main loop) for instance), with this overlay applied:

    / {
            board-control {
                    external_flash_pins_routing: switch-ext-mem-ctrl {
                            compatible = "nordic,nrf9160dk-optional-routing";
                            control-gpios = <&gpio0 19 GPIO_ACTIVE_HIGH>;
                            status = "okay";
                    };
            };
    };

     

    Switch the "PROG/DEBUG" switch to "nrf52" mode, configure and flash the project, then switch it back to nRF91 again.

     

    Kind regards,

    Håkon

Related