This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

nRF5340-DK problem starting own project ncs v1.5.0

HI

I'm in the process of evaluating nRF5340 but am new to Nordic chips and development environment. Im running Windows 10 and I installed nRF Connect 3.6.1 and installed the toolchain through it.

I managed to run the blinky proiect but have problems starting an own project.

I followed this guide

https://devzone.nordicsemi.com/nordic/nrf-connect-sdk-guides/b/getting-started/posts/nrf-connect-sdk-tutorial---part-1-ncs-v1-4-0

but when I build, I get this error

Creating solution Bprufa02.emProject
C:/Users/Notandi/ncs/v1.5.0/toolchain/opt/bin/cmake.exe -GNinja -DBOARD=nrf5340dk_nrf5340_cpuappns -DBOARD_DIR=C:\Users\Notandi\ncs\v1.5.0\zephyr\boards\arm\nrf5340dk_nrf5340 -BC:\Users\Notandi\Dropbox (Kiso)\BVerk\Geometer\V4\nordic\Bprufa02\build_nrf5340dk_nrf5340_cpuappns -SC:\Users\Notandi\Dropbox (Kiso)\BVerk\Geometer\V4\nordic\Bprufa02 -DNCS_TOOLCHAIN_VERSION=1.5.0 -DEXTRA_KCONFIG_TARGETS=menuconfig_ses -DEXTRA_KCONFIG_TARGET_COMMAND_FOR_menuconfig_ses=C:\Users\Notandi\ncs\v1.5.0\toolchain\segger_embedded_studio/html/configure_nordic_project_menuconfig.py
-- Application: C:/Users/Notandi/Dropbox (Kiso)/BVerk/Geometer/V4/nordic/Bprufa02
-- Zephyr version: 2.4.99 (C:/Users/Notandi/ncs/v1.5.0/zephyr)
-- Found Python3: C:/Users/Notandi/ncs/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: C:/Users/Notandi/ncs/v1.5.0/zephyr/.cache
-- Found dtc: C:/Users/Notandi/ncs/v1.5.0/toolchain/opt/bin/dtc.exe (found suitable version "1.4.7", minimum required is "1.4.6")
-- Found toolchain: gnuarmemb (C:/Users/Notandi/ncs/v1.5.0/toolchain/opt)
-- Found BOARD.dts: C:/Users/Notandi/ncs/v1.5.0/zephyr/boards/arm/nrf5340dk_nrf5340/nrf5340dk_nrf5340_cpuappns.dts
-- Generated zephyr.dts: C:/Users/Notandi/Dropbox (Kiso)/BVerk/Geometer/V4/nordic/Bprufa02/build_nrf5340dk_nrf5340_cpuappns/zephyr/zephyr.dts
-- Generated devicetree_unfixed.h: C:/Users/Notandi/Dropbox (Kiso)/BVerk/Geometer/V4/nordic/Bprufa02/build_nrf5340dk_nrf5340_cpuappns/zephyr/include/generated/devicetree_unfixed.h
-- Generated device_extern.h: C:/Users/Notandi/Dropbox (Kiso)/BVerk/Geometer/V4/nordic/Bprufa02/build_nrf5340dk_nrf5340_cpuappns/zephyr/include/generated/device_extern.h
-- Configuring incomplete, errors occurred!
Including boilerplate (Zephyr base): C:/Users/Notandi/ncs/v1.5.0/zephyr/cmake/app/boilerplate.cmake
-- Using NCS Toolchain 1.5.0 for building. (C:/Users/Notandi/ncs/v1.5.0/toolchain/cmake)
CMake Error at C:/Users/Notandi/ncs/v1.5.0/zephyr/cmake/kconfig.cmake:204 (message):
File not found: C:/Users/Notandi/Dropbox
Call Stack (most recent call first):
C:/Users/Notandi/ncs/v1.5.0/zephyr/cmake/app/boilerplate.cmake:534 (include)
C:/Users/Notandi/ncs/v1.5.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:24 (include)
C:/Users/Notandi/ncs/v1.5.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:35 (include_boilerplate)
CMakeLists.txt:3 (find_package)



error: cmake failed
create_nordic_project.py failed (1)

I have spend several days on this problems and looked around but cannot find a solution. I would be very happy for any hint.

Does it matter that the example uses version 1.4 and I have 1.5?

Best regards,

Baldur

Parents
  • Hi Carl Richard.

    Thank you very much for your answers. They were very helpful.

    Regarding question 3, I have looked around but cannot see any attachment. Might I be overlooking something?

    I got curious about the file you mention (<ncs_root>\zephyr\boards\arm\nrf5340dk_nrf5340\nrf5340_cpuapp_common.dts). I could see it in my blinky_pwm project, but double-clicking on it tells me that I can not read it:

    I could find it in my installation path

    and looking at it in a text editor, it seems to define my nrf5340-DK on-board-resources  (pinout for leds, buttons,...).

    I guess that this file is common for all projects (and is thus not copied to each project) and as such the system makes it non-editable (since the board is fixed). Am I correct?

    If I was to make my own board, I guess I would make me a file like this that describes the on-board resources?

    Working with other ARM processors, the IDE typically has some kind of setup manager for the on-chip resources (setting clock frequency, enabling counters and so on - in general setting of all the processor registers). Is that what devicetree is about, or is there some tool that I am missing (similar to processor expert in NXP or STM32CubeMX)?

    If devicetreee.h describes the registers, I expect that it would be different for every project and thus under the project folder. I looked at my project folder and its subdirectories:

    C:\Users\Notandi\ncs\v1.5.0\zephyr\samples\basic\blinky_pwm

    but I could not find a devicetree.h for this  project.

    Best regards,

    Baldur

Reply
  • Hi Carl Richard.

    Thank you very much for your answers. They were very helpful.

    Regarding question 3, I have looked around but cannot see any attachment. Might I be overlooking something?

    I got curious about the file you mention (<ncs_root>\zephyr\boards\arm\nrf5340dk_nrf5340\nrf5340_cpuapp_common.dts). I could see it in my blinky_pwm project, but double-clicking on it tells me that I can not read it:

    I could find it in my installation path

    and looking at it in a text editor, it seems to define my nrf5340-DK on-board-resources  (pinout for leds, buttons,...).

    I guess that this file is common for all projects (and is thus not copied to each project) and as such the system makes it non-editable (since the board is fixed). Am I correct?

    If I was to make my own board, I guess I would make me a file like this that describes the on-board resources?

    Working with other ARM processors, the IDE typically has some kind of setup manager for the on-chip resources (setting clock frequency, enabling counters and so on - in general setting of all the processor registers). Is that what devicetree is about, or is there some tool that I am missing (similar to processor expert in NXP or STM32CubeMX)?

    If devicetreee.h describes the registers, I expect that it would be different for every project and thus under the project folder. I looked at my project folder and its subdirectories:

    C:\Users\Notandi\ncs\v1.5.0\zephyr\samples\basic\blinky_pwm

    but I could not find a devicetree.h for this  project.

    Best regards,

    Baldur

Children
  • Hi again, Baldur!

    I must have forgotten to actually attach it. My bad! Here it is: nrf5340_cpuapp_common.dts  

    Baldur said:
    I guess that this file is common for all projects (and is thus not copied to each project) and as such the system makes it non-editable (since the board is fixed). Am I correct?

    This is correct. However, changes to the DTS can be made, but then the project must be reopened. Commonly overlay files are used to configure the various available hardware resources/peripherals.

    Baldur said:
    If I was to make my own board, I guess I would make me a file like this that describes the on-board resources?

     Correct! You can of course use pre-existing board definitions, but then it's important to keep track of which on-board resources that are present and which that aren't.

    Baldur said:
    Working with other ARM processors, the IDE typically has some kind of setup manager for the on-chip resources (setting clock frequency, enabling counters and so on - in general setting of all the processor registers). Is that what devicetree is about, or is there some tool that I am missing (similar to processor expert in NXP or STM32CubeMX)?

    Configuration of on-chip and on-board resources happen both through devicetree configuration and Kconfigs (usually a combination of these). In general hardware specific configuration like pin assignments, frequency and so on are done using devicetree overlays, while more firmware related configuration is done through Kconfigs. The Zephyr documentation has some information on Devicetree versus Kconfig.

    Baldur said:
    If devicetreee.h describes the registers, I expect that it would be different for every project and thus under the project folder. I looked at my project folder and its subdirectories:

     I believe you're looking for the file "devicetree_unfixed.h", located at <project_folder>\build\zephyr\include\generated\devicetree_unfixed.h.

    Best regards,
    Carl Richard

Related