Skip to content

Implement trajectory tracking controllers for multirotors equipped with the PX4 autopilot by leveraging the features of ROS and MAVROS.

License

Notifications You must be signed in to change notification settings

dsor-isr/Quad_Ctrl_MAVROS

Repository files navigation

Quad_Ctrl_MAVROS

The Quad_Ctrl_MAVROS package offers a testing software environment to efficiently implement trajectory tracking controllers for multirotors equipped with the PX4 autopilot by leveraging the features of ROS and the MAVROS package.

At the current version, the testing software environment allows to control two vehicles simultaneously, while exchanging messages between them. One may extend the functionalities of this software to support a larger number of vehicles, however, bear in mind that further code optimisation may be required.

Main features

  • Load reference trajectories from CSV files
  • Send failsafe commands from an offboard computer in emergency circumstances
  • Set a flying safe zone
  • Synchronise two vehicles in order to start tracking a trajectory simultaneously
  • Log flight data in rosbags and make plots and animations using the MATLAB functions provided

Relay Manoeuvre Arena

Citation

If you find Quad_Ctrl_MAVROS useful in your academic work, please cite the paper below.

Coming soon

Running SITL Simulations in Gazebo Classic

  • At your ROS workspace, clone the PX4 autopilot repository into your 'src' folder and checkout to your desired version, preferably the latest stable release, by using the following commands:
git clone https://github.com/PX4/PX4-Autopilot.git
cd PX4-Autopilot
git checkout <tag>
git submodule update --init --recursive
cd <PX4-Autopilot_clone>
DONT_RUN=1 make px4_sitl_default gazebo-classic
source ~/catkin_ws/devel/setup.bash    # (optional)
source Tools/simulation/gazebo-classic/setup_gazebo.bash $(pwd) $(pwd)/build/px4_sitl_default
export ROS_PACKAGE_PATH=$ROS_PACKAGE_PATH:$(pwd)
export ROS_PACKAGE_PATH=$ROS_PACKAGE_PATH:$(pwd)/Tools/simulation/gazebo-classic/sitl_gazebo-classic
roslaunch px4 mavros_posix_sitl.launch
  • Use the provided launch files for SITL simulations to test your controller (an example of a tracking controller is in src/main):
# OPTION 1: Single vehicle
roslaunch quad_ctrl_mavros quad_ctrl_sitl.launch
# OPTION 2: Multiple vehicles
roslaunch quad_ctrl_mavros multi_quad_ctrl_sitl.launch

Experimental Tests

This package has been successfully tested in an indoor flying arena, which features a motion capture system to obtain estimates of the position and yaw angle of the vehicles involved in the experiments.

  • Use the provided launch files for real-world experiments:
# OPTION 1: Single vehicle
roslaunch quad_ctrl_mavros quad_ctrl.launch
# OPTION 2: Multiple vehicles
roslaunch quad_ctrl_mavros multi_quad_ctrl.launch

Change the ID and fcu_url of each vehicle according to your system.

Licenses

Quad_Ctrl_MAVROS is released under BSD-3 License.

PX4-Autopilot is available as an open-source project under BSD-3 License.

MAVROS is available triple-licensed as an open-source project.

Project Sponsors

  • Dynamical Systems and Ocean Robotics (DSOR) -- a group of the Institute for Systems and Robotics (ISR). ISR is a research unit of the Laboratory of Robotics and Engineering Systems (LARSyS)

  • Instituto Superior Técnico, Universidade de Lisboa

The work of João Pinto was supported by a PhD grant funded by Fundação para a Ciência e Tecnologia (FCT).

About

Implement trajectory tracking controllers for multirotors equipped with the PX4 autopilot by leveraging the features of ROS and MAVROS.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published