Quadcopter with Arduino Uno running MultiWii
Here I will show you how to use Arduino Uno as a flight controller for your quadcopter. You will also need all other parts, described in Part I of How to build a quadcopter.
Essential part of every flight controller is the gyroscope/accelerometer sensor. So you need this one too for your Arduino flight controller. I used a Chinese GY-86 IMU for my build. This one comes with additional barometer MS5611 and compass HMC5883L. The GY-87 IMU is almost the same, only the barometer is different. Of course you can use any Arduino board, as well as IMU with only a MPU6050 gyro/acc.
First check how to connect all the quadcopter parts. If you have already mounted the propellers, please remove these for safety reasons. Fix the IMU to the frame. Then connect the receiver (RX) and the GY-86 IMU to the following pins of your Arduino Uno:
You also need to connect the servo cables from every ESC to the Arduino Uno. The cable from ESC Nr. 1 will provide power to the Arduino board. Connect not only the yellow signal cable, but also the ground (brown) and 5V (red). Note that your ESC should have an integrated BEC in order to supply 5V to the Arduino.
Once you have done all these steps download the latest MultiWii firmware. Unzip and open the MultiWii.ino file from the MultiWii folder. In the config.h Tab define that you are using the GY-86 IMU. Check the MultiWii manual in order to define some other variables. Then upload the saved sketch to your Arduino (it must not be connected to the battery of your quadcopter).
Start the MultiWiiConf.exe from the MultiWiiConf folder. Select the right COM port, click “Connect” and then “Start”. If everything is connected right, you should see a graphic of your quadcopter moving, when you rotate it. To change some of the numbers, do following: move the mouse cursor over the number you want to change, click and slide. Disconnect from the USB port, turn on your transmitter and connect the battery. Perform some tests without the propellers to check if all motors spin in the right direction.
Here is a picture of my build. It doesn’t look very nice on my frame, but that is the only one I have.
If you need more information visit the official MultiWii website. Although it is great fun using 8bit Arduino with MultiWii as a flight controller, there are much better and cheaper 32bit flight controllers using the MultiWii firmware. Have a fun with your copter and if you liked my article, share it :).