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

SES Compiler error for Thingy:91 asset_tracker - 'NRF_SPU' undeclared (first use in this function); did you mean 'NRF_SPU_S'?

I'm currently unable to build the asset_tracker for Thingy:91 on Segger Embedded Studio - using nrf9160_pca20035ns for the nRF Connect SDK Project

Do anyone have an idea why this occurs?

Br Dag

nRF Connect Options

Parents Reply
  • As mentioned, I have tried several different approches - the latest cloning the fw-nrfconnect-nrf onto my source dir, and the HEAD is e9f0bc0e3ebfab249d8906c12ad060418b16f238. v1.0-branch, and nrf-source directory is neamed fw-nrfconnect-nrf. Not nrf.

    I tried all the [ns] variant you mention without any luck.

    However, when I try to run the python scripts I'm faced with a lot of errors - some quite strange, like that Visual Studio 14 is missing...??

Children
  • Did you follow the "Getting Started Assistant" when installing NCS?

    What python scripts are you talking about? The requirements files in {zephyr, nrf, mcuboot}/scripts/requirements.txt?

  • Yes, I followed the "Getting Started Assistant" when installing NCS -

    And yes, the Pyhton scripts I'm refering to are those that seem to deploy the requirements description/files.

    cd <sourcecode_root>\ncs
    pip3 install -r zephyr\scripts\requirements.txt
    pip3 install -r nrf\scripts\requirements.txt
    pip3 install -r mcuboot\scripts\requirements.txt

    Using Nordic as sourcecode root.

    When running

    pip3 install -r nrf\scripts\requirements.txt

    the printouts tell me that most of the requirements are met but I also get a lot of red printouts as well.

    Below is a random tiny fragment of the printout from the above command,

    containing the Microsoft Visual C++ 14.0, which I find strange unless it is related to SES in some way.

    ...
    ...
    running build_ext
      generating cffi module 'build\\temp.win-amd64-3.8\\Release\\pygit2._libgit2.c'
      creating build\temp.win-amd64-3.8
      creating build\temp.win-amd64-3.8\Release
      building '_pygit2' extension
      error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/
      ----------------------------------------
      ERROR: Failed building wheel for pygit2
      Running setup.py clean for pygit2
      Building wheel for editdistance (setup.py) ... error
      ERROR: Command errored out with exit status 1:
       command: 'c:\python38\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\dagak\\AppDat
    ...
    ...

    Anyways - I'll look further into this tomorrow.

  • What Python version do you have?

    Some of the dependencies have not yet updated to Python 3.8, so we recommend still using 3.7.

    Regarding the specific error you get, the Python library is based on a C library. To build the C library, you need the "Microsoft Visual C++ Build Tools" toolchain.

    So there is no need for the full Visual Studio, you just need the C++ toolchain.

    Also, can you send me your ncs/zephyr/cmake/app/boilerplate.cmake?

  • Hi again

    I just managed to build the asset_traker in full - on two PCs. Hurry:-)

    Lessons learned:

    • I should have chosen "master" for ncs_tag in the right-most panel in the Getting Started Assistant.
    • Chocolatey may clutter my control - will install Python38...choco uninstall will conflict with Windows uninstall for this program...
    • and of course, using the boards directory in the nrf directory, not the one in the zephyr directory, which do not contain the board description for the PCA20035.

    According to your last comment on python38, this might be the reason for the massive red output when installing the stuff based on the nrf requirements, but asset_tracer was regardless built successfully.

    Last question: Do you think that I should use Python37 instead og 38 for now?

    Thanks for your support.

    Br Dag

    Btw - is it possible to use the USB connector on the Thingy91 to program/update it?

  • Great to hear that you got it working!

    I would use 3.7, as I know that it works. I do not know how big of an issue it would be to use 3.8, but to be safe I would recommend using 3.7.

    You should be able to downgrade using the following commands:

    choco uninstall python
    choco install python --version 3.7.3

    Best regards,

    Didrik

Related