cover

WiFi JR-module to control ARDrone2

This is yet another project with the versatile ESP-8266 WiFi chip. I have an ARDrone2 and a Turnigy 9X transmitter ( flashed with the awesome ER9X firmware). The ARDrone2 is usually controlled with a phone or tablet over WiFi. This gives very bad control performance so I want to fly it with my Turnigy 9X. I've made a prototype of which the production process is described here. But first a nice video of the end result:

Prototype module assembly

The first step is to find a piece of proto-board and a female pin header that fits onto the pins of the transmitter.

For this module, I'm going to be using a NodeMCU board. This one is very good for prototyping because it has a USB port, but also a voltage regulator which I will be using. I also added some female pin headers for the NodeMCU.

Now it's time to make the connections. This is the schematic of the necessary connections:

It is important to check the voltage of the CPPM signal, because this differs between transmitter types. If you want to be sure that it does not destroy the ESP module, use a MOSFET like I did for the final version. In this case, I implemented a cheap and easy voltage divider with resistor values 6.8k and 3.3k, which gives me approximately 3.4V.

I also included a separate LED, because the NodeMCU will be facing down when its inserted. Put it in series with a 330 ohm resistor.

On the other side, the LED is soldered. I also added a thick yellow wire, which is not connected to anything. This thing helps me to remove the module from my transmitter.

Flashing the firmware

The prototype is now ready, time to try it. It is incredibly easy to make firmware using the Arduino IDE. A board support package is available for the NodeMCU board, so the right settings are configured automatically. First, I uploaded a blinky to test the LED. It worked :)

Now that the blinky code works, its time to upload the real thing. The firmware is open-source and can be obtained from github. Upload it and fly!

Update over the air

The firmware can also be updated over WiFi. Theoretically this is also possible from the Arduino IDE, but I had troubles detecting the module usually. Fortunately its also possible to call the python script directly. First, the firmware image needs to be built by pressing Ctrl+Shift+S in the Arduino IDE. Both the computer and the module need to be connected to the ARDrone2 (which acts as a router). When enabling the transmitter, you need to hold the aileron-elevator stick in the top-right position. The new firmware can then be uploaded with the following command:

python ~/.arduino15/packages/esp8266/hardware/esp8266/2.1.0/tools/espota.py -i txboxy.local -r -f ~/git/TXBoxy-AR/TXBoxy-AR.cpp.generic.bin

The procedure is also demonstrated in the following video:

From prototype to product

Because the prototype worked so well, I decided to make it nicer. I designed a custom PCB, ordered plastic cases and smaller parts and put it al together. A friend of mine designed a nice logo for it and we opened a small webshop for it. So if you would like to fly your ARDrone2 with your own transmitter, but don't like to solder a prototype together like this, check out txboxy.com.

Comments

ciro mitubashi - February 10, 2019 at 5:45 pm

please i need , chanel for setup

1 elev 2 aile 3throtle 4rudder 5aux 6aux1

type.this

please inform map for channel