Skip to content
Snippets Groups Projects
Commit 8e739755 authored by Fernando Herrero's avatar Fernando Herrero
Browse files

Update doc/nav_nomap.md, doc/nav_mapping.md, doc/nav_map.md files

parent 2acbdceb
No related branches found
No related tags found
No related merge requests found
# Navigation in a map
Use ROS move_base node to make the platform move in a built map.
* Run the simulation of the model car in a world with some objects:
```bash
roslaunch iri_model_car_gazebo sim.launch standalone:=false world:=objects
```
* Run the navigation algorithms. Here we are loading an already build map of the world `objects`.
```bash
roslaunch iri_model_car_rosnav nav_map.launch map_path:=`rospack find iri_model_car_rosnav`/maps map_name:=objects
```
* Run rviz
```bash
rviz -d `rospack find iri_model_car_rosnav`/rviz/model_car_nav_map.launch
```
* On Rviz
* use the '2d Nav Goal' tool (shortcut 'g') and click-drag somewhere inside the map to send a goal
* The global planner will compute the path to reach the goal (blue line)
* The model car will start following this path until reachin the goal.
# Creating a map
Use SLAM/Gmapping to create an occupancy grid map.
* Run the simulation of the model car in a world with some objects:
```bash
roslaunch iri_model_car_gazebo sim.launch standalone:=false world:=objects
```
* Run the mapping algorithms:
```bash
roslaunch iri_model_car_rosnav nav_mapping.launch
```
* Run rviz
```bash
rviz -d `rospack find iri_model_car_rosnav`/rviz/model_car_nav_gmapping.launch
```
* Move the model car around with teleoperation node or sending navigation goals.
* `roslaunch iri_model_car_launch teleop_rqt.launch`
* On Rviz use the '2d Nav Goal' tool (shortcut 'g') and click-drag somewhere to send a goal
* Map will be updated and showed in rviz as an image with:
* Free space as white cells
* Obstacles as black cells
* Unknown space as grey cells
* When done building the map, save it somewhere giving it a name:
```
roscd iri_model_car_rosnav/maps
rosrun map_server map_saver map:=model_car/map -f my_map_name
```
* Two files, my_map_name.pgm with the image and my_map_name.yaml with some parameters will be saved.
# Navigation without a map
Use ROS move_base node to make the platform move without a built map.
* Run the simulation of the model car in a world with some objects:
```bash
roslaunch iri_model_car_gazebo sim.launch world:=objects
```
* Run the navigation algorithms:
```bash
roslaunch iri_model_car_rosnav nav_no_map.launch
```
* Run rviz
```bash
rviz -d `rospack find iri_model_car_rosnav`/rviz/model_car_nav_no_map.launch
```
* On Rviz
* use the '2d Nav Goal' tool (shortcut 'g') and click-drag somewhere inside the global costmap to send a goal
* The global planner will compute the path to reach the goal (blue line)
* The model car will start following the path until reaching the goal.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment