Build your own Drone (Best Tutorial 2019)

Build your own Drone

How to Build Own quadcopter Drone using Arduino Tutorial 2019

This blog will explain quadcopter drone and 15 tips that show how to build the best quadcopter drone with an HD camera. Hopefully, by the end of the blog, you will be able to fly your own quadcopter drone and capture pictures of your favorite places. 

 

Making a Robot Fly

Robot Fly

For sensors and devices that are common between mobile robots and flying robots, ROS takes advantage of these commonalities through its standard topic and message interfaces.

 

Just as with other robots, ROS standard topics and messages communicate information from the onboard sensors about the state of the quadrotor and its environment.

 

This blog begins by providing an overview of how a quadrotor works to stay in the air. The basic steps of learning to fly a quadrotor are discussed so that you can quickly gain expertise in flying.

 

Three ROS quadrotors are introduced: one simulated quadrotor, Hector, which exists only in Gazebo, and two real quadrotors, a tiny Crazyflie and the Bebop.

 

The Hector and Crazyflie quadrotors will be controlled through a common Xbox 360 controller interface. The advanced capabilities for SLAM and autonomous navigation will be explored. References are also given for controlling multiple quadrotors using ROS.

 

We will cover the following topics in this blog:

  • How quadrotors fly
  • The capability of the sensors that are used in quadrotors
  • Techniques and rules for flying quadrotors
  • Examples of quadrotors using ROS
  • Flying the simulated Hector Quadrotor
  • Flying real quadrotors: Crazyflie and Bebop

 

Introducing quadrotors

Introducing quadrotors

Quadrotors, sometimes called quadcopters, are part of a broad category of robots called Unmanned Aerial Vehicles (UAVs) that have four motors and propellers to provide lift for the craft.

In this blog, we will introduce some of these flying robots that are controlled by ROS. The blog will consider both simulations and flying the real thing.

 

The following figure shows the Crazyflie quadrotor that will be discussed later in this blog:

 

Crazyflie quadrotor

Crazyflie quadrotor

In the image, notice the four propellers or rotors that act to lift the craft vertically for takeoff and keep it in flight at a certain altitude when flying. First, such crafts are classified as rotorcraft because the lift is generated by the rotors shown in the figure, rather than the wings of an airplane.

 

Second, they are not helicopters, because the main propeller and the tail rotor control the flight of a helicopter. The tail rotor of a helicopter keeps the craft from rotating itself due to the rotation of the main horizontal propeller.

 

With a quadrotor, all flight maneuvers are made by varying the speed of one or more propellers. The propellers are called fixed-pitch propellers since their angle with respect to the quadrotor body cannot be changed.

 

There are more sophisticated quadrotors available with propellers that have a variable pitch, but they will not be considered in this blog. On helicopters, the main propeller is a variable-pitch propeller to control the craft’s direction of flight. For a general discussion of quadrotors, visit Quadcopter - Wikipedia.

 

Why are quadrotors so popular?

Why are quadrotors

Quadrotors are a popular option for hobbyists and researchers. They have a number of attractive characteristics; primarily:

  • Relatively low-cost compared to other aerial craft
  • Not too difficult to fly due to electronic stabilization during flight Depending on the size and type, some quadrotors can be flown indoors as well as outdoors
  • With the addition of a camera, the quadrotor is excellent for outdoor aerial photography

 

Defining roll, pitch, and yaw

As in any field of robotics, there is a vocabulary which is important for speaking precisely about the operations and tasks involved. A flying craft is said to have six DOF because the position of the craft can be located in space (x, y, and z coordinates) and in orientation with respect to three axes.

 

This position is usually defined in terms of the position of a fixed point, usually on the ground, such as the point of takeoff. The figure of the plane here shows how the orientation of the plane is defined in terms of angles around the coordinate axes of the airplane itself. The same definition would apply to the quadrotor:

 

Tip

You can imagine two coordinate systems involved in flight. The fixed system usually defined at a ground point and the system belonging to the flying craft. The relationship between these coordinate systems becomes important for flight maneuvers and when making a flight plan.

 

A quadrotor craft is different in that it can turn on its own yaw axis without banking. It can even fly backward!

quadrotors fly

 

Quadrotor flying forward

Quadrotor flying forward

The next figure shows a top view of a quadrotor in flight with the forward propeller 1 rotating clockwise (CW) and propeller 4 rotating counterclockwise (CCW). To achieve forward motion, increasing the speed of motor 2 (rotating CW) and motor 3 (rotating CCW) with respect to motors 1 and 4 will cause the craft to pitch down and fly forward:

 

Quadrotor propellers

If you want to roll the quadrotor, the speed of the propellers on one or other of the lateral sides has to be increased, such as motors 2 and 4.

 

To yaw the craft, the speed of the two motors across from each other diagonally is decreased, and the other two motors are speeded up. This imparts angular torque to the aircraft, which makes it turn. An example of this would be to increase the speed of motors 3 and 4.

 

If you own a quadrotor, notice the pitch (tilt) of the propeller blades on the propellers that rotate CW and those that rotate CCW. The upward tilt of the blades causes lift by the propeller rotating, with the upward edge cutting into the air.

 

Unfortunately, determining and setting the rotational speeds of the four propellers for such control in flight is quite difficult. Fortunately, in practice, the calculations for the speed of the propellers are carried out by a microcontroller and the appropriate software when commands are given to maneuver the quadrotor.

 

The results of the calculations by the microcontroller are output to an electronic motor control unit, which adjusts the speed of the individual propellers.

 

The algorithm that converts commands from the ground-based control device to the motor controller is typically a PID controller. For those interested in the math, the following website explains PID for quadrotors: Quadcopter PID Explained - Oscar Liang.

 

In manual flight, the operator commands various maneuvers, such as takeoff, forward flight, and landing using a flight-control unit with joystick-like controls. Many quadrotors also allow control by smartphones, tablets such as iPads, and similar devices.

 

The software interfaces for many quadrotors are provided by the manufacturer and are unique to that quadrotor. We have chosen quadrotors that can be controlled by ROS to illustrate the use of ROS in flying them.

 

The basic control of the quadrotor from the ground is to command its altitude by causing it to rise or descend and control its direction and attitude. The attitude of a flying craft represents its pitch and roll or bank with respect to the Earth’s horizon.

 

The electronic motor control unit of the craft makes the necessary changes or corrections to the speed of the propellers to achieve the result commanded.

 

Components of a quadrotor

Components quadrotor

The main components for the flight of a quadrotor craft are the frame, or body, the motors, and the propellers. The body holds onboard flight and motor control circuitry, communications circuitry, and a battery. In flight, the quadrotor reports its condition and other flight information to the ground-based control device using telemetry.

 

For the quadrotor, telemetry is the wireless transmission of various parameters, such as the battery condition and the position and orientation of the craft. On the craft, there is a set of measuring units called sensors that measure the parameters that are encoded and transmitted to the ground-based control device.

 

Basic components

Build your own Drone

A quadcopter drone is an aerial vehicle that consists of mechanical and electrical components including the frame, motors, and other electronic parts. It usually consists of the following parts:

  •  Motors
  • Propellers
  • Electronic speed controllers (ESC)
  • Battery and a power distribution board (PDB)
  • Flight controller (FC)
  • Frame

 

Autonomous flying vehicles

This category of craft has no pilot. All we need to do is connect the battery to the electronic system and let it fly. Quadcopter drones have numerous sensors, such as GPS, accelerometers, cameras, and many more.

 

Every second, the controller gathers data from all the sensors and after calculations, it autonomously decides how and where it should go according to the mission plan. These are extremely difficult to build, which is the reason why we prefer hybrid RCVs if we need a craft with autonomous functions.

 

Different frame shapes

Usually, any inexperienced hobbyist who is willing to build a quadcopter drone chooses the X shape, with four motors mounted at the ends. There are plenty of shapes and materials that can be used for this construction.

 

Each has its own advantages and drawbacks, as it will be explained later on in the subsequent blogs. The X shape is the most common and the first attempt at almost everyone. However, a quadcopter drone can also be created in a Plus or H shape, as shown in the following figure:

 

Adding more than four motors will result in a different build that might also work. Vehicles like these are defined as hexacopters or octocopters depending on the number of motors used. It should be clear that we can only add two motors at a time; adding only one will not work due to the laws of physics, as will be explained later.

 

Similarly, we can lower the angular velocity of motors one and three or three and four and have either left or right movement. Lastly, there is one more maneuver that a quadcopter drone can do.

 

In order to have yaw rotation, we need to lower the speed of any of the two opposite motors. Actually, doing this will increase or decrease the total left or right torque. This creates an imbalance in the torque between the motors; thus, causing the quadcopter drone to have yaw rotation.

 

Applications

The world is in need of something fast, light, and reliable. This technology is already developed but it is not yet reliable. Therefore, it is too early to use quadcopter drones in our everyday life. However, they can be used in several other ways.

 

[Note: You can free download the complete Office 365 and Office 2019 com setup Guide for here]

 

Research platform

Research platform

Quadcopter drones are quite interesting. They are used as a research platform for individual researchers and university research groups, to test and evaluate new ideas in a number of different fields, including flight control theory, navigation, real-time systems, robotics, and so on.

 

Researchers usually build, modify, or observe their maneuvers to develop more stable and promising future crafts. Being a researcher for a system like this requires a very good knowledge of the dynamics and mechanics of aerial vehicles.

 

Furthermore, test flights cannot be done in real time. Simulation software is an important tool so that researchers can test their algorithms and theories. Anything that passes the simulation stage will be tested in the simulation indoor lab where safety is a number one priority.

 

Swarms of quadcopter drones can hover information autonomously, perform flying routines, such as flips, dart through hula hoops and organize themselves to fly through windows as a group.

 

They are relatively cheap, available in a variety of sizes, and their simple mechanical design means that they can be built and maintained by amateurs.

 

As they are so maneuverable, quadcopter drones can be useful in all kinds of situations and environments. Quadcopter drones capable of autonomous flight can help remove the need for people to put themselves in a number of dangerous positions. This is a prime reason why the research interest has been increasing over the years.

 

For example, a mountain climber can deploy a quadcopter drone autonomously and check whether he should be more careful or not while climbing. Another idea is to deploy a quadcopter drone in a house to check whether there are human survivors or not in case of a disaster. Autonomous operations are extremely useful in situations such as earthquakes, fires, and so on.

 

There are several engineering research laboratories that are currently developing more advanced control techniques and applications for quadcopter drones.

 

These include mainly MIT's Aerospace Controls Lab, ETH's Flying Machine Arena, and University of Pennsylvania's General Robotics, Automation, Sensing and Perception (GRASP) Lab.

 

Commercial use

By the end of 2014, quadcopter drones were released in the market for the general public. As a result, crafts like quadcopter drones are now used to capture images and videos of areas that are rough or dangerous for humans.

 

There are many off-the-shelf quadcopter drones that can follow a transmitter bracelet, which can be worn on the arm.

 

There are quadcopter drones that can follow subjects without bracelets, using image recognition systems such as OpenCV. The most common commercial quadcopter drone is one of the copters, and is named phantom from DJI and has already made hundreds of thousands of dollars in sales all over the world:

 

Military and law enforcement

Since UAVs are great for surveillance, quadcopter drones are now used by military and law enforcement agencies to search, spy, or even rescue teams in missions. There are projects that are being run by militaries for autonomous indoor 3D scanning.

 

Future potential

Quadcopter drones can also save lives! After an earthquake or the collapse of a building, which might cause significant destruction, the response time to search and locate trapped survivors is crucial.

 

Mini and fast quadcopter drones equipped with cameras can fly among the debris in a safe, cheap, and effective way and locate survivors quickly.

 

Another scenario worth looking at is people drowning in a sea or lake. Every year, the percentage of accidents is almost the same but now quadcopter drones can change that. There is already an idea of a quadcopter drone equipped with three buoys and able to release them over three possible targets.

 

The quadcopter drones will be fully remote controlled by a pilot that overviews the whole mission. So, in each mission, a quadcopter drone will be able to increase the probability of a rescue.

 

Lastly, quadcopter drones are excellent aerial vehicles for transportation of low weight cargo. They can be deployed easily in rough areas or big cities. There is a huge need for a speedy vital organ transportation system in various areas, particularly in Africa where the cost of transportation by road is high and extremely difficult.

 

Difference between quadcopter drones and helicopters

airplane

The main difference between a quadcopter drone and a helicopter is the number of blades used for the lift. A helicopter's mechanism is extremely difficult to build and work properly, whereas quadcopter drones are pretty simple.

 

A helicopter produces all the lift needed, which is equal to its weight, with only one blade. As a result, the total mechanism is quite complex.

 

On the other hand, the stability in a quadcopter drone comes from four motors with their blades and it's quite simple to understand and create. Thus, the mechanism is quite simple. When a blade is spinning, there are two things that happen. First of all, there is a thrust, which lifts the craft.

 

Secondly, every motor creates torque, which is why a craft with only one blade would spin around itself. In a helicopter, a rear blade is used to prevent the craft from spinning around itself.

 

On the other hand, in a quadcopter drone, all the lift is produced by the sum of each motor's lift, which must be equal to the quadcopter drone's weight. But, instead of a rear motor to prevent the craft from spinning around, each motor eliminates the torque that the opposite motor produces. As a result, the quadcopter drone hovers steadily without spinning around itself.

 

Hardware Overview

 All the parts will be explained and information about the usage of each one will be given. Furthermore, you will be able to find some simple instructions and a list of specifications that you should be aware of when buying a component.

 

Thus, you will know how to choose your component based on your requirements. Hopefully, by the end of the blog you will be able to estimate the cost of your build and have a total overview.

 

This is extremely important when building a craft because you always need to be aware of the final purpose. You always need to know and have an abstract picture of the parts you need and how they will be connected.

hardware_drone

Radio transmitter and receiver (TX/RX)

For every motor, there is a specification manual either provided by the manufacturer or the seller. The following is a list of specifications that almost every motor has:

  • KV (rpm/v)
  • Weight (g)
  • Max current (A)
  • Max voltage (V)
  • Length (mm)
  • Shaft (mm)
  • Diameter (mm)

 

Hardware Overview

An example of the specifications that can be found when choosing a motor is shown in the following table. These specifications were on the same webpage where the motor was bought from.

 

Furthermore, motors typically specify a recommended battery cell count, for example, 3S, 4S, or even 5S. It is important to buy recommended parts if you are not an expert:

KV 935

Weight 55G

Diameter 27.9MM

Length 39.7MM

3S (LIPO) 1045(PROP)

Max thrust 850G

ESC recommended 18A

It is important to be aware of each of the following specifications:

hardware-drones

The KV value indicates how many RPMs (revolutions per minute) the motor will make when provided with V number of volts. Note that increasing the KV does not mean that your quadcopter drone will fly better or that it will be more stable.

 

There are many important factors that we should be aware of. For example, more KV means more thrust. As a result, the motors will consume more battery and the flight time will decrease.

 

The weight value indicates the weight of the motor. Note that we have four motors in our build, so we have to sum up four times the weight of each motor.

 

The only time when you should worry about the length, shaft, or diameter is when you build your own frame and you have to drill some holes.

 

Lastly, the current and voltage will have an effect on the electronic speed controller (ESC), which will be mentioned later. For now, just keep in mind that we have to choose the appropriate ESC according to the current and voltage.

 

Choosing a motor

The first thing that we should ask ourselves is about the total weight that we are expecting to lift with our quadcopter drone. At first, it is difficult to calculate the weight as we have no idea how much it will be; so we usually choose all the parts apart from the motor and estimate a possible total weight.

 

Since the weight factor must be eliminated by the total thrust the quadcopter drone produces, it is important to choose a motor that has the desired thrust. Generally, motors should provide a thrust that is two times the weight. This ensures that the quadcopter drone has the best balance over those factors.

 

Note that it is important to keep the balance. In other words, if the weight is too little or too much, compared to the thrust, the quadcopter drone will either have extreme sensitivity to all its maneuvers or it will not lift at all, respectively.

 

Motors that fit your needs can be found in the market. However, it is necessary to keep in mind that more weight, even if your motor can eliminate it, means reduced flight time. After all, it's all about the stability and flight time.

 

Hardware Overview

Hardware Overview

An IMAX-B6 charger can charge LiPo and other types of batteries. Usually, multicopters use LiPo batteries but there are cases when you might need something else. It's always a good choice to have something compatible with NiHM batteries too.

 

Power distribution boards

Usually, quadcopter drones have one battery. But how can we connect one battery to four ESCs? A power distribution board is an answer. It is a simple board that has two pins as input to the board and four or more outputs.

 

Therefore, we can connect our battery and have up to 8 outputs and each one of them is connected to the battery. 

 

There are four blocks of two outputs. Each output consists of two pins: one positive and one negative. There are two more pins, one positive and one negative, for your battery connection.

 

Make sure that this board does not touch any other conductive material. To conclude we can say that through this board we can power up all our ESCs with the voltage of our battery.

 

For example, a pilot may need to light up some LEDs, activate a system while flying or capture an aerial photograph. All these are extra functions that a pilot can activate through any extra channel.

 

Usually, these systems have some kind of memory that stores its data even if the battery is disconnected. Memory is required to save all the configuration a model has.

 

For example, let's say that we have two airplanes, one helicopter, and one multicopter and we need to save all the configuration of our models without any conflict. The transmitters have this option and we can try to fly our craft, change the settings, fly again, modify configurations, and then lock our configurations and save them for future flights.

 

Apart from the four sticks that any pilot uses to control its craft, there should be four trim sticks with which we can change the trim of the craft according to the drag it has.

 

Assuming that the minimum throttle is 1000 and the maximum is 2000, trimming the throttle channel has an effect on the min-max range. In other words, if we trim the throttle, the minimum may be 1050, 1100 or even 1200.

 

For each transmitter, there is a receiver of the same GHz. The receiver simply receives a signal from the specific transmitter and through the right pins passes the signals to the flight controller.

 

Quadcopter drones can be programmed and controlled in many different ways. Usually, there are two modes: acrobatic and stable mode. The difference is the way the controller board interprets the orientations feedback, together with your RC transmitter joysticks. Even if it is quite strange, it actually consists of two sticks and a tablet where you can see what your quadcopter drone sees:

 

Creating a Drone Frame

drones_frame

Even the most skilled pilot will find it hard to fly a quadcopter drone built over a badly designed frame. The frame is the base of the quadcopter drone and one of the most important parts.

 

It is something that cannot be changed easily. Everything is mounted on the frame; thus, removing and changing any component will be very time-consuming.

 

It will require removing and remounting of all the components. There are various shapes and materials with which we can build a frame and every single one of them has its own advantages and drawbacks, which we will explain later in this blog.

 

A good and well-built frame ensures a stable and easy flight. On the other hand, a frame that is built quickly with little attention to detail can cause stability problems, drag, and may cause crashes. Since safety is the number one priority, you should be cautious when building your own frame.

 

Market versus DIY

Market versus DIY

After years of testing and designing, many companies including DJI and Parrot have created some awesome drones. Inspire 1 is currently the best drone from DJI and Parrot quadcopter drones are made on some very beautiful, light, and stable frames.

 

However, those frames are not customizable. Mounting your own electronics on a market frame may not be possible or may require too many modifications for it to be practical.

 

Furthermore, there are many simple and very good frames available on websites like http://ebay.com, http://amazon.com, or even http://hobbyking.com. The cost depends on the material and the number of motors that you want to mount.

 

Buying a frame from websites like the ones mentioned is an excellent choice; if you don't want to mess up by designing and creating your own frame using any kind of material.

 

In the left-hand side image (DJI HJ450 frame), the frame is made from plastic and in the right-hand side image (X450), the material used is aluminum:

 

The following image shows two more frames made from aluminum and carbon fiber:

As a third option, we can create our own frame step-by-step. You should keep in mind that a wooden frame will work just fine and your quadcopter drone will fly; however, it is not the best thing you can do. Since the first decision we need to take is what material we are going to use, let's have a look at all the possible materials.

 

Materials

Depending on the budget, various materials can be used to build your own frame or you can buy a market one. A frame does not need to be only one material.

For example, you will notice that many frames consist of a combination of different materials.

 

Wood

Wooden frames are simple, easy to build, and more importantly, you can make any change you may think of, later on. As far as the frame is concerned, the cost of damage after a crash is very low.

 

These are almost all the advantages of a wooden frame. You can either buy some wood and cut it by yourself or give instructions to your local shop about the dimensions.

 

Lastly, when creating a wooden frame, make sure to cut it with a laser; this way you will be able to design it precisely according to your dimensions and hopefully have a stable quadcopter drone.

 

Aluminum

Aluminum is the second and most common material used for quadcopter drones. It is quite simple and lightweight and suitable for hobbyists who seek fun. Aluminum is lighter than wood and is much more stable.

 

If all the screws and electronics are mounted on the frame with caution, the overall build will be nothing less than a stable, lightweight, and reliable quadcopter drone.

 

Assuming that we are comparing the materials, a drawback of using aluminum frame could be the weight. Although it's a very good material, there is always something better and more expensive, for example, carbon fiber.

 

Carbon fiber

Carbon fiber is by far the best material for crafts. It is light but not so much that it increases the vibrations. It's hard, so it usually prevents your quadcopter drone from getting damaged in a crash; it is complicated too.

 

Assuming that you need to build a DIY frame with your own design, this material is not so easy to cut. It is also expensive in relation to the other materials.

 

Plastic

The last choice is plastic. Plastic is used as a material for frames coming from a manufacturer but most importantly, plastic can be used in 3D printers to design and finally print your own unique frame. 

 

3D printers are an amazing breakthrough, they are small and efficient objects because of their low cost, build, and easy design. Many software, such as Blender, Rhinoceros, and SketchUp can be used to export your own design as a file.

 

Frame Shapes

Frame Shapes

The X shape

We already mentioned that this kind of shape is the most common of all shapes. The X shape defines the basic shape and it is usually the first attempt to build a quadcopter drone.

 

The reason that it's defined as X is that the quadcopter drone looks like the Greek letter X from the top view. Each motor is mounted on the edges of the shape and everything else is usually placed at the center.

 

In comparison to other shapes, this shape is advantageous because the total thrust needed for acceleration is split into two halves since two motors will be used. This also increases our motor efficiency.

 

Creating a Frame

Drone_frame

The plug shape

The plug shape is exactly like the X shape with one difference; moving forward will require one motor and not two, as is the case in the X shape. Also, with a plus shape it's quite difficult to mount a camera at the front because the front propeller is in the way:

 

The H shape

Like the Greek letter H, with this shape, we can add more electronics, cameras, and DIY stuff that we want on our quadcopter drone. The main difference between the X and plus shapes is the space between the arms. As we can see in the following image, there is plenty of space to mount more than one battery:

 

The racing shape

Quadcopter drones intended for a race need to have a specific shape. The two front arms must be lesser in length than the two at the back. This increases the acceleration and the quadcopter drone gains more speed.

 

Furthermore, hobbyists usually try to build as small a quadcopter drone as possible. All the electronics are placed in the center of the total weight, in other words, around the center of gravity.

 

The stability shape

Quadcopter drones made for aerial photographs and video capturing must have a good stable frame to minimize vibrations. Usually, frames for such a purpose are big.

 

The four arms have the same length and are very long to increase the stability of the overall system, as compared to the racing shape where all the electronics are placed in the center of the total weight.

 

Soldering the Electronics

drones

After stripping, your wire will be ready for soldering:

At this point don't forget to place a heat shrink over the wire because once you connect the wire with the connector, you will not be able to do that.

 

Be careful when soldering anything. Almost any soldering station has enough heat to injure your skin. So anything that you are trying to solder, do it with caution and with a clear table. Place your wire in the paste, as shown:

 

Next, we need to place this wire into a banana connector. The wire should be tinned by heating and applying the solder, but make sure not to clump it. It also has to be hot enough. When you do it right, the solder sucks up the wire leads.

 

The connector will become very hot; so you should hold it with some kind of "helping hand". If you don't have any helping hand you may consider asking for help from a friend. He can hold the wire using any kind of grabber mechanism.

 

Make sure that you need to keep the wire steady using whatever you can. Lastly, you should use a cardboard. The soldier often drips and cardboard is a cheap and replaceable surface to protect your workbench/table:

 

Finally, place the wire inside the connector. After you place the wire in the banana connector, keep it steady for about 8 seconds:

 

After that, just heat the heat shrink to the right position. Note that I had to use a slightly larger heat shrink because the wire could not fit in the connector:

 

The male half should be covered till the point that it indicates how much of it goes inside the female. To verify if your connection is good, try to pull apart the wire with the banana connector gently.

 

If you can remove this easily, then repeat all the steps; you will have to solder your first connection correctly. Remember that you need to solder two connections (male and female).

 

Hold your connector with your helping hand and lace some solder over the pins.

 

  • After that, place your wire into the paste as shown in the image in the Soldering a banana connection section.

 

  • Insert a heat shrink, for later use. Next, gently place the wire over the pin and solder them together:

 

  • Place the heat shrink to the right. If for some reason it cannot be placed over the pin, choose a bigger heat shrink or repeat the step and solder the wire again and try to place as little soldering wire as possible so that the heat shrink can fit over the pin and the wire:

 

  • Once everything is ready and the heat shrink is in the right position, try and heat the heat shrink with any kind of heating device, such as a lighter. Do not stay over a specific point for more than 2 seconds.

 

Try and pass the entire heat shrink 5 to 6 times, slowly. Be careful with the flame, since you can injure your finger or burn the plastic part in the T connector. Do not heat the wire for long because it will get damaged:

 

Electronics Installation

In the previous blog section, we went through the soldering procedure for some of the electronics that needed further modifications. Hopefully, at this point, all our electronics are ready for installation.

 

In this blog, we will mount the motors, connect the ESC to the motors and the PDB, connect the receiver to the flight controller, and finally power up everything with our battery. Note that all the instructions that follow are crucial for your first flight.

 

Read every step with caution and if the result is not what you expected it to be, please be patient and repeat the step.

In this blog, we will cover the following topics:

  • Motor installation
  • Mounting the propellers
  • Installing the ESCs
  • Powering up

 

Motor installation

motor

Depending on your motor, this step may be either simple or very complicatedGenerally, you need to make two or four holes at the edge of your frame. That or has a reason to exist.

 

Some market frames look like this:

These have all the necessary holes that you may need, assuming that your motor has normal dimensions. So, there is nothing more to do than taking a screwdriver and placing some screws over the four motors.

 

But if you try to mount your motors in wood, aluminum, or some other material that has no holes, you will have to do some more work. Almost all the motors have some specifications on the market from which you have bought them, as shown in the following figure:

 

So, hopefully, you can find the dimensions of the motors and the exact size and spacing of the holes needed. Either you can make some holes with appropriate tools or buy an external motor mount system.

 

The motors usually have their own screw thread type and you should check that before buying them. It may be useful to buy some screws, but be careful not to buy a long one and damage the inner coils of the motors.

 

Electronics Installation

You may have to make some holes for the mount system. It really depends on the system that you buy. Another hack that I have done on my quadcopter drone. It really works. Choose wisely what you will do because it is very important to have a steady and well-mounted motor.

 

Mounting the propeller

Before mounting the propellers in the correct manner, we need to test each one and determine if they need further balancing. Balancing the propellers is important and an unbalanced propeller results in "shaky" hovering of the quadcopter drone.

 

To minimize the shaking, you have to constantly fix each drag with the sticks on your remote controller and this is quite annoying; especially when the goal is to capture a clear photograph.

 

As you can see, the left propeller is perfectly balanced and the right one is not. But how can we fix a badly balanced propeller? We can simply put some low weight on one side of the propeller.

 

For example, you can use Scotch tape. The weight of a 1x2 cm piece is enough to change the balance. Place the tape on the side that is higher and you will see that the extra weight that we have placed balances the propeller perfectly.

 

There are other ways of balancing your propeller, such as sandpaper, but you have to be very careful with it.

 

Now that the propellers are balanced, we have to mount them on our motors. If you take a closer look at a propeller, you will see that you have two clockwise and two counterclockwise. 

 

Motor 1 should have a clockwise propeller, motor 2 should have a counterclockwise propeller, and motor 3 and 4 should have a clockwise and counterclockwise propeller respectively.

 

There are two clockwise and two counterclockwise propellers. At the opposite motors, we need to use the same propellers. As a result, front-left and back-right will be the right direction propellers and the other two propellers would go to the other two motors.

 

Note that every propeller screw is different from a normal screw. You have to screw it in the opposite direction because high RPM may loosen the screw. However, there are many motors that have right direction screws, which is also fine, if they are screwed tight enough.

 

Camera for photographs

Whether it is a simple webcam or a professional GoPro camera, you can easily mount it on your quadcopter drone and capture videos or photographs of your flight. There is no one-step guide on how to place your camera on your quadcopter drone.

 

What you will read next are some basic issues while placing your camera and some things that you should always avoid.

 

Position in relation to other components

Assuming that your build is an X shaped quadcopter drone, your camera should be placed at a position near the center of mass.

 

Usually, most cameras weigh more than 100 grams and this weight is enough to change the craft's center of gravity. As a result, depending on the position of the camera, your craft will have an imbalance in weight causing decreased performance and battery life.

 

This is something we can avoid by keeping the camera position as close to the center of gravity as possible. Take a look at a DJI Phantom drone and its camera position in the following image:

 

Another issue that we should consider is power interference. Every wire starting from the battery to each component has interference and if the camera is near the 12V wires, it will result in some noise. So you must keep in mind that wires should be at least 1cm away from the flight controller and the camera.

 

Vibrations

Motors produce more vibration than you think. The vibrations are a source of noise and affect the camera and the flight controller. As far as the camera is concerned, the video that you have captured will be the worst video ever.

 

The flight controller, on the other hand, must have minimum possible vibrations to minimize the error that is produced and to keep the quadcopter drone stable. There are anti-vibration systems on the market that do a very good job. Here is one of them:

 

YouTube or other video sharing websites have stabilization algorithms that can somehow produce a more stable video but it's still not the result we want. 

 

Servomechanism

A servo is a mechanical system that rotates from 0 to 180 degrees. To help you understand the power of the servo mechanism, let's have a look at a common servo and where and how can we use it.

 

The preceding image is of a simple servo. Usually, a servo consists of two or three different plastic modules that we can easily change according to our goal. The servo is connected with 5V to any device like an Arduino board or most of the flight controllers that support a servo.

 

You have to identify the servo you bought and connect the wires in the right order according to the preceding image.

One or two servos can be used to create a simple DIY grabber at the bottom of the craft. A servo goes from 0 to 180 degrees, so it's quite simple to create a mechanism similar to this. Furthermore, we can use it to trigger various dropping mechanisms.

 

LED strips

Flying in daylight doesn't require any extra components. The craft is visible hovering from the ground and your FPV monitor (if used) should be very clear as far as the light is concerned. On the other hand, when the sun goes down or the sunlight is low, you may consider adding an LED strip.

 

LED strips are extremely low cost and lightweight. They are a great way of identifying your craft in a low light environment! In most cases they look like in the following image:

 

LED strips can be cut in small pieces of 5-10cm. The input voltage is about 12V, exactly the voltage of the usual LiPo batteries. Adding an LED strip to your craft will result in something like the following image. Obviously, you can understand its importance in a low light environment.

 

GPS systems

Note that the GPS also has drawbacks. Unfortunately, the GPS as a standalone system cannot get accurate coordinates. As a result, the flight controller uses a GPS module combined with an accelerometer, magnetometer, and maybe some more components. Each of them has small errors but the combination is very good.

 

A GPS module should not be trusted under cloudy weather, in the rain, or inside buildings. All these situations lower the strength of the signal from the satellite and, as a result, increase errors.

 

Some Basic Information about Drones

What is an Aerial Drone

Let's also think of what a Drone isn't. We've all heard that dreaded term … drones. A Drone isn't really a drone in the true sense. Rather, it's defined by the U.S.'s Federal Aviation Administration as an Unmanned Aerial System (UAS). 

 

The term UAS covers a wide array of aircraft, from drones to your average hobby radio-controlled airplanes. Most Drones are piloted in the line of sight (LOS), just as any radio-controlled airplane.

This variety is not considered a drone. Technically, a drone both lies outside LOS and has the capability of autonomous light (autopilot).

 

With specialized equipment, you can ly a Drone using a first-person view (FPV) camera system, telemetry, and so on, and turn your Drone into a fully autonomous drone. Therefore, some drones are Drones, but not every Drone is a drone.

What is Aerial Drone

Most Drone pilots, however, shy away from the term drone. This is because the term drone evokes images of aerial assassinations using missiles and guns mounted on the aircraft.

 

For instance, in a 2013 article in the Santa Rosa Press Democrat about Drones, a Santa Rosa police officer was quoted as mentioning "flying-by gang shootings" as crimes just around the corner.

 

Once you know how a Drone lies, the idea of mounting a weapon system onto a Drone is physically laughable and ludicrous. Mounting a firearm to a drone provides such a counterforce (kick) that the mental image of the result conjures Wile E. Coyote chasing the Road Runner. The Drone lying backward as the bullet stays in one place. Comical indeed!

 

How do Drones flying

Aerial Drones fly

Drones flying by utilizing two basic principles: lift and torque. Drones are truly a great exercise in Newtonian Physics (every action has an equal and opposite reaction). In a traditional helicopter, the main rotor spins in one direction.

 

To keep the body from spinning the other way (remember, every action has an equal and opposite reaction), a tail rotor is implemented in order to put a constant pressure on the tail to keep the body stable. A Drone uses counter-rotating propellers to keep the body stable while the propellers turn.

 

The axes of rotation on an aircraft are called a pitch, yaw, and roll. Pitch is simply pointing the nose of the aircraft up or down. Yaw is turning the aircraft to the left or right. Roll is turning the aircraft such that the sides go up and down (rolling to the left would make an airplane's left wing dip down).

 

Drone yaw control

A Drone uses these principles of the pitch, yaw, and roll to its advantage. In the following figure, you can see that propellers 1 and 3 move in one direction, while 2 and 4 moves in the other.

 

By slowing down 1 and 3 while speeding up 2 and 4, you can make the Drone yaw to the left. The torque of 2 and 4 spinning to the right makes the body spin to the left. Conversely, by slowing down 2 and 4 while speeding up 1 and 3, the Drone yaws to the right.

 

How a Drone moves

How an Aerial Drone moves

It all seems rather simple, right? Increasing and decreasing the speed of each motor provides movement in any direction. The direction is only dependent on the combination of motors that are increased or decreased.

 

There are less moving parts in a Drone than in a traditional helicopter. The movement in one direction has the same feel as in any direction because the aerodynamics is symmetrical.

 

So, why do traditional helicopters exist at all? The reason is that the electronics and components of a Drone have only recently (after the year 2000) begun to be practical and small enough to really make them work. Imagine controlling the speed of each motor independently to control your Drone by feel.

 

It would be impossible without the help of some very sophisticated electronics. This brings us to the next section. For now, let's get acquainted with what makes up a Drone.

 

The airframe

airframe

Motors and propellers

Motors and propellers are the main propulsion systems for your Drone. It's truly where the rubber meets the road. These components are, by far, under the greatest strain of any component of your Drone.

 

Every ounce of weight that your Drone carries rests on the blades of the propellers. So, as you can tell, strength is a prerequisite.

 

The bigger are the blades, the more lift there is. However, the bigger the blades, the more is the leverage placed upon the hub of the blades and more strain is exerted. Skimp on the blades and they'll snap, and your whole investment comes crashing to the ground.

motor

Also, the bigger the blade, the stronger the motor must be in order to counteract the torque required to turn the blade. It might seem like the motor doesn't truly have to deal with a lot of resistance.

 

But that's just not true. If a propeller is moving enough air to lift a couple-dozen pounds into the air, there is a lot of wind resistance that the motor must counteract.

 

Faster motors are weaker. It's a giant balancing act to figure out how to get the right blades, motors, and so on, to lift your payload for the longest time possible. The following image shows carbon fiber blades attached to motors that spin at 480 RPM per volt (KV):

 

The electronic speed control

electronic speed control

The electronic speed control (ESC) is a marvelous invention. This truly makes lying Drones possible. Electric motors require more voltage to start spinning than to keep spinning at their lowest speed.

 

Also, as you apply more voltage, they don't necessarily speed up on an even curve. The ESC spikes the voltage to start the motor and eases it back to keep them spinning at a low speed on a low throttle.

 

Also, as you apply more throttle input, the ESC accelerates the rotor evenly. Furthermore, most ESCs can be programmed to any curve you like. A real tech head can have a field day just programming ESCs.

Don't let that scare you though … most ESCs are preprogrammed with the necessary settings to get you going without ever needing to dive in.

 

ESCs are the pass-through from the battery to the motor. They must be carefully balanced with the motor to give enough power to the motor and not burn out.

 

Putting an underpowered ESC in your Drone can cause crashes … or even fires. You must have an individual ESC for every motor. The following image shows all the six ESCs tied down to the hub of this Drone:

 

The guidance system

The guidance system

Now this is where the real magic happens. To flying a Drone, it literally takes tens-of-thousands of calculations per second to sense whether you're going up or down or whether you are moving, tilting, or rotating, all the while adjusting your motors to counteract these forces to keep your Drone stable. There are several aspects to the guidance system.

 

Most guidance systems have the same set of sensors nowadays. The main difference from system to system is how fast the calculations are done and the algorithms that are used in the firmware. Yes … I said firmware. These are literally lying computers.

 

The circular module in the given image is a dual-purpose antenna. It senses both the direction (using a compass) and the GPS location (by using a 6-12 satellite lock system). This provides extremely accurate positional data for the brain to do its work.

 

In the other section of the photo, you'll see two grey boxes. The one in the background is the sensor box. This includes a 3-axis accelerometer and gyros to determine the pitch, roll, and yaw movement several thousand times a second. Additionally, it contains a barometer to indicate altitude.

 

The box in the foreground is the main brain that takes all this information and your control inputs (coming in on the left side from the radio receiver), compares that to the GPS and compass data to create an accurate impression of what the drone is doing (as well as what you wish it to do).

 

And sends speed information to the ESC (out on the right side), and in turn to the motors to move your drone properly and in a stable fashion. Like I said … this is where the magic happens.

 

Furthermore, there are more add-ons that you can get to interface with your guidance system. Camera gimbals can hook in the WooKong-M (and most other systems), and as the Drone tilts to move, the camera can actually stay level.

 

Also, onscreen displays (OSD) can be hooked in for your camera transmitter (allowing you to see all the telemetry, including battery life, attitude (orientation), height, and so on, on a viewing monitor while seeing what your camera sees).

 

This unit communicates with the airborne Drone from the ground using an iPad. You can actually click on a Google Earth map … and the Drone will fly there. Or, you can even draw out preprogrammed light paths. These add-ons are what truly transform a Drone into a drone.

 

Camera gimbals and transmitters

Camera gimbals and transmitters

The term camera gimbal is a short way of saying, "a fancy device that keeps the camera leveled and reduces vibration no matter what the Drone does within reason." So yeah … camera gimbal is much shorter. Generally, these systems hook into your guidance system and are tuned by the pilot (you) to work properly.

 

Gimbals (good ones at least) are not cheap; the more weight that you want to carry and the more movement you want makes the price go up exponentially. The gimbal in the following image is capable of carrying a DSLR camera. It's made by Photoshop One, and a new one retails for around 800 USD.

 

Furthermore, it's important to have a good transmitter. It's unheard of for any videographer to blindly shoot a video in a general direction while hoping to capture what he/she wants in a great way.

 

It's unheard of because it's ludicrous, and the first sign that you've hired the wrong pilot. Transmitter/receiver systems are generally not all that expensive, and you can expect it to be one of the smallest investments you'll make. Be careful though. These can drain power rapidly if you get the wrong one.

 

Radio systems

radio

Your radio is the primary interface between a human and a machine. It's important to get a good one that feels right for you. The buttons should be easy to find, and it should (above all) be reliable.

 

FM transmitters are a way of the past. Futaba, with their FASST, and Spektrum/JR (with DSMx) are the waves of the present and future.

 

No longer do you need to worry about competing transmitters, calling out a channel, or severe fading. The new generation of transmitters/receivers is digitally paired, and have LOS ranges in terms of miles. The following is an image of the Spektrum DX7s transmitter and the AR-8000 receiver with a satellite:

 

Adding sensors

GPS

One important application of quadrotors is for aerial photography. Some models have a camera built directly into the body. Other models have cameras attached underneath the body.

 

Usually, the camera is controlled from the ground to take pictures or videos. In addition, some quadrotors may have a GPS receiver on board. The position of the craft over the Earth is available and some quadrotors can be guided to traverse a selected course through a series of GPS waypoints.

 

For more information about the GPS system, visit GPS.gov: GPS OverviewThere are many models of quadrotors on the market. For a comparison, visit Best Quadcopters and Drones

 

Since manufacturers are producing new quadrotors incomplete or kit form, you should check websites that review the latest craft if you are in the market to buy one.

 

Quadrotor communications

There are a number of communication methods that allow quadrotors to be controlled for autonomous or manually controlled flight. Here are a few examples. 

 

GPS provides position data for your quadrotor if it has a GPS receiver. Using maps for GPS that can be downloaded, you can plot a course for the craft and it will fly that course autonomously.

 

Wi-Fi communication can allow manual control of the quadrotor using smartphones and tablets. After downloading the manufacturer’s software from a website, a screen appears with an image of flight controls that mimic joysticks that you can use to fly and control the quadrotor.

 

Data from the quadrotor can also be received on these devices. If the drone has a camera, the camera view can be seen on these devices. Some quadrotors come with their own controllers that usually include joystick-type controls to fly the craft.

 

The bluetooth connection provides another method for transmitting information to and from the quadrotor. The range of the signal is limited to 10 meters (32 feet) for mobile devices. 

 

Some quadrotors may use Radio Frequency (RF) signals to communicate with the craft. Radio-controlled crafts, such as model airplanes, have been available for many years. These signals allow for a much longer range of communication.

 

Understanding quadrotor sensors

quadrotor sensors

Inertial measurement unit

The inertial measurement unit (IMU) is a combined gyroscope and accelerometer. This unit will indicate the complete information about the flight characteristics of the quadrotor. Typically, the unit will measure the acceleration and orientation of the flying craft in all three dimensions.

 

These sensors allow indoor and outdoor flight. However, all the sensors previously mentioned suffering from slight errors that may accumulate during flight, so caution is necessary while flying in confined spaces.

 

Quadrotor condition sensors

Many quadrotors have sensors that will indicate information about their condition, including the motor temperature and the percentage of battery charge. This information is relayed by telemetry to the ground-based control device.

 

ROS, with its message passing capability, is ideally suited for the communication of sensor messages between the quadrotor and the ground-based control device. Various types of ROS sensor messages are listed at http://wiki.ros.org/sensor_msgs.

 

Many websites present articles on flying quadrotors. For example, various tutorials are available on the following websites:

Drone Training, Industry News, & Free Resources | UAV Coach http://uavcoach.com/how-to-fly-a-quadcopter-guide/ There are also many YouTube videos showing quadrotor or quadcopter flying techniques.

 

Some of the things that should be considered before and during flight are as follows:

  • Testing your quadrotor
  • Preflight checklist
  • Safety and dangers
  • Rules and regulations
  • Testing your quadrotor

When your new quadrotor first arrives, it is natural to want to begin flying immediately. Our suggestion is to be patient and take time to familiarize yourself with the quadrotor and its flight controller.

 

We found that removing the propellers to test the quadrotor indoors was a good way to understand the craft and its controller without any danger of crashing.

 

Also, some practice on a simulator such as Hector (described later) will help you understand the flight controls. Remember that the controls will be reversed for direction and pitch control when the quadrotor is flying towards you, as compared to when the craft is flying away from you. A little time using the simulator will improve your flying ability.

 

Pre-flight checklist

Any good pilot follows a checklist before the flight. Some of the basics are as follows: Check that the quadrotor is not damaged and that its battery is charged. Make sure that the flight controller is disarmed so the quadrotor cannot take off until you are ready.

 

Make sure the area for flight is clear of obstacles and people.

When flying the quadrotor, always be aware of the surroundings and keep the quadrotor in sight. Flying over people or their private property without permission is usually illegal in most countries.

 

When flying in a public area, inform the police or the appropriate authorities that flights will take place. Be sure to keep the craft well away from buildings, trees, and people. 

 

If flying using GPS, be sure the GPS satellite signals are locked on before flying. It could take several minutes for the onboard GPS receiver to get the signals from at least four satellites.

 

Precautions when flying your quadrotor

When you are learning, start your flights outdoors in light-wind or no-wind conditions. A high wind can cause the quadrotor to fly out of control. Remember that if the battery fails, the quadrotor will not glide but will fall straight down.

 

Keep aware of the battery percentage charge and bring the quadrotor to its landing point when the battery charge is low, below 20 percent to be safe.

 

Tip Use caution when flying quadrotors

Motors can fail and propellers can break due to a hard landing. Communication between the ground-based control device and the quadrotor can be interrupted or lost.

 

If the motors or propellers are damaged, the controlled flight may be impossible. If the battery drains in flight, the quadrotor will fall to the ground unless it has a fail-safe mode that returns the craft home when the battery is low or communication with the quadrotor is lost.

 

Following the rules and regulations

Quadrotors are considered drones and these unmanned aircraft systems are regulated. In the United States, the Federal Aviation Administration (FAA) regulates flights and requires the registration of some craft, including quadrotors, based on the weight of the craft.

 

Loading Hector Quadrotor

The repository for the hector_quadrotor software can be found at: https://github.com/tu-darmstadt-ros-pkg/hector_quadrotor.

 

At the time this blog is being revised, the hector_quadrotor software is in a development release for ROS Kinetic. The instructions for installing this release are provided here, but you should check the GitHub repository identified in the preceding paragraph to determine whether a Debian package has been created.

 

If it has, you can use the apt-get command to install it on your system.

 

Otherwise, install the Kinetic development release of hector_quadrotor in your catkin workspace using the following commands: $ cd ~/catkin_ws/class='lazy' data-src
wstool init hector https://raw.github.com/tu-darmstadt-ros-pkg/hector_quadrotor/kinetic-devel/tutorials.rosinstall wstool update

 

Prior to performing a catkin_make on your workspace, you will need to install the geographic_msgs package: $ sudo apt-get install ros-kinetic-geographic-msgs
Then proceed with: cd ~/catkin_ws and catkin_make

 

A large number of ROS packages are downloaded with the hector_quadrotor metapackage, including the metapackages for hector_slam, hector_localization, hector_gazebo, and hector_models.

Within these metapackages, this installation downloads the following packages:

hector_components_description
hector_compressed_map_transport
hector_gazebo_plugins
hector_gazebo_thermal_camera
hector_gazebo_worlds
hector_geotiff
hector_geotiff_plugins
hector_imu_attitude_to_tf
hector_imu_tools
hector_map_server
hector_map_tools
hector_mapping
hector_marker_drawing
hector_nav_msgs
hector_pose_estimation
hector_pose_estimation_core
hector_quadrotor_actions
hector_quadrotor_controller_gazebo
hector_quadrotor_controllers
hector_quadrotor_demo
hector_quadrotor_description
hector_quadrotor_gazebo
hector_quadrotor_gazebo_plugins
hector_quadrotor_interface
hector_quadrotor_model
hector_quadrotor_pose_estimation
hector_quadrotor_teleop
hector_sensors_description
hector_sensors_gazebo
hector_slam_launch
hector_trajectory_server
hector_uav_msgs
hector_xacro_tools
message_to_tf

Recommend