This is academic project based on the orb slam 2, ros and augmented reality. Its purpose to fly with drone and find 3D objects which have been hidden in the room.
We have tested the project in Ubuntu 16.04 and Ros Kinetic, but it should be easy to compile in other platforms. A powerful computer (e.g. i7) will ensure real-time performance and provide more stable and accurate results. Drone model is tello dji.
We use Pangolin for visualization and user interface. Dowload and install instructions can be found at: https://github.com/stevenlovegrove/Pangolin.
We use OpenCV to manipulate images and features. Dowload and install instructions can be found at: http://opencv.org. Required at leat 2.4.3. Tested with OpenCV 2.4.11 and OpenCV 3.2.
Required by g2o (see below). Download and install instructions can be found at: http://eigen.tuxfamily.org. Required at least 3.1.0.
We use modified versions of the DBoW2 library to perform place recognition and g2o library to perform non-linear optimizations. Both modified libraries (which are BSD) are included in the Thirdparty folder.
- install ros kinetic from here: http://wiki.ros.org/ROS/Installation
- configure catkin workspace: http://wiki.ros.org/ROS/Tutorials/InstallingandConfiguringROSEnvironment
if you still not created catkin workspace then do:
- source /opt/ros/kinetic/setup.bash
- mkdir -p ~/catkin_ws/src
- cd ~/catkin_ws
- catkin build (or catkin_make)
- source devel/setup.bash
- echo $ROS_PACKAGE_PATH if you see this line /home//catkin_ws/src:/opt/ros/kinetic/share then all is good.
after you've created catkin_ws, do:
- cd ~/catkin_ws/src
- git clone https://github.com/MichaelCud/orb_slam_2_ros.git
- git clone https://github.com/MichaelCud/tello_driver.git
- git clone https://github.com/MichaelCud/drone_control.git current python module uses "import keyboard" if "keyboard" module is not installed, do "pip install keyboard". in case you get exception "keyboard module not found" after installation, then just copy keyboard directory to drone_control/scripts.
- sudo rosdep init
- rosdep update
- rosdep install --from-paths src --ignore-src -r -y
- sudo apt-get install python-catkin-tools
- catkin init
- catkin clean
- catkin build
- open terminal
- cd ~/catkin_ws
- source devel/setup.bash
- turn on your tello drone and connect to drone's WiFi access point (TELLO_XXXXXX)
- wait for connection
- roslaunch orb_slam2_ros find_the_treasure.launch
- if everything is ok then you will see pangolin gui opened with image recieved from drone.
for control the drone, open another terminal:
- cd ~/catkin_ws
- source devel/setup.bash
- rosrun drone_control talker.py
- control buttons: w - move forward s - move back a - move left d - move right up arrow key - move up down arrow key - move down left arrow key - turn left right arrow key - turn right