How to assemble and configure a quadcopter based on Arduino (Arduino)?

Hello, our dear readers. In this article we will talk about how to assemble a quadcopter using Arduino. This is not the easiest, although a very exciting task, the result of which will be the appearance of a small drone, designed, assembled, and configured with your own hands. Let’s immediately make a reservation that we are talking about the cheapest drone possible from the most affordable components.

Before you start assembling the quadcopter with your own hands, you need to acquire all the necessary parts. The brain of our homemade product will be the Arduino Uno flight controller. Its capabilities are more than enough to control a drone.

In addition to the microcontroller, we will need:

  • Battery (preferably several) 3.7V
  • MPU-6050 board (gyroscope and accelerometer installed on it)
  • Transistor ULN2003A
  • Commutator motors with hollow rotor 0820
  • Wires

A few points need to be made. Since we collect, our choice fell on commutator motors with a hollow rotor (so-called coreless motors). They are not nearly as reliable as brushless motors, but they are much cheaper. In addition, you can do without additional speed controllers.

But it is impossible to do without a gyroscope and accelerometer. The gyroscope is necessary to ensure that the quadcopter can maintain a given direction of movement, while the accelerometer is used to measure acceleration. Without these devices, controlling the copter would be much more difficult (if not impossible), since they provide data for the signal that regulates the speed of rotation of the propellers.

We did not include the frame in the list of required parts. You can purchase it, or you can 3D print the frame, beams and mounts for the engines. The second option seems preferable to us, especially since you can easily find quadcopter projects on the Internet.

The frame printed on the printer will be not only light, but also durable. But if you don’t have access to a 3D printer, you can order a frame.

Step-by-step assembly instructions

How to print a frame and fasteners

3D printers can be found in many universities, laboratories, and coworking spaces. Often access to them is free. You can create models for printing yourself using, for example, Solidworks. Or you can use ready-made solutions, changing the parameters if necessary.

How to set up the gyroscope accelerometer

To configure the accelerometer-gyroscope (I2C), we recommend using the following library. Under no circumstances connect the board to 5V voltage, otherwise you will instantly damage it.

Let's briefly tell you why an I2C board with sensors is interesting. It is noticeably different from a conventional accelerometer board with three analog outputs for the X, Y, Z axes. I2C is an interface bus that allows the transfer of significant amounts of data through logical digital pulses.

There are not many analog outputs on the board, and this is a big plus of I2C, because otherwise we would have to use all the ports on the Arduino to receive data from the gyroscope and accelerometer.

Connection diagram to Arduino

Before the I2C board can communicate with the Arduino, it needs to be connected to the controller.

We are interested in the I2C scanner code sketch, or rather, its code.

Copy the program code, paste it into an empty sketch, and then run it. Make sure the connection is established to the 9600 (to do this, launch the Arduino IDE via Tools-Serial Monitor). An I2C device with address 0x68 or 0x69 should appear. Write down or remember the address. If the address is not assigned, most likely the problem is in the connection to the Arduino electronics.

Next, we need a sketch that can process gyroscope and accelerometer data. There are many options on the Internet, and finding the right one is not a problem. Most likely, it will be in archived form. Unzip the downloaded archive, open the Arduino IDE and add the library (sketch-import library-add library). We will need the MPU6050 and I2Cdev folders.

Open MPU6050_DMP6 and carefully review the code. You won’t have to perform any complicated actions, but if the address 0x60 was assigned, then you need to uncomment the line at the top (it can be found under #includes) and write the correct address. Initially tav is specified as 0×68.

We download the program, open the monitor window through 115200 and simply follow the instructions. In a few moments you will receive data from the gyroscope/accelerometer. Then the sensors should be calibrated.

Place the board on a flat surface and run the sketch MPU6050_calibration.ino (easy to find on the Internet). Review the code, the default address is 0x68. After starting the program, you will have information on deviations (offset). Write it down, we will need it in the MPU6050_DMP6 sketch.

That's it, you got a functioning gyroscope and accelerometer.

Program for Arduino

The program will help you control the drone. The algorithm used for stabilization is based on two PID controllers. One is for roll, the other is for pitch.

The difference in the rotation speeds of pairs of propellers 1 and 2 is equal to the difference in the speeds of pairs of propellers 3 and 4. The same is true for pairs 1, 3 and 2, 4. The PID controller changes the difference in speed, after which roll and pitch become zero .

Pay attention to the Arduino digital pins for the motors and don't forget to change the sketch.

Connection to the controller

In order to control the copter, we need to gain control of the motors by connecting them to the Arduino. The controller outputs only a small voltage and current, so connecting motors directly makes no sense. Instead, you can install several transistors to increase the voltage.

To create a diagram we need:

  • Arduino
  • Engines
  • Transistors

All this is assembled on a circuit board and connected by connectors.

The first step is to connect 4 PWM outputs (marked ~) to the transistor. Then connect the connectors to the motors connected to the power supply. In our case, we use a 5V battery, but a 3-5V battery will also work.

The transistors must be grounded and the ground on the Arduino board must be connected to the battery ground. The motors must rotate in the correct direction, that is, they must work to lift the copter, and not to roll it.

By switching the motor contact from 5V to the transistor, you will see that the rotor will change direction of rotation. Once you have made the adjustment, you will no longer have to return to changing the direction of rotation of the rotor. Now we are interested in speed.

After running and testing the accelerometer, we install our circuit on the ProtoBoard. In its absence, you can use a regular circuit board, having previously soldered the rails for the controller on it.

Before soldering the accelerometer to the board, it is necessary to calibrate it on a horizontal surface. This will help achieve more accurate sensor performance in the future.

Some tips for beginners

When deciding to start creating a quadcopter using Arduino, pay attention to the following tips:

  • Don't complicate the first design by installing an action camera. Your task remains to create a drone that can take off and confidently stay in the air, and not fall to the ground, breaking on the first flight. If the latter happens, then the action camera can easily be broken, and this is a big expense.
  • Don’t strive for large scales, since for the first time it’s enough to create a small working Arduino drone, the design of which can be further worked on, improving and complicating it.
  • Reduce the number of additional elements and connections to a minimum, since a large number of sensors and various controllers does not always increase the reliability of the drone in flight. It is much better to create a basic design and gradually complicate it by adding new functions and capabilities. This will be much smarter and will allow the design of “specialized” drones in the future.
  • If you want to make an Arduino quadcopter with a camera, then you will need a fairly large base, which reduces the stability of the entire structure.

In conclusion, let us note that programming and creating a quadcopter based on Arduino is exciting, but quite difficult for beginners, so don’t give up if you don’t succeed. It is quite possible for anyone to make a drone using Arduino, and a lot of additional information and videos that you can easily find on the Internet will help you with this.

3.6 / 5 ( 7 votes)

How else can you upgrade your quad?

The bottleneck of the copter is its collector engines. If you search, you can find slightly larger and more powerful motors than those proposed in our article, but there will not be a significant gain in performance.

However, our goal was to assemble an inexpensive quadcopter with our own hands, and that is why cheap motors were used. Brushless motors are noticeably more expensive, but they will give you noticeably more power and reliability. They will also have to be purchased with speed controllers, but this is a truly effective upgrade.

The choice of the Arduino Uno board is due to the fact that you can quite easily remove the chip from it and put it on the ProtoBoard. This allows you to reduce the weight of the drone by 30 grams, but you will have to include additional capacitors in the circuit. An Arduino Pro Mini board will also work.

As for the Arduino program, it can be relatively easily changed and added with new functions. The main thing is that with its help the drone is able to automatically stabilize its position.

Despite the fact that quadcopters are an extremely fashionable topic, choosing components to assemble your device is still not so easy. Selecting parts for a specific project is a painful search for the optimal combination of weight, power and functionality. Therefore, before plunging into the world of countless online stores and nameless Chinese manufacturers, let's do the preparatory work.

Microcontroller socket

In order to transmit GPS data or use an ultrasonic distance sensor with an Arduino Nano, UNO or Pro Mini, we will need an additional microcontroller. It will process data from GPS or sonar modules and transfer it to the flight controller board via I2C.

A very convenient feature is a built-in socket for easy I2C connection for peripheral devices.

2 additional contacts for motors (for hexacopter) are shown in the figure below.

What is a quadcopter and why is it needed?

Multirotors, also known as multicopters or simply copters, are unmanned aerial vehicles designed for entertainment, taking photos and videos from the air, or testing automated systems.

Copters are usually distinguished by the number of motors used - ranging from a bicopter with two motors (like GunShip from the movie Avatar) to an octacopter with eight. In fact, the number of motors is limited only by your imagination, budget and the capabilities of the flight controller. The classic version is a quadcopter with four motors located on intersecting beams. The Frenchman Étienne Oehmichen tried to build such a configuration back in 1920, and in 1922 he even succeeded. Essentially, this is the easiest and cheapest option to make an aircraft that can easily lift small cameras like a GoPro into the air. But if you are going to take off with serious photo and video equipment, then you should choose a copter with a large number of motors - this will not only increase the load capacity, but also add reliability if one or more motors fail during the flight.

Ryze technology: a new player on the market

Tello is a joint product of DJI and Intel with a young startup Ryze Technology from the same China. The company was founded in 2022. For now, the company is focused on producing drones equipped with a camera, as well as an arsenal of all kinds of “smart” functions and training capabilities. The company aims to increase the interest of young people in modern technology.

In the development of the Tello drone, the young startup received help from eminent “giants”: a flight controller was taken from DJI, and a powerful processor was installed from Intel. All this power fits into a small package that you can take with you anywhere. Tello can “learn”: the owner will have the opportunity to program the drone, and according to the developers, it will be so easy that not only teenagers, but even children can handle programming!

This is not to say that Tello is a product from DJI, although the drone is visually similar to Spark. Still, DJI and Intel are rather partners who participated in the development of the quadcopter. In addition, DJI will be offering Tello for purchase in their online store.

Flight theory

In flight theory (aerodynamics), it is customary to distinguish three angles (or three axes of rotation), which determine the orientation and direction of the aircraft’s motion vector. Simply put, the aircraft “looks” somewhere and moves somewhere. Moreover, he may not move in the direction he is “looking.” Even airplanes in flight have some kind of “drift” component that takes them away from their course direction. And helicopters can generally fly sideways.

These three angles are commonly called roll, pitch and yaw. Roll is the rotation of the vehicle around its longitudinal axis (the axis that runs from nose to tail). Pitch is a rotation around its transverse axis (pecks its nose, lifts its tail). Yaw is a rotation around a vertical axis, most similar to rotation in the “ground” sense.

Basic maneuvers (from left to right): straight, roll/pitch, and yaw

In the classic helicopter design, the main rotor controls roll and pitch using a blade swashplate. Since the main rotor has non-zero air resistance, the helicopter experiences a torque directed in the direction opposite to the rotation of the rotor, and to compensate for it, the helicopter has a tail rotor. By changing the performance of the tail rotor (revolutions or pitch), a classic helicopter controls its yaw. In our case, everything is more complicated. We have four screws, two of them rotate clockwise, two counterclockwise. Most configurations use fixed-pitch propellers and can only be controlled by their speed. If they all rotate at the same speed, they will cancel each other out: yaw, roll and pitch will be zero.

If we increase the RPM of one clockwise rotating propeller and decrease the RPM of the other clockwise rotating propeller, then we maintain the total torque and yaw will still be zero, but roll or pitch (depending on where we do his “nose”) will change. And if we increase the speed on both propellers rotating clockwise, and reduce the speed on the propellers rotating counterclockwise (to maintain the total lift), then a torque will arise that will change the yaw angle. It’s clear that all this will not be done by us ourselves, but by an on-board computer that will receive a signal from the control sticks, add corrections from the accelerometer and gyroscope, and turn the screws as needed. In order to design a copter, it is necessary to find a balance between weight, flight time, engine power and other characteristics. All this depends on specific tasks. Everyone wants a quad to fly higher, faster and longer, but the average flight time is between 10 and 20 minutes depending on battery capacity and overall flight weight. It is worth remembering that all characteristics are interconnected and, for example, an increase in battery capacity will lead to an increase in weight and, as a result, a decrease in flight time. To find out approximately how long your structure will hang in the air and whether it will even be able to get off the ground, there is a good online calculator ecalc.ch. But before you enter data into it, you need to formulate the requirements for the future device. Will you be installing a camera or other equipment on the device? How fast should the device be? How far do you need to fly? Let's look at the characteristics of the various components.

PX4 - on-board computer with a full UNIX system

Software

PID controller (purpose and settings)

Proportional Integral Derivate (PID) is a piece of flight controller software that reads data from sensors and calculates how fast the motors must spin to maintain the desired speed of the UAV.

Developers of ready-to-fly UAVs typically tune the PID controller parameters optimally, so most RTF UAVs fly perfectly straight out of the box. The same cannot be said about custom UAV assemblies, where it is important to use a universal flight controller suitable for any multi-rotor assembly, with the ability to adjust PID values ​​until they meet the required flight characteristics of the end user.

GUI

Graphical User Interface (GUI) is what is used to visually edit the code (using a computer) that will be loaded into the flight controller. The software that comes with flight controllers continues to get better and better; early flight controllers used mostly text-based interfaces that required users to understand almost all of the code and change certain sections to suit the design. Recently, interactive graphical interfaces have been used in GUIs to make it easier for the user to configure the necessary parameters.

Additional features

The software used on some flight controllers may have additional features that are not available on others. The choice of a specific flight controller may ultimately depend on what additional features/functionality are offered by the developer. The list of such functions may include:

  • Autonomous Waypoint Navigation - Allows the user to set GPS waypoints that the drone will follow autonomously.
  • Oribiting - moving a drone around a given GPS coordinate, where the front of the drone is always directed towards a given coordinate (relevant for shooting).
  • Follow me - many UAVs have a “Follow Me” function, which can be based on satellite positioning (for example, tracking the GPS coordinates of a smartphone or a GPS module built into the control equipment).
  • 3D Imaging - Most 3D imaging is done after flight using images and GPS data acquired during the flight.
  • Open source - the software of some flight controllers cannot be changed/customized. Open source products typically allow advanced users to modify the code to suit their specific needs.

Frame

The main point to decide when choosing a frame is whether you will use a ready-made frame or make one yourself. With a ready-made frame, everything is simpler, and in any case you will have to order a lot of parts. At the same time, given the prices in Chinese stores, the homemade option may be more expensive. On the other hand, it will be easier to repair your own frame in the event of an accident. Well, of course, you can make any design, even the craziest one, with your own hands. Let's take a closer look at the self-assembly option.

You can make a frame from any available materials (wood, aluminum, plastic, and so on). You can get a little more serious and cut it on a CNC machine from woven carbon fiber, and you can complicate the task and make a folding structure.

The easiest option for DIY enthusiasts is to go to OBI, Leroy Merlin or the construction market and buy a 12 × 12 square aluminum pipe, as well as a 1.5 mm thick aluminum sheet. In order to make a frame from such “four sticks and fasteners” type materials, a drill or a hacksaw for metal is enough. But you need to be prepared for the fact that such a design will not last long. Still, all these profiles are made of very soft material (AD31/AD33), which will bend easily during flights.

Oehmichen No. 2, a manned quadcopter by French engineer Etienne Oehmichen, launched in 1922

As a sample for your frame, you can take a simplified factory frame or find a ready-made drawing on the Internet. More complex materials (for example, carbon fiber) can be replaced with aluminum - if it turns out to be heavier, it will not be by much. In any case, you should pay attention to the length and symmetry of the rays. The length of the beams is selected based on the diameter of the propellers used, so that after their installation the distance between the circles of the rotating propellers is at least 1–2 cm, and even more so these circles should not intersect. Motors mounted on the arms should be equidistant from the center of the frame, where the “brain” will be located, and (in most cases) be the same distance from each other, forming an equilateral polygon.

When designing, it is worth considering that the center of the frame must coincide with the center of gravity, so installing a battery at the rear between the beams is a bad idea unless it is compensated by a load in the front, such as a camera. Think about what your device will land on; for beginners, you can advise using something soft on the “belly” or ends of the arms, for example, dense foam rubber or tennis balls. And also protect the battery in case of an unsuccessful landing, for example by installing it between the frame plates or placing it under high landing skis.

Motors and propellers

Due to the rotation of the motors in different directions, it is necessary to use multidirectional propellers: forward rotation (counterclockwise) and reverse rotation (clockwise). Typically two-bladed propellers are used, they are easier to balance and find in stores, while three-bladed ones will give more thrust with a smaller propeller diameter, but will cause a lot of headaches when balancing. A bad (cheap and unbalanced) propeller can fall apart in flight or cause strong vibrations that are transmitted to the flight controller sensors. This will lead to serious problems with stabilization and will cause a lot of blur and “jelly” in the video if you are filming something from a quadcopter or flying in first person view.

Speed ​​controller, also known as ESC

Any propeller has two main parameters: diameter and pitch. They are designated variously as 10×4.5, 10×45, or simply 1045. This means the propeller has a diameter of 10 inches and a pitch of 4.5 inches. The longer the propeller and the greater the pitch, the more thrust it can create, but at the same time the load on the motor will increase and the current consumption will increase, as a result it can overheat and the electronics will fail. Therefore, the screws are matched to the motor. Well, or a motor for propellers, depending on how you look at it. Usually on the websites of motor sellers you can find information about recommended propellers and batteries for the selected motor, as well as tests of the generated thrust and efficiency. There are also propellers with variable pitch, which in theory will increase maneuverability, but in reality will add complex mechanics that tend to wear out and break, followed by expensive repairs.

Also, the larger the propeller, the greater its inertia. If you need maneuverability, it is better to choose propellers with a large pitch or three blades. With the same size, they create 1.2–1.5 times more thrust. It is clear that the propellers and their rotation speed must be selected so that they can create a thrust greater than the weight of the apparatus.

And finally, brushless motors. Motors have a key parameter - kV. This is the number of revolutions per minute that the motor will make per volt of voltage applied. This is not the power of the engine, it is its, so to speak, “gear ratio”. The lower the kV, the lower the speed, but the higher the torque. The more kV at the same power, the higher the speed and the lower the torque. When choosing a motor, they are guided by the fact that in normal mode it will operate at 50% of the maximum power. Don’t think that the higher the kV, the better; for copters with a typical 3S battery, the recommended number is in the range from 700 to 1000 kV.

Digitrode

Flying a quadcopter is a fun and interesting activity. The only thing that might be more interesting is creating your own control system for such a toy based on some popular platform, for example, Arduino. This is what the enthusiast under the nickname Dzl did. The first thing he did was take the remote control apart to see what kind of radio system it used.

Inside, as expected, were a couple of cheap circuit boards with few components on them.

Radio communication was provided by a small discrete radio module. After additional analysis and searching on the Internet, it turned out that the module is based on the BK2421 transmitter chip operating in the 2.4 GHz band. Today, in principle, most cheap radio-controlled toys are based on this module.

Thanks to the oscilloscope and the documentation for the chip, it was quite easy to find the pins through which SPI communication was carried out between the module and the rest of the remote control.

Thanks to “wiretapping” using Arduino UNO, the initialization order and communication mode became clear. there is an initialization order.

Without going into details of low-level communication, when you turn on the remote control and the quadcopter, the following happens:

1. The remote transmits its unique network address or ID

2. The quadcopter receives this transmission, confirms it and starts listening to the channel with data from this ID

3. After confirmation, the remote control starts transmitting data packets every 20 ms

You can control several quadcopters simultaneously by assigning them different addresses. ID transmission occurs on one fixed channel, and data is transmitted on one of 12 random channels. Quadcopters automatically scan radio channels until they find data.

Data is transmitted in an 8-byte packet in the following format:

Byte 0 = throttle 0-255 Byte 1 = Yaw 0-255 Byte 2 = Yaw_trim 0-128 Byte 3 = Pitch 0-255 Byte 4 = Roll 0- 255 Byte 5 = Pitch_trim 0-128 Byte 6 = Roll_trim 0-128 Byte 7 = Fly/run 0=fly, 16=run

Then a base station was created, which should communicate with the quadcopters. The modules used were RFM-70 containing the same BK2421 chip. It should be noted that the BK2421 pins are tolerant to 5 V, so additional resistors for 3.3 V do not need to be installed.

A special library was written to connect one or more quadcopters to Arduino. This library should work with any Arduino boards based on ATMEGA88 - ATMEGA328P chips. And at the end of the video:

Power and power controllers

The captain suggests: the greater the engine power, the more battery it needs. A large battery is not only about its capacity (read: flight time), but also about the maximum current it delivers. But the larger the battery, the greater its weight, which forces us to adjust our estimates regarding propellers and motors. These days, everyone uses lithium polymer (LiPo) batteries. They are light, capacious, with a high discharge current. The only negative is that they do not work well at subzero temperatures, but if you keep them in your pocket and connect them immediately before the flight, then during the discharge they themselves warm up slightly and do not have time to freeze. LiPo cells produce a voltage of 3.7 V.

When choosing a battery, you should pay attention to three of its parameters: capacity, measured in milliamp-hours, maximum discharge current in the battery capacity (C) and the number of cells (S). The first two parameters are interconnected, and when you multiply them, you will find out how much current this battery can supply for a long time. For example, your motors consume 10 A each and there are four of them, and the battery has parameters of 2200 mAh 30/40C, so the copter requires 4 10 A = 40 A, and the battery can produce 2.2 A 30 = 66 A or 2.2 A 40 = 88 A for 5–10 seconds, which will clearly be enough to power the device. Also, these coefficients directly affect the weight of the battery. Attention! If there is not enough current, then at best the battery will inflate and fail, and at worst it will catch fire or explode; this can also happen if there is a short circuit, damage or improper storage and charging conditions, so use specialized chargers, store batteries in special non-flammable bags and fly with a “beeper” that will warn of discharge. The number of cells (S) indicates the number of LiPo cells in the battery, each cell produces 3.7 V, and, for example, a 3S battery will supply approximately 11.1 V. It is worth paying attention to this parameter, since the speed depends on it engine speed and type of regulators used.

Battery elements are combined in series or in parallel. When connected in series, the voltage increases, when connected in parallel, the capacitance increases. The connection diagram of the elements in the battery can be understood by its markings. For example, 3S1P (or simply 3S) is three elements connected in series. The voltage of such a battery will be 11.1 V. 4S2P is eight elements, two groups, connected in parallel with four serial elements.

However, the motors are not connected to the battery directly, but through so-called speed controllers. Speed ​​controllers (also known as ESCs) control the rotation speed of the motors, making your copter balance in place or fly in the desired direction. Most regulators have a built-in 5V current regulator, from which you can power the electronics (particularly the “brain”), or you can use a separate current regulator (UBEC). Speed ​​controllers are selected based on the current consumption of the motor, as well as the possibility of flashing. Conventional controllers are quite slow in terms of response to the incoming signal and have many unnecessary settings for copter construction, so they are flashed with custom SimonK or BLHeli firmware. The Chinese have come to the rescue here too, and you can often find speed controllers with already updated firmware. Do not forget that such regulators do not monitor the condition of the battery and can discharge it below 3.0 V per cell, which will lead to its damage. But at the same time, on conventional ESCs it is worth switching the type of battery used from LiPo to NiMH or disabling the reduction in speed when the power source is discharged (according to the instructions), so that at the end of the flight the motor does not suddenly turn off and your drone does not fall.

The motors are connected to the speed controller with three wires, the sequence does not matter, but if you swap any two of the three wires, the motor will rotate in the opposite direction, which is very important for copters.

The two power wires coming from the regulator must be connected to the battery. DON'T CONFUSE THE POLARITY! In general, for convenience, the regulators are connected not to the battery itself, but to the so-called Power Distribution Module - an energy distribution module. This, in general, is just a board on which the power wires of the regulators are soldered, the branchings for them are soldered, and the power cable going to the battery is soldered. Of course, the battery does not need to be soldered, but must be connected through a connector. You don't want to re-solder the battery every time it dies.

On-board computer and sensors

The choice of flight controllers for copters is very large - from the simple and cheap KapteinKUK and several open source projects for Arduino-compatible controllers to the expensive commercial DJI Wookong. If you are a real hacker, then closed controllers should not interest you much, while open projects, and even those based on the popular Arduino, will attract many programmers. The capabilities of any flight controller can be judged by the sensors used in it:

The gyroscope allows you to hold the copter at a certain angle and is included in all controllers; the accelerometer helps determine the position of the copter relative to the ground and aligns it parallel to the horizon (comfortable flight); The barometer makes it possible to keep the device at a certain altitude. The readings of this sensor are greatly influenced by air flows from the propellers, so you should hide it under a piece of foam rubber or sponge; The compass and GPS together add functions such as heading hold, position hold, return to starting point and route assignments (autonomous flight). You should approach the installation of the compass carefully, since its readings are greatly influenced by nearby metal objects or power wires, which is why the “brains” will not be able to determine the correct direction of movement; sonar or ultrasonic rangefinder is used for more accurate altitude retention and autonomous landing; the optical sensor from the mouse is used to maintain position at low altitudes; Current sensors determine the remaining battery charge and can activate return to launch or landing functions.

There are currently three main open source projects: MultiWii, ArduCopter and its ported version MegaPirateNG. MultiWii is the simplest of them, requiring an Arduino with a 328p, 32u4 or 1280/2560 processor and at least one gyroscope sensor to run. ArduCopter is a project packed with all sorts of functionality, from simple hovering to performing complex route tasks, but it requires special hardware based on two ATmega chips. MegaPirateNG is an ArduCopter clone that can run on a regular Arduino with a 2560 chip and a minimum set of sensors: a gyroscope, accelerometer, barometer and compass. Supports all the same features as the original, but always catches up in development.

Advanced nine-channel remote control

The situation with hardware for open projects is similar, as with frames for copters, that is, you can buy a ready-made controller or assemble it yourself from scratch or based on Arduino. Before purchasing, you should always pay attention to the sensors used in the board, since technology development does not stand still, and the old ones somehow need to be sold to the Chinese, and besides, not all sensors can be supported by open firmware.

Finally, it is worth mentioning one more computer - PX4, which differs from Arduino clones in that it has a UNIX-like real-time operating system, with a shell, processes and everything. But we must warn you that PX4 is a new and rather crude platform. It will not fly immediately after assembly.

Setting up flight parameters, like the setup program, is very individual for each project, and the theory on it could take another article, so in short: almost all firmware for multicopters are based on a PID controller, and the main parameter that requires intervention is the proportional component , denoted as P or rateP. If during takeoff your copter twitches from side to side, then this value should be reduced, but if it reacts sluggishly to external influences, then on the contrary, increase it; you can find other nuances in the instructions and on the developers’ websites.

Homemade flying drone with a camera that follows you on autopilot (based on Arduino)

Step 1: Basic Properties

The drone operates almost completely automatically, you don't have to control it because it follows your phone, which is usually always with you, the ultrasonic sensor helps you avoid trees, buildings and other obstacles, and the GPS provides very accurate location data, but let's see what we end up with:

— 1000 mAh battery, enough for 16-18 minutes of continuous flight; - ultrasonic sensor to avoid obstacles in the air; — Bluetooth module for receiving data from the phone; — Microcontroller based on Arduino; — built-in gyroscope; — adjustable maximum height (5 m); — when the battery is low, the drone automatically falls on the phone; (it is advisable to hold the phone in your hands) - the cost of building a drone is about $100; - can be programmed for anything; — using GPS, you can send a drone to any coordinates; — design in the style of a quadcopter; — equipped with a 2-megapixel 720p HQ video camera; — weighs 109 g;

— Soldering iron; - Glue gun; - cutter; — Wire cutters; - Super glue; — Double-sided adhesive tape; — Rubber bands;

— MultiWii 32kB Flight Controller; — Serial GPS module; — Serial I2C converter; — Bluetooth module; — Ultrasonic sensor; — A piece of hard plastic; — Straws from a cafe; - gear; — Engines; — Propellers; — Screws; — L293D Motor Driver (this was a bad choice of driver, will be fixed in the second version); — 1000 mAh lithium-ion battery;

Step 3: Propeller Assembly

The master bought these propellers with motors on Aliexpress; they are spare parts for the Syma S5X drone, but they turned out to be useful for this homemade product.

Step 4: Circuit Diagram

Always look at the diagram as you work and be careful with connections. Step 5: Soldering the Motors to the Control Driver

Now you need to solder all the cables from the motors to the L293D motor driver IC. Look at the pictures, they say much more. You should connect the black and blue wires to ground and the positive wires to pins 1-4. The L293D can drive these motors, but the wizard recommends using power transistors because this chip cannot drive all four motors at high power (more than 2A).

Safety

All beginners, when thinking about safety, remember the AR.Drone and its propeller protection. This is a good option, and it works, but only on small and light devices, and when the weight of your copter begins to approach two kilograms or has long exceeded this figure, then only a strong iron structure can save you, which will weigh a lot and, like you you see, it will greatly reduce the load capacity and flight autonomy. Therefore, it is better to first train away from people and property that can be damaged, and as your skills improve, protection will no longer be needed. But even if you are an experienced pilot, do not forget about safety precautions and think through the possible negative consequences of your flight in emergency situations, especially when flying in crowded places. Do not forget that a failure of the controller or communication channel can lead to the device flying far away from you, and then a GPS tracker installed in advance on the copter, or a simple but very loud beeper, by the sound of which you you can determine its location. Set up and check in advance the fail safe function of your flight controller, which will help you land or return the copter to the starting point if the signal from the remote control is lost.

Features of the new model

The Tello quadcopter falls into the category of fun drones (fandrons) rather than camera drones. This little guy can do fun tricks and somersaults in the air that will be a lot of fun for younger pilots. Tello can be safely launched from the palm of your hand and placed on it automatically. Moreover, the launch can be done by lightly throwing the quadcopter into the air.

Tello has a number of pre-installed functions for photo and video shooting (for example, Circle Mode, 360 Grad, Up-and-Away). Image stabilization is done digitally, not mechanically. The built-in 14-core processor from Intel is responsible for this. The quadcopter takes 5 megapixel photos. In addition, Tello is compatible with VR glasses. And at the same time its weight is only 80 grams!

Among other things, the new product has a number of useful functions for flight safety. With just a swipe of your finger on the app, the drone can automatically take off or land. Using visual and audio signals, Tello warns you when your battery is about to run low.

Rating
( 1 rating, average 5 out of 5 )
Did you like the article? Share with friends:
For any suggestions regarding the site: [email protected]
Для любых предложений по сайту: [email protected]