Getting started with vscode in Linux toolchain not found

System details:

- Ubuntu Linux version 20.04.5 LTS
- nRF Connect for Desktop v3.12.0
- Toolchain Manager v1.2.1
- NCS v2.2.0
- Visual Studio Code 1.74.3

I want to get started with Visual Studio Code and NCS 2. I found a guide on youtube that I followed:
https://www.youtube.com/watch?v=zcMCaODyISo

Because I had installed vscode before, I never got it to work and the forum suggested to uninstall everything before trying again I performed the following actions:
- removed all NCS versions
- uninstalled Visual Studio Code
- uninstalled nRF connect
- restarted my computer

Then I followed the steps in the video. The video suggests that it works on any operating system.

I installed the nRF Connect and installed the Toolchain Manager.
I installed NCS v2.2.0
From the Toolchain manager I started vscode, which was not installed.
After installing vscode I installed all the plugins.
Then the video suggest to go to the nRF welcome page and select the correct toolchain.

But I cannot change the toolchain, instead it's set to version 2.0.2, which is not installed?!

And there is a message saying:
An SDK is already selected in this workspace, so another cannot be selected.

I don't see an option to close the workspace or to create a new workspace.
But in the explorer I do not see a workspace. so I don't understand the error message?

I also tried copying blinky example to a new directory, then choose file - open folder - blinky. But I still cannot change the toolchain.

Parents
  • You may trying launching Visual Studio Code directly instead of from the Toolchain Manager.

  • Thank you for the suggestion. I just tried but it did not solve the problem (problem remains the same).

  • Hi Philip,

    Could you attach the support Infirmation? It is available from the "Generate Support Information" option in VSCode.

    Best Regards,

    Priyanka

  • I assume To generate it open command palette (ctrl+shift+p) in VS Code and write nRF Connect: generate support information. ?

    IMPORTANT: The data below could contain sensitive or confidential information about your environment.
    If you do not wish this to be seen by others, please make sure to remove it before sharing.
    
    For help and support, visit the Nordic DevZone at https://devzone.nordicsemi.com/.
    
    {
      "platform": {
        "os": "linux",
        "osVersion": "#156-Ubuntu SMP Fri Jan 20 17:27:18 UTC 2023",
        "osKernel": "5.4.0-139-generic",
        "vscode": "1.75.1",
        "electron": "19.1.9",
        "node": "v16.14.2"
      },
      "system": {
        "date": "2023-02-13T22:49:30.797Z",
        "vscodeRoot": "/usr/share/code/resources/app",
        "nrfConnectForDesktopInstalled": "unknown",
        "vscodeUptime": "02:05:38",
        "osUptime": "05:57:49",
        "cpu": {
          "model": "Intel(R) Core(TM) i5-8250U CPU @ 1.60GHz",
          "speed": "1771 MHz",
          "count": 4
        },
        "memory": {
          "total": "15.40 GB",
          "free": "7.32 GB"
        }
      },
      "workspace": {
        "name": "project (Workspace)",
        "workspaceFile": "/home/ephimee/vscode/blinky/application/project.code-workspace",
        "folders": [
          "/home/ephimee/vscode/blinky/application",
          "/home/ephimee/vscode/blinky/application/..\\library_sdk",
          "/home/ephimee/vscode/blinky/application/..\\..\\..\\ncs\\v2.2.0"
        ]
      },
      "extensions": {
        "internal": {
          "nordic-semiconductor.nrf-connect": {
            "version": "2023.1.44",
            "path": "/home/ephimee/.vscode/extensions/nordic-semiconductor.nrf-connect-2023.1.44-linux-x64",
            "isActive": true
          },
          "nordic-semiconductor.nrf-terminal": {
            "version": "2022.11.29",
            "path": "/home/ephimee/.vscode/extensions/nordic-semiconductor.nrf-terminal-2022.11.29",
            "isActive": true
          },
          "nordic-semiconductor.nrf-devicetree": {
            "version": "2022.11.153",
            "path": "/home/ephimee/.vscode/extensions/nordic-semiconductor.nrf-devicetree-2022.11.153",
            "isActive": true
          },
          "nordic-semiconductor.nrf-kconfig": {
            "version": "2022.11.50",
            "path": "/home/ephimee/.vscode/extensions/nordic-semiconductor.nrf-kconfig-2022.11.50",
            "isActive": true
          }
        },
        "external": {
          "marus25.cortex-debug": null,
          "ms-vscode.cpptools": "1.13.9",
          "ms-vscode.js-debug": "1.75.1",
          "ms-vscode.js-debug-companion": "1.0.18",
          "ms-vscode.vscode-js-profile-table": "1.0.3",
          "mcu-debug.debug-tracker-vscode": "0.0.13",
          "mcu-debug.memory-view": "0.0.19",
          "mcu-debug.rtos-views": "0.0.4",
          "trond-snekvik.gnu-mapfiles": "1.1.0",
          "twxs.cmake": "0.0.17",
          "utsavm9.c-cpp-flag-debugging": "0.0.1"
        }
      },
      "tools": {
        "/home/ephimee/ncs2/toolchains/v2.2.0/opt/zephyr-sdk/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc": "0.15.1",
        "/opt/SEGGER/JLink/JLinkExe": "6.88a",
        "/usr/local/bin/nrfjprog": "10.17.2",
        "/home/ephimee/.local/bin/nrfutil": null,
        "/home/ephimee/ncs2/toolchains/v2.2.0/usr/local/bin/cmake": "3.20.5",
        "/home/ephimee/ncs2/toolchains/v2.2.0/usr/local/bin/west": "0.14.0",
        "/home/ephimee/ncs2/toolchains/v2.2.0/usr/local/bin/python3": "3.8.2",
        "/home/ephimee/ncs2/toolchains/v2.2.0/usr/local/bin/ninja": "1.9.0",
        "/home/ephimee/ncs2/toolchains/v2.2.0/usr/bin/gperf": "3.1",
        "/home/ephimee/ncs2/toolchains/v2.2.0/usr/bin/dtc": "1.4.7",
        "/home/ephimee/ncs2/toolchains/v2.2.0/opt/bin/gn": "1871",
        "/home/ephimee/ncs2/toolchains/v2.2.0/usr/local/bin/git": "2.37.3",
        "gdbPath": "/home/ephimee/ncs2/toolchains/v2.2.0/opt/zephyr-sdk/arm-zephyr-eabi/bin/arm-zephyr-eabi-gdb"
      },
      "sdks": [
        {
          "version": "Zephyr 2.4.99",
          "path": "/home/ephimee/zephyrproject"
        },
        {
          "version": "2.2.0",
          "path": "/home/ephimee/ncs2/v2.2.0"
        }
      ],
      "toolchains": [
        {
          "version": "2.2.0",
          "path": "/home/ephimee/ncs2/toolchains/v2.2.0"
        }
      ],
      "connectedDevices": [],
      "deviceProviders": [
        "nrfjprog"
      ],
      "config": {
        "nordic-semiconductor.nrf-connect": {
          "topdir": "${workspaceFolder:v2.2.0}",
          "toolchain": {
            "path": "${nrf-connect.toolchain:2.2.0}"
          },
          "ozonePath": "",
          "applications": [
            "${workspaceFolder:application}"
          ],
          "applicationOptions": {},
          "kconfig": {
            "interface": "kconfig",
            "executeInDefaultShell": false
          },
          "welcome": {
            "showOnStartup": false
          },
          "west": {
            "env": {
              "$base": "terminal"
            }
          },
          "boardRoots": [],
          "enableTelemetry": true,
          "taskBindings": {},
          "debugging": {
            "backend": "nRF Debug",
            "flash": true,
            "bindings": {}
          },
          "activeAppFollowActiveEditor": true
        },
        "nordic-semiconductor.nrf-terminal": {
          "terminalMode": "character",
          "scrollBack": 1000
        },
        "marus25.cortex-debug": {
          "JLinkGDBServerPath": "/opt/SEGGER/JLink/JLinkGDBServerCLExe",
          "armToolchainPath": "/home/ephimee/zephyr-sdk-0.14.2/arm-zephyr-eabi/bin",
          "armToolchainPrefix": "arm-zephyr-eabi"
        }
      },
      "environment": {
        "westExe": "west",
        "westEnv": {
          "ELECTRON_RUN_AS_NODE": "1",
          "GIT_EXEC_PATH": "/home/ephimee/ncs2/toolchains/v2.2.0/usr/lib/git-core",
          "HOME": "/home/ephimee",
          "PATH": "/home/ephimee/ncs2/toolchains/v2.2.0/usr/bin:/home/ephimee/ncs2/toolchains/v2.2.0/usr/local/bin:/home/ephimee/ncs2/toolchains/v2.2.0/opt/bin:/home/ephimee/ncs2/toolchains/v2.2.0/opt/nanopb/generator-bin:/home/ephimee/ncs2/toolchains/v2.2.0/opt/zephyr-sdk/arm-zephyr-eabi/bin:/home/ephimee/ncs2/toolchains/v2.2.0/arm-zephyr-eabi/bin:/tmp/.mount_nrfcon8vzoJN:/tmp/.mount_nrfcon8vzoJN/usr/sbin:/home/ephimee/.local/bin:/home/ephimee/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin",
          "ZEPHYR_BASE": "/home/ephimee/vscode/blinky/application/..\\..\\..\\ncs\\v2.2.0/zephyr",
          "ZEPHYR_TOOLCHAIN_VARIANT": "zephyr",
          "ZEPHYR_SDK_INSTALL_DIR": "/home/ephimee/ncs2/toolchains/v2.2.0/opt/zephyr-sdk",
          "PYTHONPATH": "/home/ephimee/ncs2/toolchains/v2.2.0/usr/local/lib/python3.8/site-packages",
          "USER": "ephimee"
        },
        "inherited": {
          "ELECTRON_RUN_AS_NODE": "1",
          "HOME": "/home/ephimee",
          "PATH": "/tmp/.mount_nrfcon8vzoJN:/tmp/.mount_nrfcon8vzoJN/usr/sbin:/home/ephimee/.local/bin:/home/ephimee/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin",
          "USER": "ephimee"
        },
        "toolchainPath": "/home/ephimee/ncs2/toolchains/v2.2.0",
        "toolchainBinPath": "/home/ephimee/ncs2/toolchains/v2.2.0/opt/zephyr-sdk/arm-zephyr-eabi/bin",
        "toolchainVersion": "2.2.0"
      },
      "terminal": {
        "shell": null,
        "defaultProfile": null
      }
    }
    
    
    

  • Hi Philip,

    When you open VSCode, do you get any pop up questions?

    -Priyanka

  • in the right bottom corner I get suggestions about plugins like CMake Tools and C/C++ Extension Pack

Reply Children
Related