nRF Connect Extension for VS Code Unable to run most commands

While following the "nRF Connect SDK Fundamentals" tutorial, my nRF Connect extension fails on the "Install Toolchain" step with error command 'nrf-connect.installToolchain' not found. I'm able to circumvent for now by using nRF Connect for Desktop and installing the toolchain with its Toolchain Manager, but still troubling that none of the commands seem to work directly from the VS Code nRF Connect extension. Nearly all nRF Connect commands similarly fail from VS Code including "Install SDK", "Manage Toolchains", "Check nRF Command Line Tools Update".

Any help to resolve would be greatly appreciated!

My setup:

  • Windows 10 64bit PC
  • VS Code v1.86.1
  • nRF Connect for VS Code Extension pack v2023.11.3
  • nRF Command Line tools v10.24.0
  • Those are just from an example main.c program I had open at the time and many of them are just flagged as unknown spelling issues. Here is a new screenshot after reloading the window without any files open:

  • Hi Travis, Priyanka,

    I have been looking through this thread as I'm having the same issues:

    1. Watching the "Zephyr and Nordic nRF Connect SDK - 01 Intro and Installation" video.
    2. Trying to run the install toolchain and from the button which doesn't work.
    3. Trying to manually run install toolchain and getting the same error message.
    4. Seeing that the three extensions above are not activate.

    I am running windows and ran the installer for nrf-command-line-tools-10.24.0-x64.exe and the command line tools were installed into C:\Program Files\Nordic Semiconductor\nrf-command-line-tools.

    Since this wasn't working I was going to try this manually.  I installed nrfconnect-setup-4.4.0-x64.exe (nRF Connect for Desktop v4.4.0).  I ran the GUI for this and installed the Toolchain Manger.  In my case this created c:\ncs.  My c:\nsc was empty since I haven't actually run the Toolchain Manger and hadn't previously installed any tools chains on this computer.

    I went back to VSCode and now magically rRF Connect for VS Code runtime status is activated.  If I click on Install Toolchain I now get the list of installable toolschains.

    I think what is happening is that the video is missing the step to install the Toolchain Manager.  Also it appears that the Extension Pack needs to have the Toolchain Manager installed before it will work.  Looks like nRF Connect for VS Code depends on this as well.

    I can now have VSCode download and install toolchains.  I suspect installing SDKs will work as well.

    Hope this helps.

    Lenny

  • Thanks, Lenny!

    I first installed nRF Connect for Desktop v4.4.0 and then used its Toolchain Manager to install both the v1.9.1 and v2.5.2 SDKs as Priyanka described earlier in this thread, so my ncs folder looks like this:

    I'm wondering if, to follow what you did Lenny, I should have only installed the Toolchain Manager using nRF Connect for Desktop then immediately go to VS Code to see if the Toolchain Manager would work and let me install install SDKs directly from VS Code.

      if you think I should try a different order of installing dependencies could you please give guidance on how to properly uninstall what I have and the preferred order? I'm particularly curious how to clear out the existing Toolchain manager and SDKs in my ncs folder.

  • Hi,

    Yes that's indeed interesting. We could try a different order then. Could you try uninstalling everything from the control panel --> Program and features --> Uninstall a program

    and then select the nRF Connect for Desktop and uninstall it? 

    This should uninstall everything.

    Then you could once again try to install the nRF Connect for Desktop, followed by installing the Toolchain Manager and then from the Toolchain Manager try installing the SDK version that you want.

    Please try this and let's see how it goes for you.

    -Priyanka

  • I noticed that at some point after installing nRF Connect for Desktop, a new directory .nrfconnect-apps was created in my "home" directory (i.e. C:\Users\username\.nrfconnect-apps).  There is a bunch of stuff in there including node_modules which now has pc-nrfconnect-toolchain-manager.  My guess is that the VSCode extension needs this information to work. 

    Interestingly you can find code for all of the Desktop apps here (they start with pc- and pc-nrfconnect-launcher is the Desktop app).

Related