Aerostack2

DocsPlugins

Overview

Every plugin that ships with Aerostack2, what each one does and how to pick one.

Authored by
  • @alvgaona

Many Aerostack2 components do their work through a plugin, loaded when the component starts. The component handles its ROS 2 interface, and the plugin holds the algorithm, so swapping a controller or a planner is a change of one parameter. Most components choose theirs with plugin_name.

ComponentPlugins
Motion controllerpid_speed_controller, differential_flatness_controller, geometric_controller
State estimatorground_truth, raw_odometry, simple_ekf
Motion behaviorsPosition and trajectory plugins for every motion behavior, plus speed and platform plugins for take off and land
Trajectory generatordynamic_mav_trajectory_generator, mav_trajectory_generator, gcopter_trajectory_generator, jerk_limited_trajectory_generator
Path planninga_star, voronoi
Map serverscan2occ_grid, depth2occ_grid, point_cloud2occ_grid
Grippertwo_fingers, dc_servo
Object perceptionaruco

Common setups

Which controller to use depends on the commands the platform accepts:

Controller sendsControllerPlatforms that accept it
Velocitiespid_speed_controllerGazebo, Crazyflie, Tello, DJI, PX4, MAVLink and the multirotor simulator
Body rates and thrustdifferential_flatness_controller or geometric_controllerBetaflight, PX4, MAVLink, the multirotor simulator, and Gazebo with its body rates control modes file

Differential flatness only takes trajectories, so pair it with the trajectory plugins of the motion behaviors and a trajectory generator. The PID speed and geometric controllers also take position references, so the position plugins work with them.

The state estimator depends on where the drone's position comes from. See choosing a plugin.

Plugins

Writing a plugin

A plugin is a class that inherits from its component's base class, exported with pluginlib. The guides walk through a controller plugin, an estimator plugin and a follow reference plugin.

Last updated on November 3, 2026

On this page

Last updated on November 3, 2026