Skip to content

Commit

Permalink
fix(tutorial): fix tutorial for planning simulation with ADAPI (#301)
Browse files Browse the repository at this point in the history
* fix(tutorial): fix tutorial for planning simulation with ADAPI

* delete unused

* fix number

* delete space
  • Loading branch information
h-ohta authored Jan 17, 2023
1 parent 5ee0639 commit 919354b
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 12 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
21 changes: 9 additions & 12 deletions docs/tutorials/ad-hoc-simulation/planning-simulation.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,13 +34,7 @@ ros2 launch autoware_launch planning_simulator.launch.xml map_path:=$HOME/autowa

![after-autoware-launch](images/planning/lane-following/after-autoware-launch.png)

#### 2. Add Autoware State Panel

This panel is useful when running planning simulations. To add the panel, click `Panels -> Add new panel`, select `AutowareStatePanel`, and then click `OK`.

![after-autoware-launch](images/planning/lane-following/open-autoware-state-panel.png)

#### 3. Set an initial pose for the ego vehicle
#### 2. Set an initial pose for the ego vehicle

![set-initial-pose](images/planning/lane-following/set-initial-pose.png)

Expand All @@ -54,24 +48,27 @@ b) In the 3D View pane, click and hold the left-mouse button, and then drag to s

To confirm the direction of the lane, check the arrowheads displayed on the map.

#### 4. Set a goal pose for the ego vehicle
#### 3. Set a goal pose for the ego vehicle

a) Click the `2D Goal Pose` button in the toolbar, or hit the `G` key.

b) In the 3D View pane, click and hold the left-mouse button, and then drag to set the direction for the goal pose. If done correctly, you will see a planned path from initial pose to goal pose.

![set-goal-pose](images/planning/lane-following/set-goal-pose.png)

#### 5. Engage the ego vehicle
#### 4. Start the ego vehicle

Now you can start the ego vehicle driving by clicking the `Engage` button in `AutowareStatePanel`. Alteratively, you can manually engage the vehicle by running the following command:
Now you can start the ego vehicle driving by clicking the `AUTO` button on `OperationMode` in `AutowareStatePanel`.
Alteratively, you can manually start the vehicle by running the following command:

```bash
source ~/autoware/install/setup.bash
ros2 topic pub /autoware/engage autoware_auto_vehicle_msgs/msg/Engage "engage: true" -1
ros2 service call /api/operation_mode/change_to_autonomous autoware_adapi_v1_msgs/srv/ChangeOperationMode {}
```

![start-driving](images/planning/lane-following/engage-and-start-planning.png)
After that, you can see `AUTONOMOUS` sign on `OperationMode` and `AUTO` button is grayed out.

![start-driving](images/planning/lane-following/start-driving.png)

### Parking scenario

Expand Down

0 comments on commit 919354b

Please sign in to comment.