Skip to content

Visual Studio Code (VSCode)

VSCode provides two important features. First, AI integration through extensions like GitHub Copilot can assist you in writing code faster and with fewer errors. Second, VSCode has built-in support for remote development, allowing you to connect to and work directly on your car's ROS 2 workspace over SSH.

The reccommended way to use VSCode with the Autonomous Driving Platform is to install it on your local machine and use the Remote - SSH extension to connect to the car's Jetson Orin Nano. This setup allows you to edit files, run commands, and debug code directly on the car while leveraging the powerful features of VSCode.

Once you've configured ssh, follow these steps to set up VSCode for remote development:

  1. Install VSCode: Download and install Visual Studio Code from the official website.

  2. Install the Remote - SSH Extension:

  3. Open VSCode.
  4. Go to the Extensions view by clicking on the Extensions icon in the Activity Bar on the side of the window.
  5. Search for "SSH", pick "Remote - SSH" and click "Install".

  6. Connect to the Car:

  7. Press F1 to open the Command Palette.
  8. Type Remote-SSH: Connect to Host... and select it.
  9. Enter the SSH connection string for your car (e.g., orin12).
  10. VSCode will open a new window connected to the car.

  11. Open the ROS 2 Workspace:

  12. When the remote window opens, the command palette will prompt you to open a folder.
  13. Navigate to and select your ROS 2 workspace directory (e.g., /home/orin/roboracer_ws).

  14. Code

    • You can now edit files, run terminal commands, and debug code directly on the car.
    • Use the integrated terminal in VSCode to run ROS 2 commands and launch files as needed.

Be sure to commit your code regularly to your GitHub repository to keep your work backed up and synchronized with your team.