I have an NCS project compiling and running for nRF52840 (nrf52840-DK) and am attempting to transition this project to nRF5340 (nRF5340-DK). (Prior to this, I tested the nRF5340 using the Heart Rate example, directly downloading the .hex files as supplied by Nordic.)
I'm using Segger Embedded Studio and nRF Connect SDK v1.5.0 (and tool version 1.5.0). As mentioned above, when targeting nrf52840df_nrf52840 everything compiles and runs as expected.
To start transitioning to nRF5340, I closed the nrf52840 solution, then attempted to create a new project using Segger Embedded Solution (SES). I pointed to the project directory and selected the board target as nrf5340dk_nrf5340_cpuappns.
SES reports that it "Cannot create project" with the message "create_nordic_project.py failed (1)."
A build directory is created (build_nrf5340dk_nrf5340_cpuappns) and populated. i will attach the CMakeOutput and CMakeError files.
I updated both the SDK and Tools and tried again, with the same results.
Can you suggest what I'm doing wrong?
Compiling the C compiler identification source file "CMakeCCompilerId.c" failed. Compiler: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/arm-none-eabi-gcc.exe Build flags: Id flags: The output was: 1 e:/additionalwindowstools/nordic/nrf_connect_sdk/v1.5.0/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/bin/ld.exe: e:/additionalwindowstools/nordic/nrf_connect_sdk/v1.5.0/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/lib\libc.a(lib_a-exit.o): in function `exit': exit.c:(.text.exit+0x2c): undefined reference to `_exit' collect2.exe: error: ld returned 1 exit status Compiling the CXX compiler identification source file "CMakeCXXCompilerId.cpp" failed. Compiler: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/arm-none-eabi-gcc.exe Build flags: Id flags: The output was: 1 e:/additionalwindowstools/nordic/nrf_connect_sdk/v1.5.0/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/bin/ld.exe: e:/additionalwindowstools/nordic/nrf_connect_sdk/v1.5.0/toolchain/opt/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/lib\libc.a(lib_a-exit.o): in function `exit': exit.c:(.text.exit+0x2c): undefined reference to `_exit' collect2.exe: error: ld returned 1 exit status
The target system is: Generic - 2.4.99 - arm The host system is: Windows - 10.0.18363 - AMD64 Compiling the C compiler identification source file "CMakeCCompilerId.c" succeeded. Compiler: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/arm-none-eabi-gcc.exe Build flags: Id flags: -c The output was: 0 Compilation of the C compiler identification source "CMakeCCompilerId.c" produced "CMakeCCompilerId.o" The C compiler identification is GNU, found in "C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/CMakeFiles/3.17.3/CompilerIdC/CMakeCCompilerId.o" Compiling the CXX compiler identification source file "CMakeCXXCompilerId.cpp" succeeded. Compiler: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/arm-none-eabi-gcc.exe Build flags: Id flags: -c The output was: 0 Compilation of the CXX compiler identification source "CMakeCXXCompilerId.cpp" produced "CMakeCXXCompilerId.o" The CXX compiler identification is GNU, found in "C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/CMakeFiles/3.17.3/CompilerIdCXX/CMakeCXXCompilerId.o" Checking whether the ASM compiler is GNU using "--version" matched "(GNU assembler)|(GCC)|(Free Software Foundation)": arm-none-eabi-gcc.exe (GNU Tools for Arm Embedded Processors 9-2019-q4-major) 9.2.1 20191025 (release) [ARM/arm-9-branch revision 277599] Copyright (C) 2019 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Determining if files stdatomic.h exist passed with the following output: Change Dir: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/CMakeFiles/CMakeTmp Run Build Command(s):E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/ninja.exe cmTC_df50c && [1/2] Building C object CMakeFiles/cmTC_df50c.dir/HAVE_STDATOMIC_H.c.obj [2/2] Linking C executable cmTC_df50c arm-none-eabi-gcc.exe: warning: CMakeFiles/cmTC_df50c.dir/HAVE_STDATOMIC_H.c.obj: linker input file unused because linking not done Determining if files fcntl.h exist passed with the following output: Change Dir: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/CMakeFiles/CMakeTmp Run Build Command(s):E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/ninja.exe cmTC_a5f11 && [1/2] Building C object CMakeFiles/cmTC_a5f11.dir/HAVE_FCNTL_H.c.obj [2/2] Linking C executable cmTC_a5f11 arm-none-eabi-gcc.exe: warning: CMakeFiles/cmTC_a5f11.dir/HAVE_FCNTL_H.c.obj: linker input file unused because linking not done
The console log is:
Creating solution RocketTelemetry.emProject E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/cmake.exe -GNinja -DBOARD=nrf5340dk_nrf5340_cpuappns -DBOARD_DIR=E:\AdditionalWindowsTools\Nordic\nRF_Connect_SDK\v1.5.0\zephyr\boards\arm\nrf5340dk_nrf5340 -BC:\Users\hepler\Projects\RocketTelemetry\Software\Nordic\RocketTelemetry\build_nrf5340dk_nrf5340_cpuappns -SC:\Users\hepler\Projects\RocketTelemetry\Software\Nordic\RocketTelemetry -DNCS_TOOLCHAIN_VERSION=1.5.0 -DEXTRA_KCONFIG_TARGETS=menuconfig_ses -DEXTRA_KCONFIG_TARGET_COMMAND_FOR_menuconfig_ses=E:\AdditionalWindowsTools\Nordic\nRF_Connect_SDK\v1.5.0\toolchain\segger_embedded_studio/html/configure_nordic_project_menuconfig.py -- Application: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry -- Zephyr version: 2.4.99 (E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr) -- Found Python3: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/python.exe (found suitable exact version "3.8.2") found components: Interpreter -- Found west (found suitable version "0.9.0", minimum required is "0.7.1") -- Board: nrf5340dk_nrf5340_cpuappns -- Cache files will be written to: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/.cache -- Found dtc: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/dtc.exe (found suitable version "1.4.7", minimum required is "1.4.6") -- Found toolchain: gnuarmemb (E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt) -- Found BOARD.dts: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/boards/arm/nrf5340dk_nrf5340/nrf5340dk_nrf5340_cpuappns.dts -- Found devicetree overlay: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/boards/nrf5340dk_nrf5340_cpuappns.overlay -- Generated zephyr.dts: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/zephyr/zephyr.dts -- Generated devicetree_unfixed.h: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/zephyr/include/generated/devicetree_unfixed.h -- Generated device_extern.h: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/zephyr/include/generated/device_extern.h Parsing E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/Kconfig Loaded configuration 'E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/boards/arm/nrf5340dk_nrf5340/nrf5340dk_nrf5340_cpuappns_defconfig' Merged configuration 'C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/prj.conf' Configuration saved to 'C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/zephyr/.config' Kconfig header saved to 'C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/zephyr/include/generated/autoconf.h' -- The C compiler identification is GNU 9.2.1 -- The CXX compiler identification is GNU 9.2.1 -- The ASM compiler identification is GNU -- Found assembler: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/arm-none-eabi-gcc.exe -- Application: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/nrf/samples/spm -- Zephyr version: 2.4.99 (E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr) -- Found Python3: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/python.exe (found suitable exact version "3.8.2") found components: Interpreter -- Found west (found suitable version "0.9.0", minimum required is "0.7.1") -- Board: nrf5340dk_nrf5340_cpuapp -- Cache files will be written to: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/.cache -- Found dtc: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/dtc.exe (found suitable version "1.4.7", minimum required is "1.4.6") -- Found toolchain: gnuarmemb (E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt) -- Found BOARD.dts: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/boards/arm/nrf5340dk_nrf5340/nrf5340dk_nrf5340_cpuapp.dts -- Generated zephyr.dts: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/spm/zephyr/zephyr.dts -- Generated devicetree_unfixed.h: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/spm/zephyr/include/generated/devicetree_unfixed.h -- Generated device_extern.h: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/spm/zephyr/include/generated/device_extern.h Parsing E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/Kconfig Loaded configuration 'E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/boards/arm/nrf5340dk_nrf5340/nrf5340dk_nrf5340_cpuapp_defconfig' Merged configuration 'E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/nrf/samples/spm/prj.conf' Merged configuration 'E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/nrf/subsys/partition_manager/partition_manager_enabled.conf' Merged configuration 'C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/spm/zephyr/misc/generated/extra_kconfig_options.conf' Configuration saved to 'C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/spm/zephyr/.config' Kconfig header saved to 'C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/spm/zephyr/include/generated/autoconf.h' -- The C compiler identification is GNU 9.2.1 -- The CXX compiler identification is GNU 9.2.1 -- The ASM compiler identification is GNU -- Found assembler: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/arm-none-eabi-gcc.exe -- Configuring done -- Generating done -- Build files have been written to: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/spm -- Application: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/samples/bluetooth/hci_rpmsg -- Zephyr version: 2.4.99 (E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr) -- Found Python3: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/python.exe (found suitable exact version "3.8.2") found components: Interpreter -- Found west (found suitable version "0.9.0", minimum required is "0.7.1") -- Board: nrf5340dk_nrf5340_cpunet -- Cache files will be written to: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/.cache -- Found dtc: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/dtc.exe (found suitable version "1.4.7", minimum required is "1.4.6") -- Found toolchain: gnuarmemb (E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt) -- Found BOARD.dts: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/boards/arm/nrf5340dk_nrf5340/nrf5340dk_nrf5340_cpunet.dts -- Generated zephyr.dts: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/hci_rpmsg/zephyr/zephyr.dts -- Generated devicetree_unfixed.h: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/hci_rpmsg/zephyr/include/generated/devicetree_unfixed.h -- Generated device_extern.h: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/hci_rpmsg/zephyr/include/generated/device_extern.h Parsing E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/Kconfig Loaded configuration 'E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/boards/arm/nrf5340dk_nrf5340/nrf5340dk_nrf5340_cpunet_defconfig' Merged configuration 'E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/samples/bluetooth/hci_rpmsg/prj.conf' Merged configuration 'E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/nrf/subsys/bluetooth/controller/bt_ll_softdevice_hci_rpmsg.conf' Merged configuration 'E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/nrf/subsys/partition_manager/partition_manager_enabled.conf' Configuration saved to 'C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/hci_rpmsg/zephyr/.config' Kconfig header saved to 'C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/hci_rpmsg/zephyr/include/generated/autoconf.h' -- The C compiler identification is GNU 9.2.1 -- The CXX compiler identification is GNU 9.2.1 -- The ASM compiler identification is GNU -- Found assembler: E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/opt/bin/arm-none-eabi-gcc.exe -- Looking for include file stdatomic.h -- Looking for include file stdatomic.h - found -- Looking for include file fcntl.h -- Looking for include file fcntl.h - found -- Configuring done -- Generating done -- Build files have been written to: C:/Users/hepler/Projects/RocketTelemetry/Software/Nordic/RocketTelemetry/build_nrf5340dk_nrf5340_cpuappns/hci_rpmsg -- Looking for include file stdatomic.h -- Looking for include file stdatomic.h - found -- Looking for include file fcntl.h -- Looking for include file fcntl.h - found -- Configuring done Including boilerplate (Zephyr base): E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/cmake/app/boilerplate.cmake -- Using NCS Toolchain 1.5.0 for building. (E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/cmake) warning: BT_CTLR_RX_BUFFERS (defined at subsys/bluetooth/controller/Kconfig:166) was assigned the value '2' but got the value ''. Check these unsatisfied dependencies: BT_CTLR (=n). See http://docs.zephyrproject.org/latest/reference/kconfig/CONFIG_BT_CTLR_RX_BUFFERS.html and/or look up BT_CTLR_RX_BUFFERS 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: BT_CTLR_TX_BUFFERS (defined at subsys/bluetooth/controller/Kconfig:176) was assigned the value '8' but got the value ''. Check these unsatisfied dependencies: BT_CTLR (=n). See http://docs.zephyrproject.org/latest/reference/kconfig/CONFIG_BT_CTLR_TX_BUFFERS.html and/or look up BT_CTLR_TX_BUFFERS 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: BT_CTLR_TX_BUFFER_SIZE (defined at subsys/bluetooth/controller/Kconfig:187) was assigned the value '251' but got the value ''. Check these unsatisfied dependencies: BT_CTLR (=n). See http://docs.zephyrproject.org/latest/reference/kconfig/CONFIG_BT_CTLR_TX_BUFFER_SIZE.html and/or look up BT_CTLR_TX_BUFFER_SIZE 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: BT_CTLR_DATA_LENGTH_MAX (defined at subsys/bluetooth/controller/Kconfig:345) was assigned the value '251' but got the value ''. Check these unsatisfied dependencies: BT_CTLR_DATA_LENGTH (=n), BT_CTLR (=n). See http://docs.zephyrproject.org/latest/reference/kconfig/CONFIG_BT_CTLR_DATA_LENGTH_MAX.html and/or look up BT_CTLR_DATA_LENGTH_MAX 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: BT_CTLR_PHY_2M (defined at subsys/bluetooth/controller/Kconfig:424) was assigned the value 'y' but got the value 'n'. Check these unsatisfied dependencies: (BT_CTLR_PHY || BT_CTLR_ADV_EXT) (=n), BT_CTLR_PHY_2M_SUPPORT (=n), BT_CTLR (=n). See http://docs.zephyrproject.org/latest/reference/kconfig/CONFIG_BT_CTLR_PHY_2M.html and/or look up BT_CTLR_PHY_2M 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. Changed board to secure nrf5340dk_nrf5340_cpuapp (NOT NS) === child image spm - begin === Including boilerplate (Zephyr base): E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/cmake/app/boilerplate.cmake -- Using NCS Toolchain 1.5.0 for building. (E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/cmake) === child image spm - end === Adding 'hci_rpmsg' firmware as child image since CONFIG_BT_RPMSG_NRF53 is set to 'y' === child image hci_rpmsg - CPUNET begin === Including boilerplate (Zephyr base): E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/cmake/app/boilerplate.cmake -- Using NCS Toolchain 1.5.0 for building. (E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/toolchain/cmake) -- Build type: -- Host: Windows/AMD64 -- Target: Generic/arm -- Machine: cortexm -- Host: Windows/AMD64 -- Target: Generic/arm -- Machine: cortexm -- C_FLAGS : -Wall -Wextra CMake Warning at ../../../CMakeLists.txt:1357 (message): __ASSERT() statements are globally ENABLED === child image hci_rpmsg - CPUNET end === -- Build type: -- Host: Windows/AMD64 -- Target: Generic/arm -- Machine: cortexm -- Host: Windows/AMD64 -- Target: Generic/arm -- Machine: cortexm -- C_FLAGS : -Wall -Wextra CMake Error at E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/cmake/extensions.cmake:416 (add_library): No SOURCES given to target: drivers__spi Call Stack (most recent call first): E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/cmake/extensions.cmake:393 (zephyr_library_named) E:/AdditionalWindowsTools/Nordic/nRF_Connect_SDK/v1.5.0/zephyr/drivers/spi/CMakeLists.txt:3 (zephyr_library) CMake Generate step failed. Build files cannot be regenerated correctly. error: cmake failed create_nordic_project.py failed (1)
It appears to not be able to find SPI drivers??
Thanks!