Home

Awesome

Build Status

WARNING: This repository is deprecated. Please use the Crazyswarm instead, even when only operating a single Crazyflie. If you are missing features in the Crazyswarm, feel free to open an open issue.

crazyflie_ros

ROS stack for Bitcraze Crazyflie (http://www.bitcraze.se/), with the following features:

A tutorial (for a slightly older version) is available in W. Hönig and N. Ayanian. "Flying Multiple UAVs Using ROS", Chapter in Robot Operating System (ROS): The Complete Reference (Volume 2), Springer, 2017. (see http://act.usc.edu/publications.html for a free pre-print).

Citing This Work

This project is published under the very permissive MIT License. However, if you use the package we appreciate if you credit this project accordingly.

For academic publications, you can cite the following book chapter:

@Inbook{crazyflieROS,
  author={Wolfgang H{\"o}nig
          and Nora Ayanian},
  editor={Anis Koubaa},
  title={Flying Multiple UAVs Using ROS},
  bookTitle={Robot Operating System (ROS): The Complete Reference  (Volume 2)},
  year={2017},
  publisher={Springer International Publishing},
  pages={83--118},
  isbn={978-3-319-54927-9},
  doi={10.1007/978-3-319-54927-9_3},
  url={https://doi.org/10.1007/978-3-319-54927-9_3}
}

If your work is related to Mixed Reality, you might cite the paper which introduced the package instead, using the following bibtex entry:

@conference{HoenigMixedReality2015,
  author = {Wolfgang H{\"o}nig and Christina Milanes and Lisa Scaria and Thai Phan and Mark Bolas and Nora Ayanian},
  booktitle = {IEEE/RSJ Intl Conf. Intelligent Robots and Systems},
  pages = {5382 - 5387},
  title = {Mixed Reality for Robotics},
  year = {2015}}

For any other mentioning please include my affiliation (ACTLab at University of Southern California or USC in short; The link to our webpage is http://act.usc.edu) as this work was partially done as part of my research at USC.

Installation

Clone the package into your catkin workspace:

git clone https://github.com/whoenig/crazyflie_ros.git
cd crazyflie_ros
git submodule init
git submodule update

Use catkin_make on your workspace to compile.

Usage

There are six packages included: crazyflie_cpp, crazyflie_driver, crazyflie_tools, crazyflie_description, crazyflie_controller, and crazyflie_demo. Note that the below description might be slightly out-of-date, as we continue merging the Crazyswarm and crazyflie_ros.

Crazyflie_Cpp

This package contains a cpp library for the Crazyradio and Crazyflie. It can be used independently of ROS.

Crazyflie_driver

This package contains the driver. In order to support multiple Crazyflies with a single Crazyradio, there is crazyflie_server (communicating with all Crazyflies) and crazyflie_add to dynamically add Crazyflies. The server does not communicate to any Crazyflie initially, hence crazyflie_add needs to be used.

Crazyflie_tools

This package contains tools which are helpful, but not required for normal operation. So far, it just support one tool for scanning for a Crazyflie.

You can find connected Crazyflies using:

rosrun crazyflie_tools scan

Crazyflie_description

This package contains a 3D model of the Crazyflie (1.0). This is for visualization purposes in rviz.

Crazyflie_controller

This package contains a simple PID controller for hovering or waypoint navigation. It can be used with external motion capture systems, such as VICON.

Crazyflie_demo

This package contains a rich set of examples to get quickly started with the Crazyflie.

For teleoperation using a joystick, use:

roslaunch crazyflie_demo teleop_xbox360.launch uri:=radio://0/100/2M

where the uri specifies the uri of your Crazyflie. You can find valid uris using the scan command in the crazyflie_tools package.

For hovering at (0,0,1) using VICON, use:

roslaunch crazyflie_demo hover_vicon.launch uri:=radio://0/100/2M frame:=/vicon/crazyflie/crazyflie x:=0 y:=0 z:=1

where the uri specifies the uri of your Crazyflie and frame the tf-frame. The launch file runs vicon_bridge automatically.

For multiple Crazyflies make sure that all Crazyflies have a different address. Crazyflies which share a dongle should use the same channel and datarate for best performance. The performance degrades with the number of Crazyflies per dongle due to bandwidth limitations, however it was tested successfully to use 3 CFs per Crazyradio.

roslaunch crazyflie_demo multi_teleop_xbox360.launch uri1:=radio://0/100/2M/E7E7E7E7E7 uri2:=radio://0/100/2M/E7E7E7E705

Please check the launch files in the crazyflie_demo package for other examples, including simple waypoint navigation.

ROS Features

Parameters

The launch file supports the following arguments:

See http://wiki.bitcraze.se/projects:crazyflie:userguide:tips_and_tricks for details on how to obtain good trim values.

Subscribers

cmd_vel

Similar to the hector_quadrotor, package the fields are used as following:

Publishers

imu

temperature

magnetic_field

pressure

battery

Similar Projects

Notes