3
$\begingroup$

I am relatively new to using drones and was wondering if someone more experienced in the topic could lend a hand. I am familiar with C++ and OpenCV, a facial recognition software that has libraries in C++. I would like to be able to use the software to control the drone (engaging it/turning off or on. Flight patterns would be a plus).

In other words I need someone to point me in the right direction to finding the right materials so that my C++ code can control the drone. If anyone can point me to the reading materials or specific drones to purchase I would be extremely grateful.

Note, I used quadcopter as a tag because I did not have enough reputation to use drone

$\endgroup$
  • $\begingroup$ I believe this is going to very drone specific. What drone do you plan on using, If you are open to options, please place some parameters around what drones you be open to (ex: cost, range) $\endgroup$ – markshancock Jul 9 '17 at 4:24
  • $\begingroup$ OpenCV is a general purpose computer vision library. It is used in many applications beyond facial recognition. For a useful framework for controlling your UAV, look into ROS. $\endgroup$ – koverman47 Jul 6 '18 at 21:26
3
$\begingroup$

You could use ROS. There's AR Drone Autonomy for well.. Parrot AR-Drones. TUM ARDrone from the Technical University of Munich, who used that with OpenCV to control a drone. You can simulate a drone using Hector.

Or simply search google for quadcopter ROS

$\endgroup$
2
$\begingroup$

From a very basic standpoint, you're talking about turning on and off motors using code. I'm not sure what drone you're planning on using (building your own?), but there's a lot of great motor controllers out there. Adafruit makes some great motor hats that work with a Raspberry Pi, if you decide to go that route (you'll still need an H Bridge).

If you want something more advanced, like a full on flight controller, I'd point you to GitHub as a starter, where there's a lot of stuff already out there.

It may be a good first start to get a motor (or motors) running as a sort of 'hello world', and then move to drone control from there.

$\endgroup$
2
$\begingroup$

ROSflight is a relatively new ROS-based autopilot built on top of STM32 family of microcontrollers -- most notably the F1.

It was built mainly as a research platform so the code is very organized and lean. It was first written in C and is now being ported to C++. The flight controller firmware talks to an on-board companion computer using the MAVLink protocol and exposes IMU (and other sensors) at a rate of 1000Hz through the ROS network using pub/sub.

The ROSflight autopilot firmware takes care of attitude estimation, stabilization, mixing, and RC while the high-level controllers written in C++/Python (using ROS) run on the on-board computer and direct the autopilot based on your specific application. This is where you would use OpenCV to do image segmentation / recognition and control off of visual information.

The same research lab that built ROSflight has publicly available ROS high-level controller starter code for multirotors and fixed wing planes (github.com/rosplane).

$\endgroup$
1
$\begingroup$

I propose to use a flight controller (FC software like Betaflight) connected to an Arduino or Raspberry Pi.

The new F3 or F4 flight controllers have, in general, I2C/SPI interfaces where you can call the FC functions.

$\endgroup$
  • $\begingroup$ What is "resp."? $\endgroup$ – Greenonline Jul 10 '17 at 14:31
  • $\begingroup$ haha sorry, "ginglish" - german / english mix..... I've corrected my answer. $\endgroup$ – over.unity Jul 10 '17 at 15:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.