Part2 Practice

4. Setting Up the Application Development Environment 📱🚗

4-1. Introduction

In this chapter, we will set up the development environment required to smoothly follow the tutorial.

The overall structure of the tutorial environment is shown in the diagram below.

In this tutorial, you will launch a development container on Ubuntu running on Windows Subsystem for Linux 2 (WSL2), then connect to the container from VS Code via the Dev Containers extension. From there, you will perform coding, building, and running the application.

yoriito_tutorial_env

Info

Depending on your network environment, some download/installation steps may fail. If the process does not proceed or times out partway through, please check your network settings.

The recommended operating environment is as follows:

  • OS: Windows 11
  • Virtualization: WSL2
  • Linux distribution: Ubuntu 24.04 LTS (on WSL2)

4-3. Prerequisites

  1. Please install the following on Windows 11.

  2. Please install the following on Ubuntu.

    • Git
    • Docker
  3. Please install the following extension in VS Code.

4-4. Clone the Repository

  1. Open an Ubuntu terminal.

  2. Clone the sample application repository.

    $ git clone https://github.com/yoriito/yoriito-tutorial.git
    
  3. Fetch submodules.

    $ cd yoriito-tutorial
    $ git submodule init
    $ git submodule update
    

4-5. Start the Container

Yoriito repositories typically support dev containers. In this section, you will set up the environment using a dev container.

  1. In the target repository's root directory, start VS Code:

    $ code .
    
  2. After VS Code starts, open the Command Palette with Ctrl + Shift + P.

  3. Type Dev Containers: Rebuild and select "Dev Containers: Rebuild and Reopen in Container".

  4. The container will be built and various libraries will be installed.

Info

A video is also available as a reference.

4-6. Start the Simulator

This section explains how to start the simulator, which allows you to simulate actual vehicle behavior throughout the tutorial.

  1. Move to the ref_pal directory.

    $ cd /work/ref_pal
    
  2. Run the following commands.

    $ npm install
    $ ./init_pal.sh
    $ npx electron . --no-sandbox
    

Info

./init_pal.sh takes about 3–5 minutes to complete.