|
| 1 | +# Control Launch Files |
| 2 | + |
| 3 | +## Overview |
| 4 | + |
| 5 | +The Autoware control stacks start |
| 6 | +launching at `autoware_launch.xml` as mentioned on the [Launch Autoware](../index.md) page. |
| 7 | +The `autoware_launch` package includes `tier4_control_component.launch.xml` |
| 8 | +for initiating control launch files invocation from `autoware_launch.xml`. |
| 9 | +The diagram below illustrates the flow of Autoware control launch files within the autoware_launch and autoware.universe packages. |
| 10 | + |
| 11 | +<figure markdown> |
| 12 | + { align=center } |
| 13 | + <figcaption> |
| 14 | + Autoware control launch flow diagram |
| 15 | + </figcaption> |
| 16 | +</figure> |
| 17 | + |
| 18 | +!!! note |
| 19 | + |
| 20 | + The Autoware project is a large project. |
| 21 | + Therefore, as we manage the Autoware project, we utilize specific |
| 22 | + arguments in the launch files. |
| 23 | + ROS 2 offers an argument-overriding feature for these launch files. |
| 24 | + Please refer to [the official ROS 2 launch documentation](https://docs.ros.org/en/humble/Tutorials/Intermediate/Launch/Using-ROS2-Launch-For-Large-Projects.html#parameter-overrides) for further information. |
| 25 | + For instance, |
| 26 | + if we define an argument at the top-level launch, |
| 27 | + it will override the value on lower-level launches. |
| 28 | + |
| 29 | +## tier4_control_component.launch.xml |
| 30 | + |
| 31 | +The tier4_control_component.launch.xml launch file is the main control component launch in the autoware_launch package. |
| 32 | +This launch file calls control.launch.xml from the [tier4_control_launch](https://github.com/autowarefoundation/autoware.universe/tree/main/launch/tier4_control_launch) package |
| 33 | +within the autoware.universe repository. |
| 34 | +We can modify control launch arguments in tier4_control_component.launch.xml. |
| 35 | +Additionally, |
| 36 | +we can add any other necessary arguments |
| 37 | +that need adjustment since tier4_control_component.launch.xml serves as the top-level launch file for other control launch files. |
| 38 | +Here are some predefined control launch arguments: |
| 39 | + |
| 40 | +- **`lateral_controller_mode:`** This argument determines |
| 41 | + the lateral controller algorithm. |
| 42 | + The default value is `mpc`. |
| 43 | + To change it to pure pursuit, |
| 44 | + make the following update in your `tier4_control_component.launch.xml` file: |
| 45 | + |
| 46 | + ```diff |
| 47 | + - <arg name="lateral_controller_mode" default="mpc"/> |
| 48 | + + <arg name="lateral_controller_mode" default="pure_pursuit"/> |
| 49 | + ``` |
| 50 | + |
| 51 | +- **`enable_autonomous_emergency_braking:`** This argument enables autonomous emergency |
| 52 | + braking under specific conditions. |
| 53 | + Please refer to the [Autonomous emergency braking (AEB)](https://autowarefoundation.github.io/autoware.universe/main/control/autonomous_emergency_braking/) page for |
| 54 | + more information. |
| 55 | + To enable it, update the value in the `tier4_control_component.launch.xml` file: |
| 56 | + |
| 57 | + ```diff |
| 58 | + - <arg name="enable_autonomous_emergency_braking" default="false"/> |
| 59 | + + <arg name="enable_autonomous_emergency_braking" default="true"/> |
| 60 | + ``` |
| 61 | + |
| 62 | +- **`enable_predicted_path_checker:`** This argument enables the predicted path checker module. |
| 63 | + Please refer to the [Predicted Path Checker](https://autowarefoundation.github.io/autoware.universe/main/control/predicted_path_checker/) page for |
| 64 | + more information. |
| 65 | + To enable it, update the value in the `tier4_control_component.launch.xml` file: |
| 66 | + |
| 67 | + ```diff |
| 68 | + - <arg name="enable_predicted_path_checker" default="false"/> |
| 69 | + + <arg name="enable_predicted_path_checker" default="true"/> |
| 70 | + ``` |
| 71 | + |
| 72 | +!!! note |
| 73 | + |
| 74 | + You can also use this arguments as command line arguments: |
| 75 | + ```bash |
| 76 | + ros2 launch autoware_launch autoware.launch.xml ... enable_predicted_path_checker:=true lateral_controller_mode:=pure_pursuit ... |
| 77 | + ``` |
| 78 | + |
| 79 | +The predefined arguments in tier4_control_component.launch.xml have been explained above. |
| 80 | +However, numerous control arguments are included in the autoware_launch control config parameters. |
0 commit comments