JetsonHacks

Developing on NVIDIA® Jetson™ for AI on the Edge

Visual Studio Code

Microsoft now supports ARM 64 machines like the NVIDIA Jetsons and Raspberry Pi within Visual Studio Code. Looky here:

Background

Last year we did an article on installing Visual Studio Code using a community build. While this is great, Microsoft now supports ARM 64 builds directly. In addition in the newest release, Microsoft also adds the C/C++ programming extensions for ARM/ARM64!

Visual Studio Code is probably the most popular programming tool on the planet, and for good reason. It’s free, and supports a very large ecosystem of programming languages and extensions. While aimed at web and cloud development, most people find that other development tasks are easier too.

Installation

One easy way to install Visual Studio Code is to go to the Visual Studio Code site, download the .deb for ARM 64, and install it. Just remember to find the ‘Other platforms’ link to take you to the place to download the ARM 64 version. Many of the buttons labelled ‘Download’ download the x86 version of Visual Studio Code (this is for a PC), make sure you find the ARM 64 version (see the video if you need a better description).

There is great documentation for both installing Visual Studio Code and getting started. This includes video tutorials and a large number of articles for use. Certainly a page worth checking out.

The ARM 64 version runs on the NVIDIA Jetson Nano 2GB, Jetson Nano, Jetson AGX Xavier, Jetson Xavier NX, Jetson TX1 and Jetson TX2. The Jetson TK1 requires the ‘ARM’ version (32 bit), though we have not tested the Jetson TK1 with Visual Studio Code.

If you are looking to script the installation, on the JetsonHacksNano account on Github, there is a repository installVSCode. There are two scripts. The first script, installVSCode.sh, will simply download Visual Studio Code and install it. The second script, installVSCodeWithPython.sh, will download Visual Studio Code, install it, and then download and install the Microsoft Python extension, along with some Python support libraries.

To clone the repository and install VSCode:

$ git clone https://github.com/JetsonHacksNano/installVSCode.git
$ cd installVSCode
$ ./installVSCode.sh

To clone the repository and install VSCode with Python support:

$ git clone https://github.com/JetsonHacksNano/installVSCode.git
$ cd installVSCode
$ ./installVSCodeWithPython.sh

Modify the scripts to suit your development needs. In particular, the Python install script gives an example on how to install an extension from the command line:

$ code –install-extension ms-python.python –force

The name of the extension can be found by looking up the extension in the extension manager of Code.

Conclusion

If you program a lot on your Jetson, Visual Studio Code is worth checking out. This is especially true if you use different languages, as you can hop back and forth between them and maintain the same programming development environment.

Facebook
Twitter
LinkedIn
Reddit
Email
Print

12 Responses

  1. Hello Jim, so I have a problem facing me with my Jetson nano 2gb, put in note that I don’t know much about single board computers and AI. So what I’m currently facing is that when I updated my jetson nano(well I don’t know if that was a jetson nano update or if it was an ubuntu update, but it had me checking all the files and when it finished it asked me to restart)after I restarted the nano It just showed the nvidia logo and it didn’t boot, please if you know what is wrong let me know, and thanks for reading this whole article BTW, I mean if you did?.

  2. I am having troubles getting VS Code downloaded onto my jetson, which is running Ubuntu 18.04. It seems to be a problem with my packages:

    The following packages have unmet dependencies:
    code : Depends: libc6 (>= 2.28) but 2.27-3ubuntu1.6 is to be installed
    Depends: libgssapi-krb5-2 (>= 1.17) but 1.16-2ubuntu0.4 is to be installed
    Depends: libxkbfile1 (>= 1:1.1.0) but 1:1.0.9-2 is to be installed
    E: Unable to correct problems, you have held broken packages.

    I am new to the jetson and having trouble updating the packages / troubleshooting this problem.

    1. I had the same issues in February 2024 using Jetson Nano Jetpack 4.6.4
      Installation is no longer possible.
      I could only connect via SSH from Windows Host Computer.

      I found this from Microsoft VS:

      Can I run VS Code on older Linux distributions?

      Starting with VS Code release 1.86.1 (January 2024), VS Code desktop is only compatible with Linux distributions based on glibc 2.28 or later, for example, Debian 10, RHEL 8, or Ubuntu 20.04. VS Code will still allow users to connect to an OS that is not supported by VS Code (OS that does not provide glibc >= 2.28 and libstdc++ >= 3.4.25) until February 2025. This allows time for you and your companies to migrate to newer Linux distributions. VS Code will show a dialog and banner message when you connect to an OS version that is not supported by VS Code

  3. Hello,

    i was not able to install VS Code on my Jetson Nano with Jetpack 4.6.4 in February 2024.
    For all of you facing the same problems, i found this:

    https://code.visualstudio.com/docs/supporting/faq#_can-i-run-vs-code-on-older-linux-distributions

    Starting with VS Code release 1.86.1 (January 2024), VS Code desktop is only compatible with Linux distributions based on glibc 2.28 or later, for example, Debian 10, RHEL 8, or Ubuntu 20.04. VS Code will still allow users to connect to an OS that is not supported by VS Code (OS that does not provide glibc >= 2.28 and libstdc++ >= 3.4.25) until February 2025. This allows time for you and your companies to migrate to newer Linux distributions. VS Code will show a dialog and banner message when you connect to an OS version that is not supported by VS Code.

    I could still connect via SSH but an install is no longer possible

Leave a Reply

Your email address will not be published. Required fields are marked *

Disclaimer

Some links here are affiliate links. If you purchase through these links I will receive a small commission at no additional cost to you. As an Amazon Associate, I earn from qualifying purchases.

Books, Ideas & Other Curiosities