Main Content


Submit simulation data to RoadRunner Scenario simulation engine using MATLAB

Since R2024a


    prepareSimulation(rrApp) submits simulation data, such as scenario definition and map definition, to the RoadRunner Scenario simulation engine. This makes the simulation data available to clients, such as MATLAB® or CARLA, without first running the simulation.


    collapse all

    Prepare a simulation in RoadRunner Scenario using MATLAB.

    Create a roadrunner object, specifying the path to an existing project. For example, this code shows the path to a project, on a Windows® machine, located at "C:\RR\MyProject". This code assumes that RoadRunner is installed in the default location, and returns an object, rrApp, that provides functions for performing basic workflow tasks such as opening, closing, and saving scenes and projects.

    rrApp = roadrunner(ProjectFolder="C:\RR\MyProject");

    Open an existing scenario in RoadRunner Scenario by using the openScenario function with the roadrunner object, rrApp, and the filename of the specific scenario that you want to open. This MATLAB code opens the desired scenario in RoadRunner Scenario.

    filename = "TrajectoryCutIn.rrscenario";

    Prepare the simulation by using the prepareSimulation function.


    Input Arguments

    collapse all

    RoadRunner application associated with a project, specified as a roadrunner object. This object provides functions for performing common workflow tasks such as opening, closing, and saving scenes and projects. rrApp provides functions that support importing data from files and exporting scenes to other formats from RoadRunner.

    Version History

    Introduced in R2024a