<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/125942/combining-dtm-and-dfu-next-samples</link><description>I am trying to get the nrf/sampoles/bluetooth/direct_test_mode working together with the code from zephyr/samples/subsys/usb/dfu-next. 
 
 I have the DTM mode running correctly, but can&amp;#39;t integrate the dfu mode to this sample. 
 I started with the dtm</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 05 Jan 2026 13:29:49 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/125942/combining-dtm-and-dfu-next-samples" /><item><title>RE: Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/thread/557927?ContentTypeID=1</link><pubDate>Mon, 05 Jan 2026 13:29:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0ae28cd9-9e7d-475e-87f4-cf984da642bb</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Try adding a pm_static.yml to your project, and see if that helps.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/thread/557293?ContentTypeID=1</link><pubDate>Thu, 18 Dec 2025 07:55:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:44a5b019-ac07-4512-bb77-d36a89f1382e</guid><dc:creator>simeg</dc:creator><description>&lt;p&gt;Hi Edvin,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I got a step further by trying a different approach:&amp;nbsp;&lt;br /&gt;instead of starting from the DTM sample I took the Remote IPC shell as a starting point and grafted the direct test mode on to it.&amp;nbsp;&lt;br /&gt;I named the resulting project &amp;quot;dtm_remote_shell&amp;quot;.&lt;br /&gt;This approach allowed me to compile the project and get DFU (app-core only) mode together with DTM.&amp;nbsp;&lt;br /&gt;However, for our scenario we will have to upgrade both app- and netcore together, and this led to the problem I am having now:&amp;nbsp;&lt;br /&gt;if I enable NETCORE_APP_UPDATE and the related configs, b0n shows up in the images, but I get following error:&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;   **************************************
   * Running CMake for dtm_remote_shell *
   **************************************

Loading Zephyr default modules (Zephyr base).
-- Application: /home/simeg/workspace/nrf-bluetooth/dtm_remote_shell
-- CMake version: 3.21.0
-- Found Python3: /home/simeg/ncs/toolchains/b2ecd2435d/usr/local/bin/python (found suitable version &amp;quot;3.12.4&amp;quot;, minimum required is &amp;quot;3.10&amp;quot;) found components: Interpreter 
-- Cache files will be written to: /home/simeg/.cache/zephyr
-- Zephyr version: 4.1.99 (/home/simeg/ncs/v3.1.1/zephyr)
-- Found west (found suitable version &amp;quot;1.4.0&amp;quot;, minimum required is &amp;quot;0.14.0&amp;quot;)
-- Board: nrf5340dk, qualifiers: nrf5340/cpuapp
-- Found host-tools: zephyr 0.17.0 (/home/simeg/ncs/toolchains/b2ecd2435d/opt/zephyr-sdk)
-- Found toolchain: zephyr 0.17.0 (/home/simeg/ncs/toolchains/b2ecd2435d/opt/zephyr-sdk)
-- Found Dtc: /home/simeg/ncs/toolchains/b2ecd2435d/usr/bin/dtc (found suitable version &amp;quot;1.5.0&amp;quot;, minimum required is &amp;quot;1.4.6&amp;quot;) 
-- Found BOARD.dts: /home/simeg/ncs/v3.1.1/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpuapp.dts
-- Found devicetree overlay: /home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/boards/nrf5340dk_nrf5340_cpuapp.overlay
-- Generated zephyr.dts: /home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/dtm_remote_shell/zephyr/zephyr.dts
-- Generated pickled edt: /home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/dtm_remote_shell/zephyr/edt.pickle
-- Generated devicetree_generated.h: /home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/dtm_remote_shell/zephyr/include/generated/zephyr/devicetree_generated.h

warning: STDOUT_CONSOLE (defined at lib/libc/Kconfig:156) was assigned the value &amp;#39;y&amp;#39; but got the
value &amp;#39;n&amp;#39;. Check these unsatisfied dependencies: CONSOLE_HAS_DRIVER (=n). See
http://docs.zephyrproject.org/latest/kconfig.html#CONFIG_STDOUT_CONSOLE and/or look up
STDOUT_CONSOLE 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: LOG_BACKEND_UART (defined at subsys/logging/backends/Kconfig.uart:4) was assigned the value
&amp;#39;y&amp;#39; but got the value &amp;#39;n&amp;#39;. Check these unsatisfied dependencies: UART_CONSOLE (=n). See
http://docs.zephyrproject.org/latest/kconfig.html#CONFIG_LOG_BACKEND_UART and/or look up
LOG_BACKEND_UART 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: The choice symbol USB_DRIVER_LOG_LEVEL_ERR (defined at
subsys/logging/Kconfig.template.log_config:11) was selected (set =y), but no symbol ended up as the
choice selection. See
http://docs.zephyrproject.org/latest/kconfig.html#CONFIG_USB_DRIVER_LOG_LEVEL_ERR and/or look up
USB_DRIVER_LOG_LEVEL_ERR 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: The choice symbol USB_DEVICE_LOG_LEVEL_ERR (defined at
subsys/logging/Kconfig.template.log_config:11) was selected (set =y), but no symbol ended up as the
choice selection. See
http://docs.zephyrproject.org/latest/kconfig.html#CONFIG_USB_DEVICE_LOG_LEVEL_ERR and/or look up
USB_DEVICE_LOG_LEVEL_ERR 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: Experimental symbol UDC_DRIVER is enabled.


warning: Experimental symbol USB_DEVICE_STACK_NEXT is enabled.

Parsing /home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/Kconfig
Loaded configuration &amp;#39;/home/simeg/ncs/v3.1.1/zephyr/boards/nordic/nrf5340dk/nrf5340dk_nrf5340_cpuapp_defconfig&amp;#39;
Merged configuration &amp;#39;/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/prj.conf&amp;#39;
Merged configuration &amp;#39;/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/dtm_remote_shell/zephyr/.config.sysbuild&amp;#39;
Configuration saved to &amp;#39;/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/dtm_remote_shell/zephyr/.config&amp;#39;
Kconfig header saved to &amp;#39;/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/dtm_remote_shell/zephyr/include/generated/zephyr/autoconf.h&amp;#39;
-- Found GnuLd: /home/simeg/ncs/toolchains/b2ecd2435d/opt/zephyr-sdk/arm-zephyr-eabi/arm-zephyr-eabi/bin/ld.bfd (found version &amp;quot;2.38&amp;quot;) 
-- 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: /home/simeg/ncs/toolchains/b2ecd2435d/opt/zephyr-sdk/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc
-- libmetal version: 1.7.0 (/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell)
-- Build type:  
-- Host:    Linux/x86_64
-- Target:  Generic/arm
-- Machine: arm
-- Vendor: none
-- Looking for include file stdatomic.h
-- Looking for include file stdatomic.h - found
-- open-amp version: 1.7.0 (/home/simeg/ncs/v3.1.1/modules/lib/open-amp/open-amp)
-- Host:    Linux/x86_64
-- Target:  Generic/arm
-- Machine: arm
-- C_FLAGS :  -Wall -Wextra
-- Looking for include file fcntl.h
-- Looking for include file fcntl.h - found
-- Using ccache: /home/simeg/ncs/toolchains/b2ecd2435d/usr/bin/ccache
-- Found gen_kobject_list: /home/simeg/ncs/v3.1.1/zephyr/scripts/build/gen_kobject_list.py
CMake Warning at /home/simeg/ncs/v3.1.1/zephyr/CMakeLists.txt:1027 (message):
  No SOURCES given to Zephyr library: drivers__disk

  Excluding target from build.


-- Including signing script: /home/simeg/ncs/v3.1.1/nrf/cmake/sysbuild/image_signing.cmake
-- Configuring done
-- Generating done
-- Build files have been written to: /home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/dtm_remote_shell
CMake Warning at /home/simeg/ncs/v3.1.1/nrf/cmake/sysbuild/debug_keys.cmake:27 (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):
  /home/simeg/ncs/v3.1.1/nrf/cmake/sysbuild/provision_hex.cmake:11 (include)
  /home/simeg/ncs/v3.1.1/nrf/sysbuild/CMakeLists.txt:55 (include)
  /home/simeg/ncs/v3.1.1/nrf/sysbuild/CMakeLists.txt:777 (include_provision_hex)
  cmake/modules/sysbuild_extensions.cmake:598 (nrf_POST_CMAKE)
  cmake/modules/sysbuild_extensions.cmake:598 (cmake_language)
  cmake/modules/sysbuild_images.cmake:46 (sysbuild_module_call)
  cmake/modules/sysbuild_default.cmake:21 (include)
  /home/simeg/ncs/v3.1.1/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:75 (include)
  /home/simeg/ncs/v3.1.1/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:92 (include_boilerplate)
  /home/simeg/ncs/v3.1.1/zephyr/share/sysbuild-package/cmake/SysbuildConfig.cmake:8 (include)
  template/CMakeLists.txt:10 (find_package)


CMake Warning at /home/simeg/ncs/v3.1.1/nrf/cmake/sysbuild/partition_manager.cmake:119 (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):
  /home/simeg/ncs/v3.1.1/nrf/cmake/sysbuild/partition_manager.cmake:636 (partition_manager)
  /home/simeg/ncs/v3.1.1/nrf/sysbuild/CMakeLists.txt:825 (include)
  cmake/modules/sysbuild_extensions.cmake:598 (nrf_POST_CMAKE)
  cmake/modules/sysbuild_extensions.cmake:598 (cmake_language)
  cmake/modules/sysbuild_images.cmake:46 (sysbuild_module_call)
  cmake/modules/sysbuild_default.cmake:21 (include)
  /home/simeg/ncs/v3.1.1/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:75 (include)
  /home/simeg/ncs/v3.1.1/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:92 (include_boilerplate)
  /home/simeg/ncs/v3.1.1/zephyr/share/sysbuild-package/cmake/SysbuildConfig.cmake:8 (include)
  template/CMakeLists.txt:10 (find_package)


Traceback (most recent call last):
  File &amp;quot;/home/simeg/ncs/v3.1.1/nrf/scripts/partition_manager.py&amp;quot;, line 1054, in &amp;lt;module&amp;gt;
    main()
  File &amp;quot;/home/simeg/ncs/v3.1.1/nrf/scripts/partition_manager.py&amp;quot;, line 1022, in main
    args, ranges_configuration = parse_args()
                                 ^^^^^^^^^^^^
  File &amp;quot;/home/simeg/ncs/v3.1.1/nrf/scripts/partition_manager.py&amp;quot;, line 928, in parse_args
    parser.add_argument(f&amp;#39;--{x}-size&amp;#39;, required=True, type=lambda z: int(z, 0))
  File &amp;quot;/home/simeg/ncs/toolchains/b2ecd2435d/usr/local/lib/python3.12/argparse.py&amp;quot;, line 1495, in add_argument
    return self._add_action(action)
           ^^^^^^^^^^^^^^^^^^^^^^^^
  File &amp;quot;/home/simeg/ncs/toolchains/b2ecd2435d/usr/local/lib/python3.12/argparse.py&amp;quot;, line 1877, in _add_action
    self._optionals._add_action(action)
  File &amp;quot;/home/simeg/ncs/toolchains/b2ecd2435d/usr/local/lib/python3.12/argparse.py&amp;quot;, line 1697, in _add_action
    action = super(_ArgumentGroup, self)._add_action(action)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File &amp;quot;/home/simeg/ncs/toolchains/b2ecd2435d/usr/local/lib/python3.12/argparse.py&amp;quot;, line 1509, in _add_action
    self._check_conflict(action)
  File &amp;quot;/home/simeg/ncs/toolchains/b2ecd2435d/usr/local/lib/python3.12/argparse.py&amp;quot;, line 1646, in _check_conflict
    conflict_handler(action, confl_optionals)
  File &amp;quot;/home/simeg/ncs/toolchains/b2ecd2435d/usr/local/lib/python3.12/argparse.py&amp;quot;, line 1655, in _handle_conflict_error
    raise ArgumentError(action, message % conflict_string)
argparse.ArgumentError: argument --sram_primary-size: conflicting option string: --sram_primary-size
CMake Error at /home/simeg/ncs/v3.1.1/nrf/cmake/sysbuild/partition_manager.cmake:179 (message):
  Partition Manager failed, aborting.  Command:
  /home/simeg/ncs/toolchains/b2ecd2435d/usr/local/bin/python3.12;/home/simeg/ncs/v3.1.1/nrf/scripts/partition_manager.py;--input-files;/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/b0n/zephyr/include/generated/pm.yml;/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/b0n/modules/nrf/subsys/partition_manager/pm.yml.secure_boot_storage;/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/zephyr/include/generated/pm.yml;/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/b0n/zephyr/include/generated/pm.yml;/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/b0n/modules/nrf/subsys/partition_manager/pm.yml.secure_boot_storage;/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/zephyr/include/generated/pm.yml;--regions;sram_primary;flash_primary;sram_primary;flash_primary;--output-partitions;/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/partitions_CPUNET.yml;--output-regions;/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/regions_CPUNET.yml;--flash_primary-dynamic-partition;direct_test_mode;--sram_primary-size;0x10000;--sram_primary-base-address;0x21000000;--sram_primary-placement-strategy;complex;--sram_primary-dynamic-partition;sram_primary;--flash_primary-size;0x40000;--flash_primary-base-address;0x1000000;--flash_primary-placement-strategy;complex;--flash_primary-device;flash_controller;--flash_primary-default-driver-kconfig;CONFIG_SOC_FLASH_NRF;--sram_primary-size;0x10000;--sram_primary-base-address;0x21000000;--sram_primary-placement-strategy;complex;--sram_primary-dynamic-partition;sram_primary;--flash_primary-size;0x40000;--flash_primary-base-address;0x1000000;--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):
  /home/simeg/ncs/v3.1.1/nrf/cmake/sysbuild/partition_manager.cmake:639 (partition_manager)
  /home/simeg/ncs/v3.1.1/nrf/sysbuild/CMakeLists.txt:825 (include)
  cmake/modules/sysbuild_extensions.cmake:598 (nrf_POST_CMAKE)
  cmake/modules/sysbuild_extensions.cmake:598 (cmake_language)
  cmake/modules/sysbuild_images.cmake:46 (sysbuild_module_call)
  cmake/modules/sysbuild_default.cmake:21 (include)
  /home/simeg/ncs/v3.1.1/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:75 (include)
  /home/simeg/ncs/v3.1.1/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:92 (include_boilerplate)
  /home/simeg/ncs/v3.1.1/zephyr/share/sysbuild-package/cmake/SysbuildConfig.cmake:8 (include)
  template/CMakeLists.txt:10 (find_package)


-- Configuring incomplete, errors occurred!
See also &amp;quot;/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1/CMakeFiles/CMakeOutput.log&amp;quot;.
FATAL ERROR: command exited with status 1: /home/simeg/ncs/toolchains/b2ecd2435d/usr/local/bin/cmake -DWEST_PYTHON=/home/simeg/ncs/toolchains/b2ecd2435d/usr/local/bin/python3.12 -B/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell/build_1 -GNinja -DBOARD=nrf5340dk/nrf5340/cpuapp -S/home/simeg/ncs/v3.1.1/zephyr/share/sysbuild -DAPP_DIR:PATH=/home/simeg/workspace/nrf-bluetooth/dtm_remote_shell

 *  The terminal process terminated with exit code: 1. 
 *  Terminal will be reused by tasks, press any key to close it. 
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;When I look at the build directory and search for the different sram-primary definitions it seems to lign up and also the indicated CMake command (from the build output) does not acually show any discrepancies.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;I seem close to have this project building in the desired state - mind to look in to it once more?&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/dtm_5F00_remote_5F00_shell.tar.gz"&gt;devzone.nordicsemi.com/.../dtm_5F00_remote_5F00_shell.tar.gz&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/thread/556483?ContentTypeID=1</link><pubDate>Mon, 08 Dec 2025 15:00:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4bbbc968-e364-4ce8-8cd6-6d3f7c262d94</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;The challenge here is that the direct test mode is running on the network core. You probably already flashed the app core with the empty_app_core sample, which basically starts up the network core and shuts down.&lt;/p&gt;
&lt;p&gt;You may actually want to look into modifying this into the empty app core. But if you want to be able to DFU back and forth between direct test mode, then you need a DFU image that contains the empty app core and the direct test mode for the network core. So much like the BLE samples would automatically build the IPC radio sample for the network core on the nRF5340, you would need your empty_app_core sample to automatically include the direct test mode for the network core, and then add DFU to your empty_app_core.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;To add USB DFU to an application, you can reference &lt;a href="https://academy.nordicsemi.com/courses/nrf-connect-sdk-intermediate/lessons/lesson-9-bootloaders-and-dfu-fota/topic/exercise-4-dfu-over-usb/"&gt;this DevAcademy course&lt;/a&gt;. Note that it says that if you want USB DFU from the application, you should go straight to step 5.&lt;/p&gt;
&lt;p&gt;The solution to the exercise is found here:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/NordicDeveloperAcademy/ncs-inter/tree/main/l9/l9_e4_sol"&gt;https://github.com/NordicDeveloperAcademy/ncs-inter/tree/main/l9/l9_e4_sol&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
[quote user="simeg"]&lt;p&gt;Here you see that nrf connect uses &amp;quot;main.c&amp;quot; from the &amp;quot;samples&amp;quot; directory, I would however like that this code would exist locally in our git repository and that west does use source code from other folders.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;[/quote]
&lt;p&gt;If I understand correctly, you want to maintain your application on github, and just make it point to the nRF Connect SDK for the rest of the files, right?&lt;/p&gt;
&lt;p&gt;That is possible. If you have nrfutil installed, you can use the command:&lt;/p&gt;
&lt;p&gt;nrfutil sdk-manager toolchain env --as-script --ncs-version v3.1.1&lt;/p&gt;
&lt;p&gt;Then copy the output into a file called e.g. ncs_v3_1_1.cmd&lt;/p&gt;
&lt;p&gt;Then add this line at the end:&lt;/p&gt;
&lt;p&gt;SET ZEPHYR_BASE=C:\nordic\SDKs\ncs\v3.1.1\zephyr&lt;/p&gt;
&lt;p&gt;(but with the path to your NCS&amp;#39;s zephyr folder)&lt;/p&gt;
&lt;p&gt;Then add this script to path, and you can call &amp;quot;ncs_v3_1_1.cmd&amp;quot; from anywhere, and you can use it to build. You can also place application folder&amp;#39;s outside the nRF Connect SDK and build it in VS Code.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/thread/556446?ContentTypeID=1</link><pubDate>Mon, 08 Dec 2025 12:23:21 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:08d989dd-1919-44de-87e9-1488d5b02ff6</guid><dc:creator>simeg</dc:creator><description>&lt;p&gt;Hi Edvin,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Thank you again for looking in to this . &lt;br /&gt;YES, the project - as is -&amp;nbsp; builds successfully.&amp;nbsp;&lt;br /&gt;This was however not the issue or the question I was trying to ask:&lt;br /&gt;the problem is how to get DTM and DFU working together.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;I am unclear how we can modify the DTM code to add USB-DFU functionality to it.&amp;nbsp;&lt;br /&gt;Also, how we can get west to use local sources, e.g. while building I get a warning:&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;57/242] Building C object CMakeFiles/app.dir/src/main.c.obj
/home/user/ncs/v3.1.1/nrf/samples/nrf5340/remote_shell/src/main.c: In function &amp;#39;main&amp;#39;:
/home/user/ncs/v3.1.1/nrf/samples/nrf5340/remote_shell/src/main.c:138:15: warning: implicit declaration of function &amp;#39;dfu_init&amp;#39; [-Wimplicit-function-declaration]
  138 |         err = dfu_init();
      |               ^~~~~~~~&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Here you see that nrf connect uses &amp;quot;main.c&amp;quot; from the &amp;quot;samples&amp;quot; directory, I would however like that this code would exist locally in our git repository and that west does use source code from other folders.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;---&lt;/p&gt;
&lt;p&gt;After flashing the project it shows up in the &amp;quot;dfu-util&amp;quot; utility:&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;user:~/workspace/nrf-bluetooth/direct_test_mode(user.dfu_and_dtm)$ sudo dfu-util -l
dfu-util 0.11

Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2021 Tormod Volden and Stefan Schmidt
This program is Free Software and has ABSOLUTELY NO WARRANTY
Please report bugs to http://sourceforge.net/p/dfu-util/tickets/

Found Runtime: [2fe3:0001] ver=0401, devnum=35, cfg=1, intf=2, path=&amp;quot;3-7.4.5&amp;quot;, alt=0, name=&amp;quot;UNKNOWN&amp;quot;, serial=&amp;quot;8924B12F028AA082&amp;quot;&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;However, the chip can not successfully be flashed:&amp;nbsp;&lt;br /&gt;&lt;pre class="ui-code" data-mode="text"&gt;user:~/workspace/nrf-bluetooth/direct_test_mode(user.dfu_and_dtm)$ sudo dfu-util --alt 0 --download build/direct_test_mode/zephyr/zephyr.signed.bin 
dfu-util 0.11

Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2021 Tormod Volden and Stefan Schmidt
This program is Free Software and has ABSOLUTELY NO WARRANTY
Please report bugs to http://sourceforge.net/p/dfu-util/tickets/

dfu-util: Warning: Invalid DFU suffix signature
dfu-util: A valid DFU suffix will be required in a future dfu-util release
Opening DFU capable USB device...
Device ID 2fe3:0001
Run-Time device DFU version 0110
Claiming USB DFU (Run-Time) Interface...
Setting Alternate Interface zero...
Determining device status...
DFU state(0) = appIDLE, status(0) = No error condition is present
Device really in Run-Time Mode, send DFU detach request...
Device will detach and reattach...
Opening DFU USB Device...
Claiming USB DFU Interface...
Setting Alternate Interface #0 ...
Determining device status...
DFU state(2) = dfuIDLE, status(0) = No error condition is present
DFU mode device DFU version 0110
Device returned transfer size 512
Copying data from PC to DFU device
Download        [                         ]   0%            0 bytesdfu-util: Error during download (LIBUSB_ERROR_PIPE)&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;It seems that the dfu functionality is not &amp;quot;present&amp;quot; once the device is detached.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Could you please assist us in getting DTM working together with DFU mode?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/thread/556432?ContentTypeID=1</link><pubDate>Mon, 08 Dec 2025 10:11:48 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:91c07d63-8fc0-4f16-8e00-7e4ac4fe6cc5</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Ok, just tried building the sample now, using NVS v3.1.1 (and toolchain 3.1.1), and it built without any errors.&lt;/p&gt;
&lt;p&gt;I used the command:&lt;/p&gt;
&lt;p&gt;west build -b ubx_evknorab10/nrf5340/cpunet -d build -- -DBOARD_ROOT=&amp;quot;../.&amp;quot;&lt;/p&gt;
&lt;p&gt;Can you try to update the toolchain to v3.1.1 as well?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/thread/556352?ContentTypeID=1</link><pubDate>Fri, 05 Dec 2025 14:54:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a29f1f06-c9de-476e-8f0a-2d459d70edb4</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;No worries. I didn&amp;#39;t get the time to look into these today, but I will try next week.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/thread/556255?ContentTypeID=1</link><pubDate>Thu, 04 Dec 2025 14:24:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a99d28e2-0c4f-4815-8be0-7be882c275d0</guid><dc:creator>simeg</dc:creator><description>&lt;p&gt;Ah, sorry - I missed the &amp;quot;common&amp;quot; directory.&amp;nbsp;&lt;br /&gt;It is however just some effort on my side to try to get all files that the project needs out of the SDK folder and in to the repository.&amp;nbsp;&lt;br /&gt;This came together, because I had problem described in this ticket and I tried to &amp;quot;copy&amp;quot; all files in to the repo, that the original direct_test_mode project needs.&lt;/p&gt;
&lt;p&gt;Please find attached the an archive with this common directory included.&lt;/p&gt;
&lt;p&gt;I am very sorry to have missed this the first round...&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/dtm_5F00_and_5F00_dfe_5F00_together_5F00_v2.tar.gz"&gt;devzone.nordicsemi.com/.../dtm_5F00_and_5F00_dfe_5F00_together_5F00_v2.tar.gz&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/thread/556251?ContentTypeID=1</link><pubDate>Thu, 04 Dec 2025 14:05:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ac3c7db8-9b11-45e2-94e8-f192c6ba3ab2</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;I see this:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;Parsing C:/nordic/SDKs/ncs/v3.1.1/nrf/samples/nrf5340/direct_test_mode/Kconfig.sysbuild
C:/nordic/SDKs/ncs/v3.1.1/zephyr/scripts/kconfig/kconfig.py: C:/nordic/SDKs/ncs/v3.1.1/nrf/samples/nrf5340/direct_test_mode/Kconfig.sysbuild:67: &amp;#39;C:/nordic/SDKs/ncs/v3.1.1/nrf/samples/nrf5340/direct_test_mode\../common/usb/Kconfig.sample_usbd&amp;#39; not found (in &amp;#39;rsource &amp;quot;../common/usb/Kconfig.sample_usbd&amp;quot;&amp;#39;)&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Outside the application folder, what &amp;quot;common&amp;quot; folder is it trying to point to? Where exactly do I need to place the direct_test_mode folder?&lt;/p&gt;
&lt;p&gt;You said you place it in the nrf\samples\nrf5340\remote_shell directory, but this does not have a &amp;quot;common&amp;quot; folder in it&amp;#39;s parent folder.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/thread/556214?ContentTypeID=1</link><pubDate>Thu, 04 Dec 2025 08:08:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:45204689-e99f-44a6-ad6a-ab9181ee75e9</guid><dc:creator>simeg</dc:creator><description>&lt;p&gt;Oh sorry, overlooked this:&amp;nbsp;&lt;br /&gt;SDK:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;nRF Connect SDK v3.1.1&lt;br /&gt;Toolchain:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;nRF Connect SDK Toolchain v3.1.0&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/thread/556212?ContentTypeID=1</link><pubDate>Thu, 04 Dec 2025 07:46:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:14cdd323-f005-49c8-a652-9c8db84008ed</guid><dc:creator>simeg</dc:creator><description>&lt;p&gt;Yes, exactly, the direct_test_mode is the project we are trying to build.&amp;nbsp;&lt;br /&gt;If I copy the sample_code in to the&amp;nbsp;nrf/samples/nrf5340/remote_shell directory, I actually get the DTM application to show up in dfu - alas only the Ramdisk.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;This is my west build command, as generated by VS Code nrf connect plugin:&amp;nbsp;&lt;br /&gt;&lt;pre class="ui-code" data-mode="text"&gt;west build --build-dir /home/user/workspace/nrf-bluetooth/direct_test_mode/build /home/user/workspace/nrf-bluetooth/direct_test_mode --pristine --board ubx_evknorab10/nrf5340/cpunet --sysbuild -- -DBOARD_ROOT=&amp;quot;/home/user/workspace/nrf-bluetooth&amp;quot;&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/thread/556211?ContentTypeID=1</link><pubDate>Thu, 04 Dec 2025 07:43:47 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1d522497-34cb-49ab-a5d1-1c8e96fa39e1</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;And what NCS version?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/thread/556209?ContentTypeID=1</link><pubDate>Thu, 04 Dec 2025 07:42:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:63bba98f-a12c-4707-bd8b-7b58608f495a</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Just to be clear, it is the direct_test_mode, and not the sample_code_remote_shell we are trying to build?&lt;/p&gt;
&lt;p&gt;What is your build command? &amp;quot;west build -b ubc_evknorab10_nrf5340/nrf5340/cpuapp&amp;quot; ? or some additional build flags?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/thread/556206?ContentTypeID=1</link><pubDate>Thu, 04 Dec 2025 07:07:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:386f59c8-6887-4158-8246-09aae30d8760</guid><dc:creator>simeg</dc:creator><description>&lt;p&gt;Hi Edvin,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;thank you for looking in to this.&amp;nbsp;&lt;br /&gt;The nrf5340 will be part of another product and enable new features for our users.&amp;nbsp;&lt;br /&gt;We want to have various apps that the user can cycle through on our products: the user will select an &amp;quot;app&amp;quot; and it will be pushed to the nrf5340 in the background via USB dfe from a linux host.&lt;br /&gt;The DTM mode will be one such application, which will only be available for a select view users (mainly internal testing, production chain, certification labs, etc.).&amp;nbsp;&lt;br /&gt;We have this workflow working for other applications, but the DTM applications does not yet work.&lt;/p&gt;
&lt;p&gt;We use the Ublox Nora B - I&amp;#39;ve included the boards directory for this board.&amp;nbsp;&lt;br /&gt;I&amp;#39;ve also included the modified sample code.&lt;br /&gt;Please do not hesitate to contact me, if you have any further questions.&amp;nbsp;&lt;br /&gt;If you send me a DM I can also give you my company contact informations.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/dtm_5F00_and_5F00_dfe_5F00_together.tar.gz"&gt;devzone.nordicsemi.com/.../dtm_5F00_and_5F00_dfe_5F00_together.tar.gz&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Combining DTM and dfu-next samples</title><link>https://devzone.nordicsemi.com/thread/556131?ContentTypeID=1</link><pubDate>Wed, 03 Dec 2025 14:04:27 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:476674f5-d796-414f-b03f-5b1816418910</guid><dc:creator>Edvin</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Is there a reason why you need DFU on the direct_test_mode application? What kind of DFU are you trying to add? Bluetooth or serial?&lt;/p&gt;
&lt;p&gt;Can you please zip and upload the application that you are trying to build, and let me know what NCS version you are using, and what board target you are building for. If it is a custom board, please upload the board files as well, so that I can replicate the build issue that you are seeing.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Edvin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>