A rudder is used to steer the aircraft when it moves through the air, controlling the direction in which the aircraft is pointing. It is a flat sheet of material attached with hinges to the craft’s stern, tail, or after end.
An aileron is a hinged flight control surface, usually attached to the trailing edge of each wing of an aircraft. Ailerons are used in pairs to control the aircraft in roll, or movement around the aircraft’s longitudinal axis.
Elevators are flight control surfaces, usually at the rear end of an aircraft, which control the aircraft’s longitudinal altitude. The position of the elevator controls whether the nose of the airplane is pointing up or down, and accordingly the plane moves up or down. The elevators are usually hinged to a fixed or adjustable rear surface.
Input supply wire of ESC is connected to 11.1V battery. Three output wires of ESC are connected to three-phase inputs of BLDC motor (M4).
Arduino UNO is programmed using Arduino IDE software. ATmega328 on Arduino UNO comes with a boot loader that allows you to upload new code to it without the use of an external hardware programmer. It communicates using the STK500 protocol.
You can bypass the boot loader and program the microcontroller through in-circuit serial programming (ICSP) header, but using boot loader programming is quick and easy. Select the correct board from ‘Tools -> Board’ menu in Arduino IDE 0022 and burn the program (sketch) through standard USB port in the computer.
We used Red Brick ESC module. If you use any other ESC module, you may have to modify delays in the code accordingly.
Programming an XBee
Several communication programs are available for programming an XBee, such as procontrol, xterm, pcu, X-CTU, even putty, but among these X-CTU is the easiest, Windows-based graphical program, though it takes longer time. But once you master X-CTU, you can quickly connect XBee to any other communication program and do the reprogramming of your XBee through short AT commands.
Download X-CTU from the Internet and install it on a Windows PC. Position the XBee on the Explorer board and connect it to the USB port of your PC. Fire up X-CTU and see whether it detects the device or not.
The two XBees can be made to communicate with each other freely and precisely through X-CTU software. The X-CTU has four tabbed windows: PC settings, Range test, Modem and Configuration. In PC settings window there are three sub-windows located at the bottom: Host setup, User com ports and Network Interface. In case you have not found your right com ports, you can click Network Interface and then Digi Device Discovery to find your device.
Press Test/Query button on right side of the same PC Settings window and see what XBee it discovers. Check Enable API box because we will use this feature in Coordinator Xbee (XB1). Now come to Configuration window where most of the settings need to be made.
In Configuration window, click on Read button and your screen will start showing lots of data. Do not get alarmed; you need to configure only a few parameters.
Click on Always Update Firmware, as this will keep the XBee updated with the latest software. In Function Set pull-down menu select XBee Coordinator API. In Version pull-down select the highest number. In Networking parameters window find the personal area network (PAN) parameter, and give it a 4-digit number, say, 7821. Do not give 1234 because most people use this number. In case another person is experimenting with XBee in your area, you both will collide in the air space for bandwidth.
For communication between two XBees, one has to be made Coordinator and the other a Router. Here we are preparing the Coordinator XBee (XB1).
Coming to the Addressing parameter at DH and DL, these are called the High and Low addresses. DH is a 32-bit address written on the XBee itself. Enter this parameter here. In most cases, it is the same number for all generic XBees: 0013A200 (find out yours to be sure). Just below this number you will find another 32-bit number inscribed on the XBee. This is the DL number.
The DL parameter is to be switched between the Coordinator and the Router; the Router number to be entered into the Coordinator and vice versa. After doing that check Write and the setup will be written in your Coordinator XBee. See the message below. You may need your Internet connection on now. When it is over, ‘finished’ message will appear at the bottom.