This section explains how to use ROS/Gazebo simulator as the external simulator for ArduCopter. The main characteristics of the simulation are:
In order to begin it is required to arm. Some of the available features provided are:
These applications publish data in the related ROS topics. It is compatible with ROS Indigo, which is the long time support (LTS) ROS version. This simulation includes the MAVROS (Micro Air Vehicle ROS) package. This package provides a communication driver for various autopilots with MAVLink communication protocol. In addition, it provides UDP MAVLink bridge for the ground control station. Using this protocol ROS can send specific commands to the UAV, which is essentially what this simulator is specialised for. Navigation commands can be sent directly to the flight controller produced by a robotics algorithm via MAVROS.
The step lock mechanism enforces a pause of the Gazebo simulation until it receives the next motor command from Ardupilot. It then steps forward the simulation by 2.5 ms (for the 400 Hz update rate) and sends back new sensor measurements to Ardupilot. Unlike many controller simulations on Gazebo, Ardupilot is the master of the simulation clock.
Many thanks to Alex Buyval for creating the initial Arducopter simulation on Gazebo. Also many thanks to Aurélien Roy and Maxime Lafleur to continue his work. and finally to the whole Ardupilot community!