Skip to content
This repository was archived by the owner on Mar 17, 2021. It is now read-only.
Prev Previous commit
Next Next commit
Move ROS simulation doc into ROS docs and cross link from gazebo docs
  • Loading branch information
hamishwillee committed Dec 19, 2017
commit 108d2cea39e7c4e6ca20729211c20fe4e48e6179
2 changes: 1 addition & 1 deletion en/SUMMARY.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
* [AirSim Simulation](simulation/airsim.md)
* [Multi-Vehicle Simulation](simulation/multi-vehicle-simulation.md)
* [HITL Simulation](simulation/hitl.md)
* [Interfacing to ROS](simulation/ros_interface.md)
* [Hardware](hardware/README.md)
* [Autopilot Hardware](flight_controller/README.md)
* [Porting Guide](debug/porting-guide.md)
Expand Down Expand Up @@ -70,6 +69,7 @@
* [ROS](ros/README.md)
* [MAVROS \(MAVLink on ROS\)](ros/mavros_installation.md)
* [MAVROS offboard example](ros/mavros_offboard.md)
* [ROS with Gazebo Simulation](simulation/ros_interface.md)
* [ROS Installation on RPi](ros/raspberrypi_installation.md)
* [External Position Estimation](ros/external_position_estimation.md)
* [Gazebo Octomap](simulation/gazebo_octomap.md)
Expand Down
7 changes: 3 additions & 4 deletions en/simulation/gazebo.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Gazebo Simulation

[Gazebo](http://gazebosim.org) is a powerful 3D simulation environment for autonomous robots that is particularly suitable for testing object-avoidance and computer vision. It can also be used for [multi-vehicle simulation](../simulation/multi-vehicle-simulation.md) and is commonly used with [ROS](../simulation/ros_interface.md), a collection of tools for automating vehicle control.
[Gazebo](http://gazebosim.org) is a powerful 3D simulation environment for autonomous robots that is particularly suitable for testing object-avoidance and computer vision. It can also be used for [multi-vehicle simulation](../simulation/multi-vehicle-simulation.md).

**Supported Vehicles:** Quad ([Iris](../airframes/airframe_reference.md#copter_quadrotor_wide_3dr_iris_quadrotor) and [Solo](../airframes/airframe_reference.md#copter_quadrotor_x_3dr_solo), Hex (Typhoon H480), [Generic quad delta VTOL](../airframes/airframe_reference.md#vtol_standard_vtol_generic_quad_delta_vtol), Tailsitter, Plane, Rover, Submarine (coming soon!)

> **Tip** See [Simulation](/simulation/README.md) for general information about simulators, the simulation environment and available simulation configuration (e.g. supported vehicles).
> **Tip** Gazebo is often used with [ROS](../ros/README.md), a toolkit/offboard API for automating vehicle control. If you plan to use PX4 with ROS you should instead [follow the instructions here](../simulation/ros_interface.md) to install Gazebo as part of ROS!

{% youtube %}https://www.youtube.com/watch?v=qfFF9-0k4KA&vq=hd720{% endyoutube %}

Expand All @@ -16,12 +16,11 @@ graph LR;
MAVLink-->SITL;
{% endmermaid %}

> **Note** See [Simulation](/simulation/README.md) for general information about simulators, the simulation environment and available simulation configuration (e.g. supported vehicles).


## Installation

> **Tip** If you plan to use PX4 with ROS you should instead [follow the instructions here](../simulation/ros_interface.md) to install Gazebo as part of ROS! Note that we install Gazebo7 with ROS, as this is the default compatible version.

Gazebo 8 setup in included in our standard build instructions:
- **macOS:** [Development Environment on Mac](http://localhost:4000/en/setup/dev_env_mac.html)
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@TSC21 Does macOS installer also include ROS Kinetic? If so, does it install Gazebo 7 (the default) or Gazebo 8 (preferred).

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note also that I've dropped the mention of gazebo 6. We prefer gazebo 8 as standalone and for ROS we use whatever it default to.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't actually confirm that since I don't have a Mac...

- **Linux:** [Development Environment on Linux > jMAVSim/Gazebo Simulation](../setup/dev_env_linux.md#jmavsimgazebo-simulation)
Expand Down
8 changes: 4 additions & 4 deletions en/simulation/ros_interface.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# Interfacing the Simulation to ROS
# ROS with Gazebo Simulation

[ROS](../ros/README.md) (Robot Operating System) is a general purpose robotics library that can be used with the PX4 flight stack and also (optionally) with the Gazebo simulator. It uses the [MAVROS](../ros/mavros_installation.md) MAVLink node to communicate with PX4.
[ROS](../ros/README.md) (Robot Operating System) can be used with the PX4 flight stack and the Gazebo simulator. It uses the [MAVROS](../ros/mavros_installation.md) MAVLink node to communicate with PX4.

The diagram below shows the *standard* [PX4 simulation environment](../simulation/README.md#sitl-simulation-environment). PX4 communicates with the simulator (e.g. Gazebo) to receive sensor data from the simulated world and send motor and actuator values. It communicates with the GCS and Offboard API to send telemetry from the simulated environment and receive commands.
The ROS/Gazebo integration with PX4 follows the pattern in the diagram below (this shows the *generic* [PX4 simulation environment](../simulation/README.md#sitl-simulation-environment)). PX4 communicates with the simulator (e.g. Gazebo) to receive sensor data from the simulated world and send motor and actuator values. It communicates with the GCS and an Offboard API (e.g. ROS) to send telemetry from the simulated environment and receive commands.

![PX4 SITL overview](../../assets/simulation/px4_sitl_overview.png)

The ROS/Gazebo integration with PX4 follows the pattern above. The only *slight* difference being that ROS initiates the connection on port 14557, while it is more typical for an offboard API to listen for connections on UDP port 14540.
> **Note** The only *slight* difference to "normal behaviour" is that ROS initiates the connection on port 14557, while it is more typical for an offboard API to listen for connections on UDP port 14540.


## Installing Gazebo for ROS
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated instructions to point to our build scripts, which include everything you need with PX4 in one easy script. Also link to the kinetic instructions for people who want to do in manually.

@TSC21 FYI, this will need an update once I know what happens with macOS standard installer. If the standard installer does not include ROS are there manual instructions that we know will work on macOS?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Again, can't tell since I never tried to install ROS on a Mac.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI, so the simple answer is "we don't support it"

Expand Down