10. Quick Start for Renesas RH850

10.1. Supported Environments

Operating System

Windows: Windows 10 / Windows 11

Linux: Ubuntu 22.04 / Ubuntu 24.04

VS Code version

1.102.0 (minimum)

VS Code can be downloaded and installed from this page https://code.visualstudio.com/.

10.2. Installation

Please choose your operating system for operating system dependent installation steps.

For the Renesas RH850 Family, Renesas Platform provides a straightforward installation wizard to install the CMake, Ninja, Python and the Support Files for RH850 Family. To set up your environment:

  1. Open VS Code.

  2. Navigate to the “Renesas” tab in VS Code. Then, click “Renesas Quick Install” in the “Environment” view.

    _images/renesas-quick-install.png
  3. Click the “Install” button for the “Renesas RH850” device family. The Renesas Platform will now check the dependencies required by the Renesas RH850 Device Family. The Renesas Platform extension will check the local environment and CMake, Ninja, Python and the Support Files for RH850 Family, then create an installation plan for them if necessary.

    _images/rh850-install.png
  4. When your selection is ready, click the “Start Installations” button. The download and installation process will start automatically.

    _images/rh850-start-installation.png

Installing the latest RH850 Smart Configurator (RH850 SC):

For RH850 projects, it is recommended to download and install the latest RH850 Smart Configurator.

  • https://www.renesas.com/en/software-tool/rh850-smart-configurator#downloads

    Note

    The Renesas Platform extension scans for changes at start-up, thus, after installing the Renesas RH850 Smart Configurator, please restart VS Code to force Renesas Platform to detect the recent RH850 Smart Configurator installation.

    You can click “Manage Smart Configurators” to check the detected Smart Configurators. If it is not automatically detected, you can use the “Register SC” button to register the Smart Configurator manually by selecting the path of the Smart Configurator.

    _images/rh850-sc.png

Installing “CC-RH” toolchains for RH850 Project Build:

For RH850 projects, it is recommended to install “CC-RH” toolchain. For installing “CC-RH”:

  1. Download and install the latest toolchain:

    https://www.renesas.com/us/en/software-tool/c-compiler-package-rh850-family

  2. Add the bin folder of the toolchain as “RENESAS_CCRH_TOOLCHAIN_PATH” to the environment variables.

    Configuring RENESAS_CCRH_TOOLCHAIN_PATH environment variable
    1. Use Window search to find and open “Edit the system environment variables

      _images/edit-env-vars-button.png
    2. In “Advanced” tab, click on “Environment Variables…” button to open “Environment Variables” dialog

    3. Click to “New…”.

      _images/add-new-sys-env-vars.png
    4. Enter the “RENESAS_CCRH_TOOLCHAIN_PATH” to the Variable name field, and click to “Browse Directory…” to select the bin folder of the toolchain. Then click “OK”.

      _images/installation-env-variables-ccrh.png

Installing Additional Emulator Drivers

You may need to download and install additional USB drivers for establishing a connection with the emulators and devices. Please install the latest drivers before starting your debug session. Use the following links to download the drivers suitable for your operating system and device:

For the Renesas RH850 Family, Renesas Platform provides a straightforward installation wizard to install the CMake, Ninja, Python and the Support Files for RH850 Family. To set up your environment:

  1. Open VS Code.

  2. Navigate to the “Renesas” tab in VS Code. Then, click “Renesas Quick Install” in the “Environment” view.

    _images/renesas-quick-install.png
  3. Click the “Install” button for the “Renesas RH850” device family. The Renesas Platform will now check the dependencies required by the Renesas RH850 Device Family. The Renesas Platform extension will check the local environment and CMake, Ninja, Python and the Support Files for RH850 Family, then create an installation plan for them if necessary.

    _images/rh850-install.png
  4. When your selection is ready, click the “Start Installations” button. The download and installation process will start automatically.

    _images/rh850-start-installation.png

Most of the installations will be performed automatically, some installations may require manual interaction.

  • During the “Python 3.10” installation, the terminal wizard will appear for manual interaction. The terminal will show the execution plan and ask for confirmation before continuing. During the installation, it requires administrative rights to execute the installation, thus a password could be needed during the installation. Please make sure that the current user has “sudo” permissions and enter the password.

    _images/common-installation-terminal-attention.png

Installing “CC-RH” toolchains for RH850 Project Build:

For RH850 projects, it is recommended to install “CC-RH” toolchain. For installing “CC-RH”:

  1. Download and install the latest toolchain:

    https://www.renesas.com/us/en/software-tool/c-compiler-package-rh850-family

Installing Additional Emulator Drivers

You may need to download and install additional USB drivers for establishing a connection with the emulators and devices. Please install the latest drivers before starting your debug session. Use the following links to download the drivers suitable for your operating system and device:

For the Renesas RH850 Family, Renesas Platform provides a straightforward installation wizard to install the CMake, Ninja, Python and the Support Files for RH850 Family. To set up your environment:

  1. Open VS Code.

  2. Navigate to the “Renesas” tab in VS Code. Then, click “Renesas Quick Install” in the “Environment” view.

    _images/renesas-quick-install.png
  3. Click the “Install” button for the “Renesas RH850” device family. The Renesas Platform will now check the dependencies required by the Renesas RH850 Device Family. The Renesas Platform extension will check the local environment and CMake, Ninja, Python and the Support Files for RH850 Family, then create an installation plan for them if necessary.

    _images/rh850-install.png
  4. When your selection is ready, click the “Start Installations” button. The download and installation process will start automatically.

    _images/rh850-start-installation.png

Most of the installations will be performed automatically, some installations may require manual interaction.

  • During the “Python 3.10” installation, the terminal wizard will appear for manual interaction. The terminal will show the execution plan and ask for confirmation before continuing. During the installation, it requires administrative rights to execute the installation, thus a password could be needed during the installation. Please make sure that the current user has “sudo” permissions and enter the password.

    _images/common-installation-terminal-attention.png

Installing “CC-RH” toolchains for RH850 Project Build:

For RH850 projects, it is recommended to install “CC-RH” toolchain. For installing “CC-RH”:

  1. Download and install the latest toolchain:

    https://www.renesas.com/us/en/software-tool/c-compiler-package-rh850-family

Installing Additional Emulator Drivers

You may need to download and install additional USB drivers for establishing a connection with the emulators and devices. Please install the latest drivers before starting your debug session. Use the following links to download the drivers suitable for your operating system and device:

10.3. Creating a Project

For RH850 device family projects, Smart Configurator can be accessed via the “Create Project” view in the “Renesas” tab. Please use the following instructions to create and build a project for RH850 device family.

  1. Navigate to “Renesas” and click [Create Renesas RH850 project] from the commands.

    _images/create-project.png
  2. Select [Create RH850 Project with Smart Configurator] option from the list.

    _images/pick-method.png
  3. Then, VSCode will show installed [RH850 Smart Configurator] list, select a [Smart Configurator] from the list.

    _images/pick-sc.png
  4. Select a [Folder] to create the project.

    _images/pick-folder.png
  5. Enter [File name], configure your board and device type, select [Renesas CCRH850 Toolchain], and then click [Next].

    _images/sc-step1.png
  6. Choose the [RTOS] configuration and continue by clicking [Next] (Continue with “No RTOS” for the sample project).

    _images/sc-step2.png
  7. Click [Generate Code] and close [RH850 Smart Configurator] after generation of the project files completes.

    _images/sc-step3.png

10.4. Building the Project

For building a project, which has been created with RH850 Smart Configurator, please follow the steps below:

  1. In the VS Code Command Palette, run the “CMake: Delete Cache and Reconfigure” command.

    _images/delete_cache_and_reconfigure.png
  2. In the first time of running, a kit selection is shown. Select “[Unspecified]”.

    _images/select_unspecified_kit.png
  3. In VS Code, click [Terminal] ⇒ [Run Build Task] from the menu. Alternatively, press ctrl+shift+B to quickly open the Build task.

    _images/sc_run_build_task.png
  4. Select [Build Project] from the commands.

    _images/run-build-project-task.png

TIP: For more information about RH850 Smart Configurator, click here to visit the RH850 Smart Configurator page.

10.5. Debugging the Project

A debug session can be started by selecting the created configuration and clicking the [Start Debugging] button in the [Run and Debug] tab, or pressing [F5] from the keyboard.

_images/vscode-debug-start5.png

When VS Code starts the debug session, common debug control flow functions like resume, suspend, step into, step over, step out, restart, terminate debug session can be performed via the debug flow control buttons. Also, the [Debug Console] view will contain useful messages during the debug session.

_images/vscode-debug-start6.png

During the debug session, details about the local variables, device registers, call stack, watched variables, states of the peripherals can be accessed at the primary sidebar of VS Code in the [Run and Debug] tab.

_images/vscode-debug-start7.png