Table of Contents

The beetles. Let It Fly!

Authors

Project Description

Basically the project is intended to build and “flash” a multicopter provided from the assets of Electrical Engineering School and the ARCOS-Lab. Prior to carrying out these processes is necessary to learn how to do it properly, so it is an essential first phase of study and research about the artifacts to use and software tools to make it work. At the end of the project is expected to have the multicopter running and also be able to explain how it was and what knowledge is obtained and applied during the process.

Objectives

General Objective

Specific Objectives

   

Methodology

Building

We are going to explain step by step the process that we follow to build the hexacopter. The type that we are building is a Y6 multicopter, that means it have three bars supporting the six engines (two for each bar) in a Y distribution, all the engines rotate to the same side, but one is placed over other so for real effects they rotate to the opposite side. We are not using a complete kit (this kits came with all the parts to make the building easily) so we have to make or change some pieces to make them work. Here is the explanation:

  1. Preparing the supporting bars: the supporting bars must be of the same dimensions and materials, the lighter and strongest material is better. For a properly fly we align and mark them to cut all with the same length.
  2. The sides of the supporting bars should be carefully sanded to remove the rough edges after they were cut and does not have problems putting them together with the other parts of the estructure, in this case we used a fine sandpaper.
  3. Preparing presses: we use red presses (a pair on the top and another at the bottom) the top ones are to secure the engines to the supporting bar, but this presses have some holes smaller than we need, son we use a table drill to make them a little bigger.
  4. Engines supports: this black support have to be connected directly on the bars, we have to make modifications on this supports with the drill because they does not have enough holes and also we need a special holes for a flat headed screws cause we want this screws does not create a relief.
  5. This is how the presses has to be located and how the engines supports has to look with the flat headed screws on them.
  6. Base platforms: we need a couple of platforms to place the controllers, the distribution and control cards, the battery and some other things that we could need. So this platforms were made with acrylic in an octagonal shape and with the size we need. Then we use a draw to make the necessary holes in the platform of the hexacopter on the right places, the platforms are not part of any kit, they were created for this specific work.
  7. This is how the platform looks after make the holes, now it has to be filed. Then the base brackets can be placed.
  8. Filing the platforms: this is the “step by step” image example about how put all the structural pieces (this is just for show how it looks like, we have to disarm to place the rest of the pieces after, but the base is ready).
  9. Power distribution card: we use an Hextronik card, we add some connectors to the cards and change the cables for a more resistant ones, they were welded to the card and are ready to be used. In the second image we can see that the card have to be centered on the platform.
  10. Controllers and regulator: now the engine controllers can be connected to the distribution card and the x5 UBEC (regulator) can be connected to. The connectors have to be flashed to make them work how we want and the regulator is to control the output of energy and avoid damages on the card and the controllers.
  11. Then we use this multi-porpouse tape to secure the controllers and the distribution card to the platform.
  12. Placing the engines: the supports are ready, but we have some problems to place the engines, first some nuts clash with the presses second we can not screw correctly one engine of each pair. So we have to modify the nuts with a grinder so that they fit and we modify an allen wrench to so that could enter between the support cross and the engine.
  13. The next step was really hard, is put the screw using the allen wrench and the modified nut and let them tied, make this with the three pairs of engines.
  14. Now we can connect all the controllers with the engines and secure all the cables on the supports, here are some images about the process.
  15. Controllers, receiver and control: using the control (ER9x) we can start the receiver (Fr Sky), first read the datasheet of the Fr Sky here http://www.frsky-rc.com/ShowProducts.asp?id=126 to be sure that you are doing it well.
  16. After that we have to flash the controllers to make them work how we want with the engines, to this we need the Advance Pro card, this card have some options that we can select according to our wishes. So we connect a battery to the distribution card, here we connect the controllers and the x5 UBEC and the controller that we are flashing and the UBEC have to be connected to the Advance Pro correctly. Following the controllers datasheet instructions we can made them work and with this the engines are working to.
  17. Before to continue with the final adjustment, here we have the battery and the charger, it is extremely important to be careful with the LiPo battery because it is very dangerous.
  18. Now we can disconnect the Advance Pro and connect all the controllers with the receiver and the distribution card, we are going to prove them with the control and see them work correctly.
  19. Finally we have just to put the cover platform, place the controller card already flashed centered on the upper cover and the battery under the lower platform, secure everything and it is ready.

Flashing

This section is about flashing the flight controller board using the MultiWii software, this is completely open source and is getting updated constantly, so it is important to look out for new versions of the software periodically. MultiWii is used to configure the “behavior” of the copter using the specific sensors of our board, most of the options stay on default, but some others have to be changed.  

  1. First we need to download all the software files to our computer before begin installing anything. At first we download the Arduino program, it is essentially a tool that allows us to edit and flash the MultiWii software,  the version of the Arduino we use is the latest one, Arduino 1.0.4, which is on this page http://arduino.cc/en/Main/Software , after decompress the file we run the arduino, for this is necessary have installed “openjdk-7-jre”, then the arduino can run.
  2. After the Arduino we need to download the MultiWii software that will be flashing the controller board. In this case we want to work with the “bleeding edge” to get the latest functions added and you can follow the instruction here https://code.google.com/p/multiwii/source/checkout but a part of that code have some errors, so you can fixed or search a previous version, they does not have so many differences.
  3. Now we run the Arduino and on it open the MultiWii software to flash it. Once open the Arduino, click on File > Open and a file browser pop up. Search for MultiWii > MultiWii > MultiWii.ino. Once we get to the “.ino” file, click open and Arduino load the program. After that we have this screen:
  4. What we want first is to modificate the config.h, so we select it from the top of the panel and it shows all the configurable parameters to make MultiWii compatible with the hardware on your controller board. Here we are going to show the most relevant parameters for us, because the configuration is really large and it change for all different board.
  5. The first step is select what type of multirotor we have, just uncomment the line deleting the two “/” behind whatever you want to select and the color of the text will turn to to black. To deselect something you simply type two “/” behind whatever you want to deselect and its color will turn back to gray. In our case we select the “Y6” configuration. Type of multicopter > #define Y6
  6. Then we set MINTHROTTLE= 1150, MAXTHROTTLE = 2000, MINCOMMAND = 1000 and I2C_SPEED = 100000L, just make sure it is ok.
  7. Next step is to select the flight controller board, MultiWii give us some options by default, on the “bleeding edge” the MWC 328p or “Holybro”which is the one we are using is not on the default options, so we leave this step and have to select the independent sensors individually. But on the previous version the Holybro is present so you can select it and the sensors are already selected.
  8. This are the sensors we choose. I2C gyroscope: #define ITG3200, I2C acelerometer: #define BMA180, I2C barometer: #define BMP085, I2C magnetometer: #define HMC5883.
  9. Those are the main changes that we do to the config.h, we review all the other options and just make sure they are correct, there are so many other configurations for a better flight but we just use this for make it basic. So then we save the changes.
  10. So now the MultiWii is ready to be uploaded on the board, before to connect the board we need to add our user on the dialout group and configure the serial port /dev/ttyUSB0. To configure the serial port we use minicom, after install it, we execute it o the terminal “minicom -s”.
  11. Edit the serial port setup.
  12. And save the configuration as default.
  13. Press exit, no exit from Minicom, then the serial port is ready. Now we can connect our board to the computer and it is going to be recognized by the Minicom. Once this happen we go to the Arduino and the MultiWii.ino again and compile it (checking for any error), then we do the upload, this will take a few seconds and finally it is flashed.
  14. After the flashing, a file named MultiWiiConf is used to test the behavior of the sensors but we are not there yet, but it looks like this.

Special thanks