Remote Visual Studio Code

Install Visual Studio Code on your laptop and add the extension ms-vscode-remote.remote-ssh.  This extension lets you use VSCode on your local machine while connecting to a remote machine over SSH.

Create an ssh key using ssh-keygen on your laptop.  The defaults are fine.  Copy the contents of ~/.ssh/id_rsa.pub to your clipboard then ssh into your Jetson.

While on our Jetson, run touch ~/.authorized_keys and then paste the contents of id_rsa.pub from your laptop into ~/authorized_keys.

In Visual Studio Code, open the Remote Explorer and click add.  This will open a text box for you to tell VSCode which remote computer you wish to connect to.  Use ssh wes-237b@<ip address or hostname> filling in either your Jetson's hostname (can be found on the label on your device) or its IP address.  Hit enter to accept.  It will open another textbox asking you where to store the configuration.  The default option is fine.  Hit enter again to accept.

You may now need to refresh the Remote Explorer panel to see the update.

Hover your mouse over the machine and you will be presented with two icons.  One will open the machine in the current window and the other will open it in a new window.  Open the machine in a new window.

Install the ms-vscode.cpptools-extension-pack while connected to the Jetson.

On the home page of VSCode, while connected to the Jetson, select Open Folder and then navigate to the code you wish to edit.  You will now be able to edit/debug/test as if you are on your local.