Simultaneous DFU on nrf5340 and NCS 2.9.0 without external flash

Hello,

I am using NCS 2.9.0, an nRF5340, custom board files (see attached), and no external flash and I would like to use simultaneous DFU over BLE. I believe this should be possible because my application core image is only ~118kB and my netcore image is ~175kB (it has a custom synch protocol on top of the hci icp logic). I've done my best to read through the intermediate dev zone academy lessons regarding the mcu bootloader and it mentions that simultaneous updates should be possible without external flash:

but then links to this devacedmay blog post that only shows how to do this utilizing external flash. I believe it should be possible because in my mind I see the following: 


Where mcu primary is the app core code that is currently running, mcu secondary is where the new app core code goes, and mcu secondary_1 is where the new netcore code goes when an application update happens. So I have tried to add the following pm_static.yml file:

EMPTY_0:
  address: 0xfc000
  end_address: 0x100000
  placement:
    after:
    - mcuboot_secondary
  region: flash_primary
  size: 0x4000
app:
  address: 0x14000
  end_address: 0x84000
  region: flash_primary
  size: 0x70000
mcuboot:
  address: 0x0
  end_address: 0xc000
  placement:
    align:
      end: 0x1000
    before:
    - mcuboot_primary
  region: flash_primary
  size: 0xc000
mcuboot_pad:
  address: 0xc000
  end_address: 0xc200
  placement:
    align:
      start: 0x4000
    before:
    - mcuboot_primary_app
  region: flash_primary
  size: 0x200
mcuboot_primary:
  address: 0xc000
  end_address: 0x84000
  orig_span: &id001
  - app
  - tfm
  - mcuboot_pad
  region: flash_primary
  sharers: 0x1
  size: 0x78000
  span: *id001
mcuboot_primary_app:
  address: 0xc200
  end_address: 0x84000
  orig_span: &id002
  - app
  - tfm
  region: flash_primary
  size: 0x77e00
  span: *id002
mcuboot_secondary:
  address: 0x84000
  end_address: 0xfc000
  placement:
    after:
    - mcuboot_primary
    align:
      start: 0x4000
    align_next: 0x4000
  region: flash_primary
  share_size:
  - mcuboot_primary
  size: 0x78000
mcuboot_sram:
  address: 0x20000000
  end_address: 0x20008000
  orig_span: &id003
  - tfm_sram
  region: sram_primary
  size: 0x8000
  span: *id003
otp:
  address: 0xff8100
  end_address: 0xff83fc
  region: otp
  size: 0x2fc
rpmsg_nrf53_sram:
  address: 0x20070840
  end_address: 0x20080000
  placement:
    before:
    - end
  region: sram_primary
  size: 0xf7c0
sram_nonsecure:
  address: 0x20008000
  end_address: 0x20080000
  orig_span: &id004
  - sram_primary
  - rpmsg_nrf53_sram
  region: sram_primary
  size: 0x78000
  span: *id004
sram_primary:
  address: 0x20008000
  end_address: 0x20070840
  region: sram_primary
  size: 0x68840
sram_secure:
  address: 0x20000000
  end_address: 0x20008000
  orig_span: &id005
  - tfm_sram
  region: sram_primary
  size: 0x8000
  span: *id005
tfm:
  address: 0xc200
  end_address: 0x14000
  inside:
  - mcuboot_primary_app
  placement:
    before:
    - app
  region: flash_primary
  size: 0x7e00
tfm_nonsecure:
  address: 0x14000
  end_address: 0x84000
  orig_span: &id006
  - app
  region: flash_primary
  size: 0x70000
  span: *id006
tfm_secure:
  address: 0xc000
  end_address: 0x14000
  orig_span: &id007
  - mcuboot_pad
  - tfm
  region: flash_primary
  size: 0x8000
  span: *id007
tfm_sram:
  address: 0x20000000
  end_address: 0x20008000
  inside:
  - sram_secure
  placement:
    after:
    - start
  region: sram_primary
  size: 0x8000


The names are bit different than my diagram but I followed the advice of other similar posts and documentation regarding DFU and copied a build partitions.yml file from one of my successful builds. I have also added the following configs to my sysbuild.conf:

SB_CONFIG_REMOTE_BOARD="candi/nrf5340/cpunet"
SB_CONFIG_BOOTLOADER_MCUBOOT=y
SB_CONFIG_NETCORE_APP_UPDATE=y
SB_CONFIG_SECURE_BOOT_NETCORE=y
SB_CONFIG_MCUBOOT_UPDATEABLE_IMAGES=2
SB_CONFIG_MCUBOOT_NRF53_MULTI_IMAGE_UPDATE=y
SB_CONFIG_MCUBOOT_MODE_OVERWRITE_ONLY=y


Added these two lines to my prj.conf:

CONFIG_BOOTLOADER_MCUBOOT=y
CONFIG_NCS_SAMPLE_MCUMGR_BT_OTA_DFU=y


Do I need to set configs for utilizing flash even tho there is no external flash? When I build with the above configs I get the following errors:



I'm not sure how to proceed because I'm having a hard time understanding what these pm_static.yaml file names are supposed to be and I'm not getting the same sort of errors as these previous related posts:

- simultaneous DFU on nRF5340 and NCS 2.6.1 without external flash
- nrf5340 custom board non-simultaneous updates without external flash with sysbuild on ncs2.7.0+

---
I know from the "Official Simultaneous multi-image DFU with nRF5340 DK" docs that I need to have the following partitions:
1) mcuboot_primary
2) mcuboot_secondary
3) mcuboot_rimary_1
4) mcuboot_secondary_1
5) pcd_sram 

and I see the note regarding the placement of mcuboot_primary_1 inside of ram_flash region but I don't understand the second comment about "CONFIG_FLASH_SIMULATOR" within the docs. I'm having a hard time understanding how to get this running because I'm not even hitting the errors I would expect to hit. Instead I'm getting stuff related to the partition_manager.py scripts' arguments... 
---

Do I need to setup a pm_static.yaml file for my custom netcore image too? I don't think so from the docs but I can't find the exact reference that makes me think this but I'm asking just in case. 

---
I utilize the following shared memory overlay within my code base and I don't think I'm correctly partitioning for it within my pm_static.yaml file:

Can you help with this too? It is the only reason I think that adding a partition file for the network core might be needed in addition but I'm really not sure. 

Thank you so much for all of your help and time. 

Respectfully,
Brady Adcock

Parents
  • Hello,

    I will look more into the application you have shared, but let's clarify a few things first. Are you trying to implement DFU over BLE? The guide you pointed to covers that. In that case, I don't see any configuration enabling BLE inside your sample.
    I am not sure, but could it be because the network core image is not mentioned inside the Kconfig.sysbuild file? Please refer to this chapter of the course.

    Kind regards,
    Abhijith

  • Hey Menon, thank you for the quick reply and for pointing out that, obviously, I need BLE enabled for the SMP service to be advertised and connected to, so I went ahead and uploaded my custom net core image that handles the IPC communication as well as my synch protocol to the example repo. I had a brain fart because we are not even getting to that part of the build process, unfortunately. I updated main with the changes, and if you remove the sys build configs for simultaneous dfu you'll see that ble works as expected:



    But when I enable all of the configs from the lessons regarding simultaneous dfu we don't get very far into the build at all because we see the exact same original error from before regarding the flash memory config that I've posted a few times now. 

     *  Executing task: nRF Connect: Build [pristine]: sim_dfu/build_pls (active) 
    
    Building template
    C:\WINDOWS\system32\cmd.exe /d /s /c "west build --build-dir c:/Impulse/sim_dfu/build_pls c:/Impulse/sim_dfu --pristine --board nrf5340dk/nrf5340/cpuapp/ns --sysbuild -- -DNCS_TOOLCHAIN_VERSION=NONE -DCONF_FILE=c:/Impulse/sim_dfu/prj.conf -DDTC_OVERLAY_FILE=boards/nrf5340dk_nrf5340_cpuapp_ns.overlay -DBOARD_ROOT=c:\Impulse\sim_dfu"
    
    -- west build: generating a build system
    Loading Zephyr module(s) (Zephyr base): sysbuild_default
    -- Found Python3: C:/ncs/toolchains/b620d30767/opt/bin/python.exe (found suitable version "3.12.4", minimum required is "3.8") found components: Interpreter 
    -- Cache files will be written to: C:/ncs/v2.9.0/zephyr/.cache
    -- Found west (found suitable version "1.2.0", minimum required is "0.14.0")
    -- Board: nrf5340dk, qualifiers: nrf5340/cpuapp/ns
    
    warning: NETCORE_APP_UPDATE (defined at C:/ncs/v2.9.0/nrf/sysbuild\Kconfig.netcore:170) was assigned
    the value 'y' but got the value 'n'. Check these unsatisfied dependencies: (!NETCORE_NONE) (=n). See
    http://docs.zephyrproject.org/latest/kconfig.html#CONFIG_NETCORE_APP_UPDATE and/or look up
    NETCORE_APP_UPDATE in the menuconfig/guiconfig interface. The Application Development Primer,
    Setting Configuration Values, and Kconfig - Tips and Best Practices sections of the manual might be
    helpful too.
    
    
    warning: MCUBOOT_NRF53_MULTI_IMAGE_UPDATE (defined at
    C:/ncs/v2.9.0/nrf/sysbuild\Kconfig.mcuboot:177) was assigned the value 'y' but got the value 'n'.
    Check these unsatisfied dependencies: NETCORE_APP_UPDATE (=n). See
    http://docs.zephyrproject.org/latest/kconfig.html#CONFIG_MCUBOOT_NRF53_MULTI_IMAGE_UPDATE and/or
    look up MCUBOOT_NRF53_MULTI_IMAGE_UPDATE in the menuconfig/guiconfig interface. The Application
    Development Primer, Setting Configuration Values, and Kconfig - Tips and Best Practices sections of
    the manual might be helpful too.
    
    Parsing c:/Impulse/sim_dfu/Kconfig.sysbuild
    Loaded configuration 'C:/Impulse/sim_dfu/build_pls/_sysbuild/empty.conf'
    Merged configuration 'c:/Impulse/sim_dfu/sysbuild.conf'
    Configuration saved to 'C:/Impulse/sim_dfu/build_pls/zephyr/.config'
    Kconfig header saved to 'C:/Impulse/sim_dfu/build_pls/_sysbuild/autoconf.h'
    -- Adding overlay config from C:/Impulse/sim_dfu/tkos_net/debug.conf to net image
    -- Adding devicetree overlay from C:/Impulse/sim_dfu/tkos_net/nrf5340dk_nrf5340_cpunet.overlay
    -- 
       *****************************
       * Running CMake for mcuboot *
       *****************************
    
    Loading Zephyr default modules (Zephyr base).
    -- Application: C:/ncs/v2.9.0/bootloader/mcuboot/boot/zephyr
    -- CMake version: 3.21.0
    -- Found Python3: C:/ncs/toolchains/b620d30767/opt/bin/python.exe (found suitable version "3.12.4", minimum required is "3.8") found components: Interpreter 
    -- Cache files will be written to: C:/ncs/v2.9.0/zephyr/.cache
    -- Zephyr version: 3.7.99 (C:/ncs/v2.9.0/zephyr)
    -- Found west (found suitable version "1.2.0", minimum required is "0.14.0")
    -- Board: nrf5340dk, qualifiers: nrf5340/cpuapp
    -- Found host-tools: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found toolchain: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found Dtc: C:/ncs/toolchains/b620d30767/opt/bin/dtc.exe (found suitable version "1.4.7", minimum required is "1.4.6") 
    -- Found BOARD.dts: C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpuapp.dts
    -- Found devicetree overlay: C:/Impulse/sim_dfu/sysbuild/mcuboot.overlay
    -- Generated zephyr.dts: C:/Impulse/sim_dfu/build_pls/mcuboot/zephyr/zephyr.dts
    -- Generated devicetree_generated.h: C:/Impulse/sim_dfu/build_pls/mcuboot/zephyr/include/generated/zephyr/devicetree_generated.h
    -- Including generated dts.cmake file: C:/Impulse/sim_dfu/build_pls/mcuboot/zephyr/dts.cmake
    Parsing C:/ncs/v2.9.0/bootloader/mcuboot/boot/zephyr/Kconfig
    Loaded configuration 'C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpuapp_defconfig'
    Merged configuration 'C:/ncs/v2.9.0/bootloader/mcuboot/boot/zephyr/prj.conf'
    Merged configuration 'C:/Impulse/sim_dfu/sysbuild/mcuboot.conf'
    Merged configuration 'C:/ncs/v2.9.0/nrf/modules/mcuboot/tfm.conf'
    Merged configuration 'C:/ncs/v2.9.0/nrf/modules/mcuboot/fih_low_enable.conf'
    Merged configuration 'C:/ncs/v2.9.0/nrf/subsys/partition_manager/ext_flash_mcuboot_secondary.conf'
    Merged configuration 'C:/Impulse/sim_dfu/build_pls/mcuboot/zephyr/.config.sysbuild'
    Configuration saved to 'C:/Impulse/sim_dfu/build_pls/mcuboot/zephyr/.config'
    Kconfig header saved to 'C:/Impulse/sim_dfu/build_pls/mcuboot/zephyr/include/generated/zephyr/autoconf.h'
    -- Found GnuLd: c:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/arm-zephyr-eabi/bin/ld.bfd.exe (found version "2.38") 
    -- The C compiler identification is GNU 12.2.0
    -- The CXX compiler identification is GNU 12.2.0
    -- The ASM compiler identification is GNU
    -- Found assembler: C:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc.exe
    -- Setting build type to 'MinSizeRel' as none was specified.
    MCUBoot bootloader key file: C:/ncs/v2.9.0/bootloader/mcuboot/root-rsa-2048.pem
    -- Configuring done
    -- Generating done
    -- Build files have been written to: C:/Impulse/sim_dfu/build_pls/mcuboot
    -- 
       *************************
       * Running CMake for b0n *
       *************************
    
    Loading Zephyr default modules (Zephyr base).
    -- Application: C:/ncs/v2.9.0/nrf/samples/nrf5340/netboot
    -- CMake version: 3.21.0
    -- Found Python3: C:/ncs/toolchains/b620d30767/opt/bin/python.exe (found suitable version "3.12.4", minimum required is "3.8") found components: Interpreter 
    -- Cache files will be written to: C:/ncs/v2.9.0/zephyr/.cache
    -- Zephyr version: 3.7.99 (C:/ncs/v2.9.0/zephyr)
    -- Found west (found suitable version "1.2.0", minimum required is "0.14.0")
    -- Board: nrf5340dk, qualifiers: nrf5340/cpunet
    -- Found host-tools: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found toolchain: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found Dtc: C:/ncs/toolchains/b620d30767/opt/bin/dtc.exe (found suitable version "1.4.7", minimum required is "1.4.6") 
    -- Found BOARD.dts: C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpunet.dts
    -- Generated zephyr.dts: C:/Impulse/sim_dfu/build_pls/b0n/zephyr/zephyr.dts
    -- Generated devicetree_generated.h: C:/Impulse/sim_dfu/build_pls/b0n/zephyr/include/generated/zephyr/devicetree_generated.h
    -- Including generated dts.cmake file: C:/Impulse/sim_dfu/build_pls/b0n/zephyr/dts.cmake
    Parsing C:/ncs/v2.9.0/nrf/samples/nrf5340/netboot/Kconfig
    Loaded configuration 'C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpunet_defconfig'
    Merged configuration 'C:/ncs/v2.9.0/nrf/samples/nrf5340/netboot/prj.conf'
    Merged configuration 'C:/Impulse/sim_dfu/build_pls/b0n/zephyr/.config.sysbuild'
    Configuration saved to 'C:/Impulse/sim_dfu/build_pls/b0n/zephyr/.config'
    Kconfig header saved to 'C:/Impulse/sim_dfu/build_pls/b0n/zephyr/include/generated/zephyr/autoconf.h'
    -- Found GnuLd: c:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/arm-zephyr-eabi/bin/ld.bfd.exe (found version "2.38") 
    -- The C compiler identification is GNU 12.2.0
    -- The CXX compiler identification is GNU 12.2.0
    -- The ASM compiler identification is GNU
    -- Found assembler: C:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc.exe
    -- Setting build type to 'MinSizeRel' as none was specified.
    CMake Warning at C:/ncs/v2.9.0/zephyr/CMakeLists.txt:2133 (message):
      __ASSERT() statements are globally ENABLED
    
    
    -- Configuring done
    -- Generating done
    -- Build files have been written to: C:/Impulse/sim_dfu/build_pls/b0n
    -- 
       ******************************
       * Running CMake for tkos_net *
       ******************************
    
    Loading Zephyr default modules (Zephyr base).
    -- Application: C:/Impulse/sim_dfu/tkos_net
    -- CMake version: 3.21.0
    -- Found Python3: C:/ncs/toolchains/b620d30767/opt/bin/python.exe (found suitable version "3.12.4", minimum required is "3.8") found components: Interpreter 
    -- Cache files will be written to: C:/ncs/v2.9.0/zephyr/.cache
    -- Zephyr version: 3.7.99 (C:/ncs/v2.9.0/zephyr)
    -- Found west (found suitable version "1.2.0", minimum required is "0.14.0")
    -- Board: nrf5340dk, qualifiers: nrf5340/cpunet
    -- Found host-tools: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found toolchain: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found Dtc: C:/ncs/toolchains/b620d30767/opt/bin/dtc.exe (found suitable version "1.4.7", minimum required is "1.4.6") 
    -- Found BOARD.dts: C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpunet.dts
    -- Found devicetree overlay: C:/Impulse/sim_dfu/tkos_net/nrf5340dk_nrf5340_cpunet.overlay
    -- Found devicetree overlay: C:/Impulse/sim_dfu/tkos_net/nrf5340dk_nrf5340_cpunet.overlay
    -- Generated zephyr.dts: C:/Impulse/sim_dfu/build_pls/tkos_net/zephyr/zephyr.dts
    -- Generated devicetree_generated.h: C:/Impulse/sim_dfu/build_pls/tkos_net/zephyr/include/generated/zephyr/devicetree_generated.h
    -- Including generated dts.cmake file: C:/Impulse/sim_dfu/build_pls/tkos_net/zephyr/dts.cmake
    Parsing C:/Impulse/sim_dfu/tkos_net/Kconfig
    Loaded configuration 'C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpunet_defconfig'
    Merged configuration 'C:/Impulse/sim_dfu/tkos_net/prj.conf'
    Merged configuration 'C:/Impulse/sim_dfu/tkos_net/debug_overlay.conf'
    Merged configuration 'C:/Impulse/sim_dfu/build_pls/tkos_net/zephyr/.config.sysbuild'
    Configuration saved to 'C:/Impulse/sim_dfu/build_pls/tkos_net/zephyr/.config'
    Kconfig header saved to 'C:/Impulse/sim_dfu/build_pls/tkos_net/zephyr/include/generated/zephyr/autoconf.h'
    -- Found GnuLd: c:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/arm-zephyr-eabi/bin/ld.bfd.exe (found version "2.38") 
    -- The C compiler identification is GNU 12.2.0
    -- The CXX compiler identification is GNU 12.2.0
    -- The ASM compiler identification is GNU
    -- Found assembler: C:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc.exe
    -- libmetal version: 1.6.0 (C:/Impulse/sim_dfu/tkos_net)
    -- Build type:  
    -- Host:    Windows/AMD64
    -- Target:  Generic/arm
    -- Machine: arm
    -- Looking for include file stdatomic.h
    -- Looking for include file stdatomic.h - found
    -- open-amp version: 1.6.1 (C:/ncs/v2.9.0/modules/lib/open-amp/open-amp)
    -- Host:    Windows/AMD64
    -- Target:  Generic/arm
    -- Machine: arm
    -- C_FLAGS :  -Wall -Wextra
    -- Looking for include file fcntl.h
    -- Looking for include file fcntl.h - found
    -- Setting build type to 'MinSizeRel' as none was specified.
    -- Configuring done
    -- Generating done
    -- Build files have been written to: C:/Impulse/sim_dfu/build_pls/tkos_net
    -- 
       *****************************
       * Running CMake for sim_dfu *
       *****************************
    
    CMake Warning at CMakeLists.txt:4 (message):
      Zephyr base: c:\ncs\v2.9.0\zephyr
    
    
    Loading Zephyr default modules (Zephyr base).
    -- Application: C:/Impulse/sim_dfu
    -- CMake version: 3.21.0
    -- Found Python3: C:/ncs/toolchains/b620d30767/opt/bin/python.exe (found suitable version "3.12.4", minimum required is "3.8") found components: Interpreter 
    -- Cache files will be written to: C:/ncs/v2.9.0/zephyr/.cache
    -- Zephyr version: 3.7.99 (C:/ncs/v2.9.0/zephyr)
    -- Found west (found suitable version "1.2.0", minimum required is "0.14.0")
    -- Board: nrf5340dk, qualifiers: nrf5340/cpuapp/ns
    -- Found host-tools: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found toolchain: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found Dtc: C:/ncs/toolchains/b620d30767/opt/bin/dtc.exe (found suitable version "1.4.7", minimum required is "1.4.6") 
    -- Found BOARD.dts: C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpuapp_ns.dts
    -- Found devicetree overlay: boards/nrf5340dk_nrf5340_cpuapp_ns.overlay
    -- Generated zephyr.dts: C:/Impulse/sim_dfu/build_pls/sim_dfu/zephyr/zephyr.dts
    -- Generated devicetree_generated.h: C:/Impulse/sim_dfu/build_pls/sim_dfu/zephyr/include/generated/zephyr/devicetree_generated.h
    -- Including generated dts.cmake file: C:/Impulse/sim_dfu/build_pls/sim_dfu/zephyr/dts.cmake
    
    warning: PM_EXTERNAL_FLASH_MCUBOOT_SECONDARY (defined at
    C:/ncs/v2.9.0/nrf\subsys\partition_manager/Kconfig:214) was assigned the value 'y' but got the value
    'n'. Check these unsatisfied dependencies: (PM_EXTERNAL_FLASH_ENABLED || MCUBOOT) (=n). See
    http://docs.zephyrproject.org/latest/kconfig.html#CONFIG_PM_EXTERNAL_FLASH_MCUBOOT_SECONDARY and/or
    look up PM_EXTERNAL_FLASH_MCUBOOT_SECONDARY in the menuconfig/guiconfig interface. The Application
    Development Primer, Setting Configuration Values, and Kconfig - Tips and Best Practices sections of
    the manual might be helpful too.
    
    Parsing C:/ncs/v2.9.0/zephyr/Kconfig
    Loaded configuration 'C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpuapp_ns_defconfig'
    Merged configuration 'c:/Impulse/sim_dfu/prj.conf'
    Merged configuration 'C:/Impulse/sim_dfu/build_pls/sim_dfu/zephyr/.config.sysbuild'
    Configuration saved to 'C:/Impulse/sim_dfu/build_pls/sim_dfu/zephyr/.config'
    Kconfig header saved to 'C:/Impulse/sim_dfu/build_pls/sim_dfu/zephyr/include/generated/zephyr/autoconf.h'
    -- Found GnuLd: c:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/arm-zephyr-eabi/bin/ld.bfd.exe (found version "2.38") 
    -- The C compiler identification is GNU 12.2.0
    -- The CXX compiler identification is GNU 12.2.0
    -- The ASM compiler identification is GNU
    -- Found assembler: C:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc.exe
    CMake Warning at C:/ncs/v2.9.0/nrf/samples/common/mcumgr_bt_ota_dfu/CMakeLists.txt:27 (message):
      MCUmgr Bluetooth OTA DFU: suboptimal configuration of Bluetooth Host
      buffers.  Consider using optimal values defined in the
      C:/ncs/v2.9.0/nrf/samples/common/mcumgr_bt_ota_dfu/Kconfig file for
      CONFIG_BT_BUF_ACL_TX_SIZE, CONFIG_BT_BUF_ACL_RX_SIZE and
      CONFIG_BT_L2CAP_TX_MTU options
    
    
    =========== Generating psa_crypto_config ===============
    Backup: CONFIG_MBEDTLS_PSA_CRYPTO_SPM: False
    Backup: CONFIG_MBEDTLS_PSA_CRYPTO_C: False
    Backup: CONFIG_MBEDTLS_PSA_CRYPTO_KEY_ID_ENCODES_OWNER: False
    Backup: CONFIG_MBEDTLS_PLATFORM_SETUP_TEARDOWN_ALT: False
    Backup: CONFIG_MBEDTLS_THREADING: False
    Backup: CONFIG_MBEDTLS_THREADING_ALT: False
    =========== Checkpoint: backup ===============
    Restore: CONFIG_MBEDTLS_PSA_CRYPTO_SPM: False
    Restore: CONFIG_MBEDTLS_PSA_CRYPTO_C: False
    Restore: CONFIG_MBEDTLS_PSA_CRYPTO_KEY_ID_ENCODES_OWNER: False
    Restore: CONFIG_MBEDTLS_PLATFORM_SETUP_TEARDOWN_ALT: False
    Restore: CONFIG_MBEDTLS_THREADING: False
    Restore: CONFIG_MBEDTLS_THREADING_ALT: False
    =========== End psa_crypto_config ===============
    =========== Generating psa_crypto_library_config ===============
    Backup: CONFIG_MBEDTLS_PSA_CRYPTO_C: False
    Backup: CONFIG_MBEDTLS_PSA_CRYPTO_KEY_ID_ENCODES_OWNER: False
    Backup: CONFIG_MBEDTLS_PSA_CRYPTO_SPM: False
    Backup: CONFIG_MBEDTLS_USE_PSA_CRYPTO: True
    Backup: CONFIG_MBEDTLS_PLATFORM_PRINTF_ALT: False
    Backup: CONFIG_MBEDTLS_THREADING: False
    Backup: CONFIG_MBEDTLS_THREADING_ALT: False
    =========== Checkpoint: backup ===============
    Restore: CONFIG_MBEDTLS_PSA_CRYPTO_C: False
    Restore: CONFIG_MBEDTLS_PSA_CRYPTO_KEY_ID_ENCODES_OWNER: False
    Restore: CONFIG_MBEDTLS_PSA_CRYPTO_SPM: False
    Restore: CONFIG_MBEDTLS_USE_PSA_CRYPTO: True
    Restore: CONFIG_MBEDTLS_PLATFORM_PRINTF_ALT: False
    Restore: CONFIG_MBEDTLS_THREADING: False
    Restore: CONFIG_MBEDTLS_THREADING_ALT: False
    =========== End psa_crypto_library_config ===============
    -- libmetal version: 1.6.0 (C:/Impulse/sim_dfu)
    -- Build type:  
    -- Host:    Windows/AMD64
    -- Target:  Generic/arm
    -- Machine: arm
    -- Looking for include file stdatomic.h
    -- Looking for include file stdatomic.h - found
    -- open-amp version: 1.6.1 (C:/ncs/v2.9.0/modules/lib/open-amp/open-amp)
    -- Host:    Windows/AMD64
    -- Target:  Generic/arm
    -- Machine: arm
    -- C_FLAGS :  -Wall -Wextra
    -- Looking for include file fcntl.h
    -- Looking for include file fcntl.h - found
    -- Setting build type to 'MinSizeRel' as none was specified.
    -- Including signing script: C:/ncs/v2.9.0/nrf/cmake/sysbuild/image_signing.cmake
    -- Configuring done
    -- Generating done
    -- Build files have been written to: C:/Impulse/sim_dfu/build_pls/sim_dfu
    CMake Warning at C:/ncs/v2.9.0/nrf/cmake/sysbuild/debug_keys.cmake:21 (message):
      
    
          --------------------------------------------------------------
          --- WARNING: Using generated NSIB public/private key-pair. ---
          --- It should not be used for production.                  ---
          --- See SB_CONFIG_SECURE_BOOT_SIGNING_KEY_FILE             ---
          --------------------------------------------------------------
          
    
    Call Stack (most recent call first):
      C:/ncs/v2.9.0/nrf/cmake/sysbuild/provision_hex.cmake:11 (include)
      C:/ncs/v2.9.0/nrf/sysbuild/CMakeLists.txt:55 (include)
      C:/ncs/v2.9.0/nrf/sysbuild/CMakeLists.txt:667 (include_provision_hex)
      cmake/modules/sysbuild_extensions.cmake:583 (nrf_POST_CMAKE)
      cmake/modules/sysbuild_extensions.cmake:583 (cmake_language)
      cmake/modules/sysbuild_images.cmake:23 (sysbuild_module_call)
      cmake/modules/sysbuild_default.cmake:20 (include)
      C:/ncs/v2.9.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:75 (include)
      C:/ncs/v2.9.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:92 (include_boilerplate)
      C:/ncs/v2.9.0/zephyr/share/sysbuild-package/cmake/SysbuildConfig.cmake:8 (include)
      template/CMakeLists.txt:10 (find_package)
    
    
    CMake Warning at C:/ncs/v2.9.0/nrf/cmake/sysbuild/partition_manager.cmake:106 (message):
      
    
            ---------------------------------------------------------------------
            --- WARNING: Using a bootloader without pm_static.yml.            ---
            --- There are cases where a deployed product can consist of       ---
            --- multiple images, and only a subset of these images can be     ---
            --- upgraded through a firmware update mechanism. In such cases,  ---
            --- the upgradable images must have partitions that are static    ---
            --- and are matching the partition map used by the bootloader     ---
            --- programmed onto the device.                                   ---
            ---------------------------------------------------------------------
            
    
    Call Stack (most recent call first):
      C:/ncs/v2.9.0/nrf/cmake/sysbuild/partition_manager.cmake:634 (partition_manager)
      C:/ncs/v2.9.0/nrf/sysbuild/CMakeLists.txt:703 (include)
      cmake/modules/sysbuild_extensions.cmake:583 (nrf_POST_CMAKE)
      cmake/modules/sysbuild_extensions.cmake:583 (cmake_language)
      cmake/modules/sysbuild_images.cmake:23 (sysbuild_module_call)
      cmake/modules/sysbuild_default.cmake:20 (include)
      C:/ncs/v2.9.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:75 (include)
      C:/ncs/v2.9.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:92 (include_boilerplate)
      C:/ncs/v2.9.0/zephyr/share/sysbuild-package/cmake/SysbuildConfig.cmake:8 (include)
      template/CMakeLists.txt:10 (find_package)
    
    
    Traceback (most recent call last):
      File "C:\ncs\v2.9.0\nrf\scripts\partition_manager.py", line 2045, in <module>
        main()
      File "C:\ncs\v2.9.0\nrf\scripts\partition_manager.py", line 1023, in main
        pm_config = load_reqs(args.input_files)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "C:\ncs\v2.9.0\nrf\scripts\partition_manager.py", line 689, in load_reqs
        raise PartitionError(
    PartitionError: Conflicting configuration found for 'C:/Impulse/sim_dfu/build_pls/mcuboot/modules/nrf/subsys/partition_manager/pm.yml.rpmsg_nrf53' value for key 'rpmsg_nrf53_sram' differs. val1: {'placement': {'before': 'end'}, 'size': 65536, 'region': 'sram_primary'} val2: {'placement': {'before': 'end'}, 'size': 63424, 'region': 'sram_primary'} 
    CMake Error at C:/ncs/v2.9.0/nrf/cmake/sysbuild/partition_manager.cmake:167 (message):
      Partition Manager failed, aborting.  Command:
      C:/ncs/toolchains/b620d30767/opt/bin/python.exe;C:/ncs/v2.9.0/nrf/scripts/partition_manager.py;--input-files;C:/Impulse/sim_dfu/build_pls/sim_dfu/modules/nrf/subsys/partition_manager/pm.yml.rpmsg_nrf53;C:/Impulse/sim_dfu/build_pls/sim_dfu/modules/nrf/subsys/partition_manager/pm.yml.tfm;C:/Impulse/sim_dfu/build_pls/sim_dfu/modules/nrf/subsys/partition_manager/pm.yml.trustzone;C:/Impulse/sim_dfu/build_pls/sim_dfu/modules/nrf/subsys/partition_manager/pm.yml.mcuboot;C:/Impulse/sim_dfu/build_pls/mcuboot/zephyr/include/generated/pm.yml;C:/Impulse/sim_dfu/build_pls/mcuboot/modules/nrf/subsys/partition_manager/pm.yml.rpmsg_nrf53;C:/Impulse/sim_dfu/build_pls/sim_dfu/zephyr/include/generated/pm.yml;--regions;sram_primary;otp;flash_primary;--output-partitions;C:/Impulse/sim_dfu/build_pls/partitions.yml;--output-regions;C:/Impulse/sim_dfu/build_pls/regions.yml;--sram_primary-size;0x80000;--sram_primary-base-address;0x20000000;--sram_primary-placement-strategy;complex;--sram_primary-dynamic-partition;sram_primary;--otp-size;764;--otp-base-address;0xff8100;--otp-placement-strategy;start_to_end;--flash_primary-size;0x100000;--flash_primary-base-address;0x0;--flash_primary-placement-strategy;complex;--flash_primary-device;flash_controller;--flash_primary-default-driver-kconfig;CONFIG_SOC_FLASH_NRF
    Call Stack (most recent call first):
      C:/ncs/v2.9.0/nrf/cmake/sysbuild/partition_manager.cmake:634 (partition_manager)
      C:/ncs/v2.9.0/nrf/sysbuild/CMakeLists.txt:703 (include)
      cmake/modules/sysbuild_extensions.cmake:583 (nrf_POST_CMAKE)
      cmake/modules/sysbuild_extensions.cmake:583 (cmake_language)
      cmake/modules/sysbuild_images.cmake:23 (sysbuild_module_call)
      cmake/modules/sysbuild_default.cmake:20 (include)
      C:/ncs/v2.9.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:75 (include)
      C:/ncs/v2.9.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:92 (include_boilerplate)
      C:/ncs/v2.9.0/zephyr/share/sysbuild-package/cmake/SysbuildConfig.cmake:8 (include)
      template/CMakeLists.txt:10 (find_package)
    
    
    -- Configuring incomplete, errors occurred!
    See also "C:/Impulse/sim_dfu/build_pls/CMakeFiles/CMakeOutput.log".
    FATAL ERROR: command exited with status 1: 'C:\ncs\toolchains\b620d30767\opt\bin\cmake.EXE' -DWEST_PYTHON=C:/ncs/toolchains/b620d30767/opt/bin/python.exe '-Bc:\Impulse\sim_dfu\build_pls' -GNinja -DBOARD=nrf5340dk/nrf5340/cpuapp/ns -DNCS_TOOLCHAIN_VERSION=NONE -DCONF_FILE=c:/Impulse/sim_dfu/prj.conf -DDTC_OVERLAY_FILE=boards/nrf5340dk_nrf5340_cpuapp_ns.overlay '-DBOARD_ROOT=c:\Impulse\sim_dfu' '-SC:\ncs\v2.9.0\zephyr\share\sysbuild' '-DAPP_DIR:PATH=c:\Impulse\sim_dfu'
    
     *  The terminal process terminated with exit code: 1. 
     *  Terminal will be reused by tasks, press any key to close it. 


    This is clearly because my current cmake sysbuild config doesn't enable the network core config "NETCORE_NONE" = n and its not clear how I'm supposed to do that. Obviously by using your prebuilt ipc image that config is getting set but I'm not sure how. 

    Here is the updated code if you prefer a zip instead of github:
    3630.sim_dfu.zip

Reply
  • Hey Menon, thank you for the quick reply and for pointing out that, obviously, I need BLE enabled for the SMP service to be advertised and connected to, so I went ahead and uploaded my custom net core image that handles the IPC communication as well as my synch protocol to the example repo. I had a brain fart because we are not even getting to that part of the build process, unfortunately. I updated main with the changes, and if you remove the sys build configs for simultaneous dfu you'll see that ble works as expected:



    But when I enable all of the configs from the lessons regarding simultaneous dfu we don't get very far into the build at all because we see the exact same original error from before regarding the flash memory config that I've posted a few times now. 

     *  Executing task: nRF Connect: Build [pristine]: sim_dfu/build_pls (active) 
    
    Building template
    C:\WINDOWS\system32\cmd.exe /d /s /c "west build --build-dir c:/Impulse/sim_dfu/build_pls c:/Impulse/sim_dfu --pristine --board nrf5340dk/nrf5340/cpuapp/ns --sysbuild -- -DNCS_TOOLCHAIN_VERSION=NONE -DCONF_FILE=c:/Impulse/sim_dfu/prj.conf -DDTC_OVERLAY_FILE=boards/nrf5340dk_nrf5340_cpuapp_ns.overlay -DBOARD_ROOT=c:\Impulse\sim_dfu"
    
    -- west build: generating a build system
    Loading Zephyr module(s) (Zephyr base): sysbuild_default
    -- Found Python3: C:/ncs/toolchains/b620d30767/opt/bin/python.exe (found suitable version "3.12.4", minimum required is "3.8") found components: Interpreter 
    -- Cache files will be written to: C:/ncs/v2.9.0/zephyr/.cache
    -- Found west (found suitable version "1.2.0", minimum required is "0.14.0")
    -- Board: nrf5340dk, qualifiers: nrf5340/cpuapp/ns
    
    warning: NETCORE_APP_UPDATE (defined at C:/ncs/v2.9.0/nrf/sysbuild\Kconfig.netcore:170) was assigned
    the value 'y' but got the value 'n'. Check these unsatisfied dependencies: (!NETCORE_NONE) (=n). See
    http://docs.zephyrproject.org/latest/kconfig.html#CONFIG_NETCORE_APP_UPDATE and/or look up
    NETCORE_APP_UPDATE in the menuconfig/guiconfig interface. The Application Development Primer,
    Setting Configuration Values, and Kconfig - Tips and Best Practices sections of the manual might be
    helpful too.
    
    
    warning: MCUBOOT_NRF53_MULTI_IMAGE_UPDATE (defined at
    C:/ncs/v2.9.0/nrf/sysbuild\Kconfig.mcuboot:177) was assigned the value 'y' but got the value 'n'.
    Check these unsatisfied dependencies: NETCORE_APP_UPDATE (=n). See
    http://docs.zephyrproject.org/latest/kconfig.html#CONFIG_MCUBOOT_NRF53_MULTI_IMAGE_UPDATE and/or
    look up MCUBOOT_NRF53_MULTI_IMAGE_UPDATE in the menuconfig/guiconfig interface. The Application
    Development Primer, Setting Configuration Values, and Kconfig - Tips and Best Practices sections of
    the manual might be helpful too.
    
    Parsing c:/Impulse/sim_dfu/Kconfig.sysbuild
    Loaded configuration 'C:/Impulse/sim_dfu/build_pls/_sysbuild/empty.conf'
    Merged configuration 'c:/Impulse/sim_dfu/sysbuild.conf'
    Configuration saved to 'C:/Impulse/sim_dfu/build_pls/zephyr/.config'
    Kconfig header saved to 'C:/Impulse/sim_dfu/build_pls/_sysbuild/autoconf.h'
    -- Adding overlay config from C:/Impulse/sim_dfu/tkos_net/debug.conf to net image
    -- Adding devicetree overlay from C:/Impulse/sim_dfu/tkos_net/nrf5340dk_nrf5340_cpunet.overlay
    -- 
       *****************************
       * Running CMake for mcuboot *
       *****************************
    
    Loading Zephyr default modules (Zephyr base).
    -- Application: C:/ncs/v2.9.0/bootloader/mcuboot/boot/zephyr
    -- CMake version: 3.21.0
    -- Found Python3: C:/ncs/toolchains/b620d30767/opt/bin/python.exe (found suitable version "3.12.4", minimum required is "3.8") found components: Interpreter 
    -- Cache files will be written to: C:/ncs/v2.9.0/zephyr/.cache
    -- Zephyr version: 3.7.99 (C:/ncs/v2.9.0/zephyr)
    -- Found west (found suitable version "1.2.0", minimum required is "0.14.0")
    -- Board: nrf5340dk, qualifiers: nrf5340/cpuapp
    -- Found host-tools: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found toolchain: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found Dtc: C:/ncs/toolchains/b620d30767/opt/bin/dtc.exe (found suitable version "1.4.7", minimum required is "1.4.6") 
    -- Found BOARD.dts: C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpuapp.dts
    -- Found devicetree overlay: C:/Impulse/sim_dfu/sysbuild/mcuboot.overlay
    -- Generated zephyr.dts: C:/Impulse/sim_dfu/build_pls/mcuboot/zephyr/zephyr.dts
    -- Generated devicetree_generated.h: C:/Impulse/sim_dfu/build_pls/mcuboot/zephyr/include/generated/zephyr/devicetree_generated.h
    -- Including generated dts.cmake file: C:/Impulse/sim_dfu/build_pls/mcuboot/zephyr/dts.cmake
    Parsing C:/ncs/v2.9.0/bootloader/mcuboot/boot/zephyr/Kconfig
    Loaded configuration 'C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpuapp_defconfig'
    Merged configuration 'C:/ncs/v2.9.0/bootloader/mcuboot/boot/zephyr/prj.conf'
    Merged configuration 'C:/Impulse/sim_dfu/sysbuild/mcuboot.conf'
    Merged configuration 'C:/ncs/v2.9.0/nrf/modules/mcuboot/tfm.conf'
    Merged configuration 'C:/ncs/v2.9.0/nrf/modules/mcuboot/fih_low_enable.conf'
    Merged configuration 'C:/ncs/v2.9.0/nrf/subsys/partition_manager/ext_flash_mcuboot_secondary.conf'
    Merged configuration 'C:/Impulse/sim_dfu/build_pls/mcuboot/zephyr/.config.sysbuild'
    Configuration saved to 'C:/Impulse/sim_dfu/build_pls/mcuboot/zephyr/.config'
    Kconfig header saved to 'C:/Impulse/sim_dfu/build_pls/mcuboot/zephyr/include/generated/zephyr/autoconf.h'
    -- Found GnuLd: c:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/arm-zephyr-eabi/bin/ld.bfd.exe (found version "2.38") 
    -- The C compiler identification is GNU 12.2.0
    -- The CXX compiler identification is GNU 12.2.0
    -- The ASM compiler identification is GNU
    -- Found assembler: C:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc.exe
    -- Setting build type to 'MinSizeRel' as none was specified.
    MCUBoot bootloader key file: C:/ncs/v2.9.0/bootloader/mcuboot/root-rsa-2048.pem
    -- Configuring done
    -- Generating done
    -- Build files have been written to: C:/Impulse/sim_dfu/build_pls/mcuboot
    -- 
       *************************
       * Running CMake for b0n *
       *************************
    
    Loading Zephyr default modules (Zephyr base).
    -- Application: C:/ncs/v2.9.0/nrf/samples/nrf5340/netboot
    -- CMake version: 3.21.0
    -- Found Python3: C:/ncs/toolchains/b620d30767/opt/bin/python.exe (found suitable version "3.12.4", minimum required is "3.8") found components: Interpreter 
    -- Cache files will be written to: C:/ncs/v2.9.0/zephyr/.cache
    -- Zephyr version: 3.7.99 (C:/ncs/v2.9.0/zephyr)
    -- Found west (found suitable version "1.2.0", minimum required is "0.14.0")
    -- Board: nrf5340dk, qualifiers: nrf5340/cpunet
    -- Found host-tools: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found toolchain: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found Dtc: C:/ncs/toolchains/b620d30767/opt/bin/dtc.exe (found suitable version "1.4.7", minimum required is "1.4.6") 
    -- Found BOARD.dts: C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpunet.dts
    -- Generated zephyr.dts: C:/Impulse/sim_dfu/build_pls/b0n/zephyr/zephyr.dts
    -- Generated devicetree_generated.h: C:/Impulse/sim_dfu/build_pls/b0n/zephyr/include/generated/zephyr/devicetree_generated.h
    -- Including generated dts.cmake file: C:/Impulse/sim_dfu/build_pls/b0n/zephyr/dts.cmake
    Parsing C:/ncs/v2.9.0/nrf/samples/nrf5340/netboot/Kconfig
    Loaded configuration 'C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpunet_defconfig'
    Merged configuration 'C:/ncs/v2.9.0/nrf/samples/nrf5340/netboot/prj.conf'
    Merged configuration 'C:/Impulse/sim_dfu/build_pls/b0n/zephyr/.config.sysbuild'
    Configuration saved to 'C:/Impulse/sim_dfu/build_pls/b0n/zephyr/.config'
    Kconfig header saved to 'C:/Impulse/sim_dfu/build_pls/b0n/zephyr/include/generated/zephyr/autoconf.h'
    -- Found GnuLd: c:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/arm-zephyr-eabi/bin/ld.bfd.exe (found version "2.38") 
    -- The C compiler identification is GNU 12.2.0
    -- The CXX compiler identification is GNU 12.2.0
    -- The ASM compiler identification is GNU
    -- Found assembler: C:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc.exe
    -- Setting build type to 'MinSizeRel' as none was specified.
    CMake Warning at C:/ncs/v2.9.0/zephyr/CMakeLists.txt:2133 (message):
      __ASSERT() statements are globally ENABLED
    
    
    -- Configuring done
    -- Generating done
    -- Build files have been written to: C:/Impulse/sim_dfu/build_pls/b0n
    -- 
       ******************************
       * Running CMake for tkos_net *
       ******************************
    
    Loading Zephyr default modules (Zephyr base).
    -- Application: C:/Impulse/sim_dfu/tkos_net
    -- CMake version: 3.21.0
    -- Found Python3: C:/ncs/toolchains/b620d30767/opt/bin/python.exe (found suitable version "3.12.4", minimum required is "3.8") found components: Interpreter 
    -- Cache files will be written to: C:/ncs/v2.9.0/zephyr/.cache
    -- Zephyr version: 3.7.99 (C:/ncs/v2.9.0/zephyr)
    -- Found west (found suitable version "1.2.0", minimum required is "0.14.0")
    -- Board: nrf5340dk, qualifiers: nrf5340/cpunet
    -- Found host-tools: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found toolchain: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found Dtc: C:/ncs/toolchains/b620d30767/opt/bin/dtc.exe (found suitable version "1.4.7", minimum required is "1.4.6") 
    -- Found BOARD.dts: C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpunet.dts
    -- Found devicetree overlay: C:/Impulse/sim_dfu/tkos_net/nrf5340dk_nrf5340_cpunet.overlay
    -- Found devicetree overlay: C:/Impulse/sim_dfu/tkos_net/nrf5340dk_nrf5340_cpunet.overlay
    -- Generated zephyr.dts: C:/Impulse/sim_dfu/build_pls/tkos_net/zephyr/zephyr.dts
    -- Generated devicetree_generated.h: C:/Impulse/sim_dfu/build_pls/tkos_net/zephyr/include/generated/zephyr/devicetree_generated.h
    -- Including generated dts.cmake file: C:/Impulse/sim_dfu/build_pls/tkos_net/zephyr/dts.cmake
    Parsing C:/Impulse/sim_dfu/tkos_net/Kconfig
    Loaded configuration 'C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpunet_defconfig'
    Merged configuration 'C:/Impulse/sim_dfu/tkos_net/prj.conf'
    Merged configuration 'C:/Impulse/sim_dfu/tkos_net/debug_overlay.conf'
    Merged configuration 'C:/Impulse/sim_dfu/build_pls/tkos_net/zephyr/.config.sysbuild'
    Configuration saved to 'C:/Impulse/sim_dfu/build_pls/tkos_net/zephyr/.config'
    Kconfig header saved to 'C:/Impulse/sim_dfu/build_pls/tkos_net/zephyr/include/generated/zephyr/autoconf.h'
    -- Found GnuLd: c:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/arm-zephyr-eabi/bin/ld.bfd.exe (found version "2.38") 
    -- The C compiler identification is GNU 12.2.0
    -- The CXX compiler identification is GNU 12.2.0
    -- The ASM compiler identification is GNU
    -- Found assembler: C:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc.exe
    -- libmetal version: 1.6.0 (C:/Impulse/sim_dfu/tkos_net)
    -- Build type:  
    -- Host:    Windows/AMD64
    -- Target:  Generic/arm
    -- Machine: arm
    -- Looking for include file stdatomic.h
    -- Looking for include file stdatomic.h - found
    -- open-amp version: 1.6.1 (C:/ncs/v2.9.0/modules/lib/open-amp/open-amp)
    -- Host:    Windows/AMD64
    -- Target:  Generic/arm
    -- Machine: arm
    -- C_FLAGS :  -Wall -Wextra
    -- Looking for include file fcntl.h
    -- Looking for include file fcntl.h - found
    -- Setting build type to 'MinSizeRel' as none was specified.
    -- Configuring done
    -- Generating done
    -- Build files have been written to: C:/Impulse/sim_dfu/build_pls/tkos_net
    -- 
       *****************************
       * Running CMake for sim_dfu *
       *****************************
    
    CMake Warning at CMakeLists.txt:4 (message):
      Zephyr base: c:\ncs\v2.9.0\zephyr
    
    
    Loading Zephyr default modules (Zephyr base).
    -- Application: C:/Impulse/sim_dfu
    -- CMake version: 3.21.0
    -- Found Python3: C:/ncs/toolchains/b620d30767/opt/bin/python.exe (found suitable version "3.12.4", minimum required is "3.8") found components: Interpreter 
    -- Cache files will be written to: C:/ncs/v2.9.0/zephyr/.cache
    -- Zephyr version: 3.7.99 (C:/ncs/v2.9.0/zephyr)
    -- Found west (found suitable version "1.2.0", minimum required is "0.14.0")
    -- Board: nrf5340dk, qualifiers: nrf5340/cpuapp/ns
    -- Found host-tools: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found toolchain: zephyr 0.17.0 (C:/ncs/toolchains/b620d30767/opt/zephyr-sdk)
    -- Found Dtc: C:/ncs/toolchains/b620d30767/opt/bin/dtc.exe (found suitable version "1.4.7", minimum required is "1.4.6") 
    -- Found BOARD.dts: C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpuapp_ns.dts
    -- Found devicetree overlay: boards/nrf5340dk_nrf5340_cpuapp_ns.overlay
    -- Generated zephyr.dts: C:/Impulse/sim_dfu/build_pls/sim_dfu/zephyr/zephyr.dts
    -- Generated devicetree_generated.h: C:/Impulse/sim_dfu/build_pls/sim_dfu/zephyr/include/generated/zephyr/devicetree_generated.h
    -- Including generated dts.cmake file: C:/Impulse/sim_dfu/build_pls/sim_dfu/zephyr/dts.cmake
    
    warning: PM_EXTERNAL_FLASH_MCUBOOT_SECONDARY (defined at
    C:/ncs/v2.9.0/nrf\subsys\partition_manager/Kconfig:214) was assigned the value 'y' but got the value
    'n'. Check these unsatisfied dependencies: (PM_EXTERNAL_FLASH_ENABLED || MCUBOOT) (=n). See
    http://docs.zephyrproject.org/latest/kconfig.html#CONFIG_PM_EXTERNAL_FLASH_MCUBOOT_SECONDARY and/or
    look up PM_EXTERNAL_FLASH_MCUBOOT_SECONDARY in the menuconfig/guiconfig interface. The Application
    Development Primer, Setting Configuration Values, and Kconfig - Tips and Best Practices sections of
    the manual might be helpful too.
    
    Parsing C:/ncs/v2.9.0/zephyr/Kconfig
    Loaded configuration 'C:/ncs/v2.9.0/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpuapp_ns_defconfig'
    Merged configuration 'c:/Impulse/sim_dfu/prj.conf'
    Merged configuration 'C:/Impulse/sim_dfu/build_pls/sim_dfu/zephyr/.config.sysbuild'
    Configuration saved to 'C:/Impulse/sim_dfu/build_pls/sim_dfu/zephyr/.config'
    Kconfig header saved to 'C:/Impulse/sim_dfu/build_pls/sim_dfu/zephyr/include/generated/zephyr/autoconf.h'
    -- Found GnuLd: c:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/arm-zephyr-eabi/bin/ld.bfd.exe (found version "2.38") 
    -- The C compiler identification is GNU 12.2.0
    -- The CXX compiler identification is GNU 12.2.0
    -- The ASM compiler identification is GNU
    -- Found assembler: C:/ncs/toolchains/b620d30767/opt/zephyr-sdk/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc.exe
    CMake Warning at C:/ncs/v2.9.0/nrf/samples/common/mcumgr_bt_ota_dfu/CMakeLists.txt:27 (message):
      MCUmgr Bluetooth OTA DFU: suboptimal configuration of Bluetooth Host
      buffers.  Consider using optimal values defined in the
      C:/ncs/v2.9.0/nrf/samples/common/mcumgr_bt_ota_dfu/Kconfig file for
      CONFIG_BT_BUF_ACL_TX_SIZE, CONFIG_BT_BUF_ACL_RX_SIZE and
      CONFIG_BT_L2CAP_TX_MTU options
    
    
    =========== Generating psa_crypto_config ===============
    Backup: CONFIG_MBEDTLS_PSA_CRYPTO_SPM: False
    Backup: CONFIG_MBEDTLS_PSA_CRYPTO_C: False
    Backup: CONFIG_MBEDTLS_PSA_CRYPTO_KEY_ID_ENCODES_OWNER: False
    Backup: CONFIG_MBEDTLS_PLATFORM_SETUP_TEARDOWN_ALT: False
    Backup: CONFIG_MBEDTLS_THREADING: False
    Backup: CONFIG_MBEDTLS_THREADING_ALT: False
    =========== Checkpoint: backup ===============
    Restore: CONFIG_MBEDTLS_PSA_CRYPTO_SPM: False
    Restore: CONFIG_MBEDTLS_PSA_CRYPTO_C: False
    Restore: CONFIG_MBEDTLS_PSA_CRYPTO_KEY_ID_ENCODES_OWNER: False
    Restore: CONFIG_MBEDTLS_PLATFORM_SETUP_TEARDOWN_ALT: False
    Restore: CONFIG_MBEDTLS_THREADING: False
    Restore: CONFIG_MBEDTLS_THREADING_ALT: False
    =========== End psa_crypto_config ===============
    =========== Generating psa_crypto_library_config ===============
    Backup: CONFIG_MBEDTLS_PSA_CRYPTO_C: False
    Backup: CONFIG_MBEDTLS_PSA_CRYPTO_KEY_ID_ENCODES_OWNER: False
    Backup: CONFIG_MBEDTLS_PSA_CRYPTO_SPM: False
    Backup: CONFIG_MBEDTLS_USE_PSA_CRYPTO: True
    Backup: CONFIG_MBEDTLS_PLATFORM_PRINTF_ALT: False
    Backup: CONFIG_MBEDTLS_THREADING: False
    Backup: CONFIG_MBEDTLS_THREADING_ALT: False
    =========== Checkpoint: backup ===============
    Restore: CONFIG_MBEDTLS_PSA_CRYPTO_C: False
    Restore: CONFIG_MBEDTLS_PSA_CRYPTO_KEY_ID_ENCODES_OWNER: False
    Restore: CONFIG_MBEDTLS_PSA_CRYPTO_SPM: False
    Restore: CONFIG_MBEDTLS_USE_PSA_CRYPTO: True
    Restore: CONFIG_MBEDTLS_PLATFORM_PRINTF_ALT: False
    Restore: CONFIG_MBEDTLS_THREADING: False
    Restore: CONFIG_MBEDTLS_THREADING_ALT: False
    =========== End psa_crypto_library_config ===============
    -- libmetal version: 1.6.0 (C:/Impulse/sim_dfu)
    -- Build type:  
    -- Host:    Windows/AMD64
    -- Target:  Generic/arm
    -- Machine: arm
    -- Looking for include file stdatomic.h
    -- Looking for include file stdatomic.h - found
    -- open-amp version: 1.6.1 (C:/ncs/v2.9.0/modules/lib/open-amp/open-amp)
    -- Host:    Windows/AMD64
    -- Target:  Generic/arm
    -- Machine: arm
    -- C_FLAGS :  -Wall -Wextra
    -- Looking for include file fcntl.h
    -- Looking for include file fcntl.h - found
    -- Setting build type to 'MinSizeRel' as none was specified.
    -- Including signing script: C:/ncs/v2.9.0/nrf/cmake/sysbuild/image_signing.cmake
    -- Configuring done
    -- Generating done
    -- Build files have been written to: C:/Impulse/sim_dfu/build_pls/sim_dfu
    CMake Warning at C:/ncs/v2.9.0/nrf/cmake/sysbuild/debug_keys.cmake:21 (message):
      
    
          --------------------------------------------------------------
          --- WARNING: Using generated NSIB public/private key-pair. ---
          --- It should not be used for production.                  ---
          --- See SB_CONFIG_SECURE_BOOT_SIGNING_KEY_FILE             ---
          --------------------------------------------------------------
          
    
    Call Stack (most recent call first):
      C:/ncs/v2.9.0/nrf/cmake/sysbuild/provision_hex.cmake:11 (include)
      C:/ncs/v2.9.0/nrf/sysbuild/CMakeLists.txt:55 (include)
      C:/ncs/v2.9.0/nrf/sysbuild/CMakeLists.txt:667 (include_provision_hex)
      cmake/modules/sysbuild_extensions.cmake:583 (nrf_POST_CMAKE)
      cmake/modules/sysbuild_extensions.cmake:583 (cmake_language)
      cmake/modules/sysbuild_images.cmake:23 (sysbuild_module_call)
      cmake/modules/sysbuild_default.cmake:20 (include)
      C:/ncs/v2.9.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:75 (include)
      C:/ncs/v2.9.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:92 (include_boilerplate)
      C:/ncs/v2.9.0/zephyr/share/sysbuild-package/cmake/SysbuildConfig.cmake:8 (include)
      template/CMakeLists.txt:10 (find_package)
    
    
    CMake Warning at C:/ncs/v2.9.0/nrf/cmake/sysbuild/partition_manager.cmake:106 (message):
      
    
            ---------------------------------------------------------------------
            --- WARNING: Using a bootloader without pm_static.yml.            ---
            --- There are cases where a deployed product can consist of       ---
            --- multiple images, and only a subset of these images can be     ---
            --- upgraded through a firmware update mechanism. In such cases,  ---
            --- the upgradable images must have partitions that are static    ---
            --- and are matching the partition map used by the bootloader     ---
            --- programmed onto the device.                                   ---
            ---------------------------------------------------------------------
            
    
    Call Stack (most recent call first):
      C:/ncs/v2.9.0/nrf/cmake/sysbuild/partition_manager.cmake:634 (partition_manager)
      C:/ncs/v2.9.0/nrf/sysbuild/CMakeLists.txt:703 (include)
      cmake/modules/sysbuild_extensions.cmake:583 (nrf_POST_CMAKE)
      cmake/modules/sysbuild_extensions.cmake:583 (cmake_language)
      cmake/modules/sysbuild_images.cmake:23 (sysbuild_module_call)
      cmake/modules/sysbuild_default.cmake:20 (include)
      C:/ncs/v2.9.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:75 (include)
      C:/ncs/v2.9.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:92 (include_boilerplate)
      C:/ncs/v2.9.0/zephyr/share/sysbuild-package/cmake/SysbuildConfig.cmake:8 (include)
      template/CMakeLists.txt:10 (find_package)
    
    
    Traceback (most recent call last):
      File "C:\ncs\v2.9.0\nrf\scripts\partition_manager.py", line 2045, in <module>
        main()
      File "C:\ncs\v2.9.0\nrf\scripts\partition_manager.py", line 1023, in main
        pm_config = load_reqs(args.input_files)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "C:\ncs\v2.9.0\nrf\scripts\partition_manager.py", line 689, in load_reqs
        raise PartitionError(
    PartitionError: Conflicting configuration found for 'C:/Impulse/sim_dfu/build_pls/mcuboot/modules/nrf/subsys/partition_manager/pm.yml.rpmsg_nrf53' value for key 'rpmsg_nrf53_sram' differs. val1: {'placement': {'before': 'end'}, 'size': 65536, 'region': 'sram_primary'} val2: {'placement': {'before': 'end'}, 'size': 63424, 'region': 'sram_primary'} 
    CMake Error at C:/ncs/v2.9.0/nrf/cmake/sysbuild/partition_manager.cmake:167 (message):
      Partition Manager failed, aborting.  Command:
      C:/ncs/toolchains/b620d30767/opt/bin/python.exe;C:/ncs/v2.9.0/nrf/scripts/partition_manager.py;--input-files;C:/Impulse/sim_dfu/build_pls/sim_dfu/modules/nrf/subsys/partition_manager/pm.yml.rpmsg_nrf53;C:/Impulse/sim_dfu/build_pls/sim_dfu/modules/nrf/subsys/partition_manager/pm.yml.tfm;C:/Impulse/sim_dfu/build_pls/sim_dfu/modules/nrf/subsys/partition_manager/pm.yml.trustzone;C:/Impulse/sim_dfu/build_pls/sim_dfu/modules/nrf/subsys/partition_manager/pm.yml.mcuboot;C:/Impulse/sim_dfu/build_pls/mcuboot/zephyr/include/generated/pm.yml;C:/Impulse/sim_dfu/build_pls/mcuboot/modules/nrf/subsys/partition_manager/pm.yml.rpmsg_nrf53;C:/Impulse/sim_dfu/build_pls/sim_dfu/zephyr/include/generated/pm.yml;--regions;sram_primary;otp;flash_primary;--output-partitions;C:/Impulse/sim_dfu/build_pls/partitions.yml;--output-regions;C:/Impulse/sim_dfu/build_pls/regions.yml;--sram_primary-size;0x80000;--sram_primary-base-address;0x20000000;--sram_primary-placement-strategy;complex;--sram_primary-dynamic-partition;sram_primary;--otp-size;764;--otp-base-address;0xff8100;--otp-placement-strategy;start_to_end;--flash_primary-size;0x100000;--flash_primary-base-address;0x0;--flash_primary-placement-strategy;complex;--flash_primary-device;flash_controller;--flash_primary-default-driver-kconfig;CONFIG_SOC_FLASH_NRF
    Call Stack (most recent call first):
      C:/ncs/v2.9.0/nrf/cmake/sysbuild/partition_manager.cmake:634 (partition_manager)
      C:/ncs/v2.9.0/nrf/sysbuild/CMakeLists.txt:703 (include)
      cmake/modules/sysbuild_extensions.cmake:583 (nrf_POST_CMAKE)
      cmake/modules/sysbuild_extensions.cmake:583 (cmake_language)
      cmake/modules/sysbuild_images.cmake:23 (sysbuild_module_call)
      cmake/modules/sysbuild_default.cmake:20 (include)
      C:/ncs/v2.9.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:75 (include)
      C:/ncs/v2.9.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:92 (include_boilerplate)
      C:/ncs/v2.9.0/zephyr/share/sysbuild-package/cmake/SysbuildConfig.cmake:8 (include)
      template/CMakeLists.txt:10 (find_package)
    
    
    -- Configuring incomplete, errors occurred!
    See also "C:/Impulse/sim_dfu/build_pls/CMakeFiles/CMakeOutput.log".
    FATAL ERROR: command exited with status 1: 'C:\ncs\toolchains\b620d30767\opt\bin\cmake.EXE' -DWEST_PYTHON=C:/ncs/toolchains/b620d30767/opt/bin/python.exe '-Bc:\Impulse\sim_dfu\build_pls' -GNinja -DBOARD=nrf5340dk/nrf5340/cpuapp/ns -DNCS_TOOLCHAIN_VERSION=NONE -DCONF_FILE=c:/Impulse/sim_dfu/prj.conf -DDTC_OVERLAY_FILE=boards/nrf5340dk_nrf5340_cpuapp_ns.overlay '-DBOARD_ROOT=c:\Impulse\sim_dfu' '-SC:\ncs\v2.9.0\zephyr\share\sysbuild' '-DAPP_DIR:PATH=c:\Impulse\sim_dfu'
    
     *  The terminal process terminated with exit code: 1. 
     *  Terminal will be reused by tasks, press any key to close it. 


    This is clearly because my current cmake sysbuild config doesn't enable the network core config "NETCORE_NONE" = n and its not clear how I'm supposed to do that. Obviously by using your prebuilt ipc image that config is getting set but I'm not sure how. 

    Here is the updated code if you prefer a zip instead of github:
    3630.sim_dfu.zip

Children
No Data
Related