I can´t run west from VCS. The west command is not found on VCS terminal.
If I go to the NCS Toolchain Manager and call the Bash or Command Prompt from there, I can run west.
What am I missing?

  • jaredwolff and K2AAE replied to this.
  • @joaodullius @K2AAE is correct. You can open up a command prompt and then run:

    C:
    cd \ncs\v1.4.1\toolchain\cmd\
    env.cmd

    That will load the environment. Opening VSCode with code . will maintain that environment.

    Alternatively you can also run env.cmd within the VSCode console and that ill get you the same results.

    Hope that helps!

    Hey joaodullius

    You need to run It from the toolchain manager command prompt. There’s an easy way to import the environment via Mac. I’ll see if I can emulate the same on Windows. I’ll get back to you on it.

    joaodullius Before you start VSC open a CMD prompt and CD to the SDK you are using:
    NOTE: I have the SDK setup on D: in ncs
    D:
    CD \ncs\v1.4.1
    toolchain\cmd\env.cmd
    code .
    When VSC starts you can open a terminal and enter:
    ls env:
    to check that you have setup nRF
    west will now work

    When you get VCS working let us know how! Mine start kicking out errors but I think I have golang setting causing issues.

    @joaodullius @K2AAE is correct. You can open up a command prompt and then run:

    C:
    cd \ncs\v1.4.1\toolchain\cmd\
    env.cmd

    That will load the environment. Opening VSCode with code . will maintain that environment.

    Alternatively you can also run env.cmd within the VSCode console and that ill get you the same results.

    Hope that helps!

      jaredwolff
      Running env.cmd in VSC terminal doesn’t work.
      .\env.cmd
      runs but PowerShell ignores the setting, when you ls env: none ot the nRF environment is setup

      Running west from VSC terminal without setting the environment:

      PS D:\ncs\v1.4.1\toolchain\cmd> west –version
      west : The term ‘west’ is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is
      correct and try again.
      At line:1 char:1

      • west –version
      • ~~~~
      • + CategoryInfo : ObjectNotFound: (west:String) [], CommandNotFoundException
      • + FullyQualifiedErrorId : CommandNotFoundException

      After running env.cmd then code .
      PS D:\ncs\v1.4.1> west –version
      West version: v0.7.2
      PS D:\ncs\v1.4.1>
      ls env:
      Path D:\ncs\v1.4.1\toolchain;D:\ncs\v1.4.1\toolchain\mingw64\bin;D:\ncs\v1.4.1\toolchain\opt\bin;D:\ncs\v1.4.1\toolchain\opt\bin\Scripts;D:\ncs\v1.4.1\toolchain\segger_e…

      I did the following:
      Copyed env.cmd to start_code.cmd on the \toolchain\cmd directory
      added “start code” at the end of start_code.cmd
      Created a shortcut on my Desktop to the start_code.cmd

      Thanks @jaredwolff and @K2AAE for the feedbacks.

        Terms and Conditions | Privacy Policy