I have searched all responses here and whatever sources I can find, but not have any success.
The main problem is that existing materials appear incompatible with the 54L range of parts, so following guides and dev academy materials proved somewhat frustrating.
The other observation is, I am starting out with Nordic and Zephyr as a beginner, and my entry device is a 54L15. That's probably part of the problem. No history with older parts.
So firstly, the elephant in the room … why is there no example for FOTA using the external flash memory and the 54L part?
Hopefully, if answers are posted here, maybe that elephant can be removed.
Board used is a Ezerio 54L15 Kit. (basically the same as a Nordic version - same pinout for MX25r64)
Project I am using as a base example is the "peripheral_lbs".
The board file used is nrf54l15dK/nrf54l15/cpuapp.
The overlay file is as below.
Build selected is sysbuild
Tool Chain is V3.0.2
Now regards adding FOTA, existing materials do appear somewhat applicable. The issue I believe I am facing is not knowing if the external flash is being addressed correctly.
This is where there is so much conflicting information on how to configure the flash for a 54L device and how to partition. Is the partition manager instruction applicable the 54 device?
To add, my current status is that I am able to do a sysbuild, load board with firmware and get the DFU symbol on the Nordic Phone app to appear. Downloading a new zip file with updated revision status does not write to external flash, but rather to address 0x000C4800 of the 54l memory space. Hence I believe there is an issue with how the flash is configured.
My prj.conf
CONFIG_NCS_SAMPLES_DEFAULTS=y
CONFIG_BT=y
CONFIG_BT_PERIPHERAL=y
CONFIG_BT_DEVICE_NAME="Nordic_LBS"
CONFIG_NORDIC_QSPI_NOR=y
# Enable the LBS service
CONFIG_BT_LBS=y
CONFIG_BT_LBS_POLL_BUTTON=y
CONFIG_DK_LIBRARY=y
CONFIG_SYSTEM_WORKQUEUE_STACK_SIZE=2048
CONFIG_NCS_SAMPLE_MCUMGR_BT_OTA_DFU=y
I manually created sysbuild.conf which has
SB_CONFIG_PARTITION_MANAGER=y
SB_CONFIG_BOOTLOADER_MCUBOOT=y
My overlay file...
/ {
chosen {
nordic,pm-ext-flash = &mx25r64;
};
};
/delete-node/ &boot_partition;
/delete-node/ &slot0_partition;
/delete-node/ &slot1_partition;
/delete-node/ &slot0_ns_partition;
/delete-node/ &slot1_ns_partition;
/delete-node/ &storage_partition;
&cpuapp_rram {
reg = < 0x0 DT_SIZE_K(1524) >;
partitions {
boot_partition: partition@0 {
label = "mcuboot";
reg = <0x000000000 0x00014000>;
};
slot0_partition: partition@14000 {
label = "image-0";
reg = <0x000014000 0x0015A000>;
};
storage_partition: partition@16E000 {
label = "storage";
reg = < 0x16E000 0x9000 >;
};
};
};
&mx25r64 {
status = "okay";
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
slot1_partition: partition@0 {
label = "image-1";
reg = <0x000000000 0x0015A000>;
};
};
};
&pinctrl {
spi00_default: spi00_default {
group1 {
psels = <NRF_PSEL(SPIM_MISO, 2, 4)>,
<NRF_PSEL(SPIM_MOSI, 2, 2)>,
<NRF_PSEL(SPIM_SCK, 2, 1)>;
};
};
/omit-if-no-ref/ spi00_sleep: spi00_sleep {
group1 {
psels = <NRF_PSEL(SPIM_SCK, 2, 1)>,
<NRF_PSEL(SPIM_MOSI, 2, 2)>,
<NRF_PSEL(SPIM_MISO, 2, 4)>;
low-power-enable;
};
};
};
&spi00 {
status = "okay";
cs-gpios = <&gpio2 5 GPIO_ACTIVE_LOW>;
pinctrl-0 = <&spi00_default>;
pinctrl-1 = <&spi00_sleep>;
pinctrl-names = "default", "sleep";
mx25r64: mx25r6435f@0 {
compatible = "jedec,spi-nor";
status = "okay";
reg = <0>;
spi-max-frequency = <2000000>;
jedec-id = [c2 28 17];
sfdp-bfp = [
e5 20 f1 ff ff ff ff 03 44 eb 08 6b 08 3b 04 bb
ee ff ff ff ff ff 00 ff ff ff 00 ff 0c 20 0f 52
10 d8 00 ff 23 72 f5 00 82 ed 04 cc 44 83 48 44
30 b0 30 b0 f7 c4 d5 5c 00 be 29 ff f0 d0 ff ff
];
size = <67108864>;
has-dpd;
t-enter-dpd = <10000>;
t-exit-dpd = <35000>;
};
};
Lastly, I did go into the nRF Kconfig GUI and "tick" NVS, but did not see any change.
Thank You.