Alan Kharsansky's Posts (4)

Sort by

Be careful with the new DJI landing gear!


Hi Everyone! I just wanted to share my bad experience with the DJI legs. I bought a few weeks ago, the addon landing gear for the F450 from DJI (Link here). The looked really cool :-D (at first). Look:


So I wen't to the park very happy to test my new altitude hold algorithm. After a while I have a bad measurement on the ultrasonic sensor, and the system performed a very hard landing. The result: the four arms of the F450 broke on the same place in the same way. I think this is due to a very bad design of the landing gear attachment.






Read more…

Hi! I have uploaded a set of three new videos explaining 3 basic principles of the quadrotor. In this case I'm using my own board, theFLCv2.0 ( but the concept may apply for other quadrotors and autopilot systems too).

First of all: why do we need controllers on the quadrotor and the effect of the different modes of flying:

Then two different ways of reference tracking:

And the coolest part: perturbation effects and rejection

Read more…

Firmware update: now it's flying!

Hi everyone!

First I would like to thanks to all the people that commented, see, and shared my work. I'm really happy you enjoyed it.

Now the important part. I've been very busy on the firmware and the flight software. The board is still the same :D. T he system is doing very well and the attitude autopilot is working great. Here is a video of the last version working:


The system is doing these things concurrently:

  • 200 Hz update of the PIDs. 3 are for angular rate control of the 3 axis, and 2 more are added on the pitch roll axis to control the attitude. (the magnetometer isn't used right now so I have no reference of true north and that's why I've decided to only control angular rate on yaw axis)
  • 50 Hz reference input axis via xBee. The GS sends the setpoints for the pitch and roll angles and the yaw angular rate. Also it is controlling the collective (altitude) control manually and it also sends the dead man switch signal for the watchdog.
  • 20 Hz telemetry download via xBee. Including: gyros, attitude in Euler angles, controls outputs, motors mix. Later I will add altitude (barometric and ultrasound) and battery level. Also any other usefull sensor.

As I promised, here is the schematic


Note: I have to add a small fix for connecting the MPU data ready signal to one of the IRQ based input of the extra sensor inputs of the board. Also a capacitor was added on the reset line of the MCU.


I'm now fully focused on finishing my thesis, but I hope in a month I will be back again and will upload the source code to Github, and other related stuff too.

Also if you would like to use a PID controller in your embedded project (arduino too) you can check my qPID control library. It lack a user manual yet but I added an usage example file that I hope is self explanatory.


Read more…

Quadrotor Flight computer FLCv2p0


This is my first post in DIY Drones. I would like to share with the comunity my last work related to UAVs. I'm currently working on my thesis for graduation as an electronic engineering at the University of Buenos Aires. My thesis is based on a embedded control system and in this post I'm presenting the Flight computer that holds the control algorithms. 

My thesis is more an academic research than a hardware/software project, but I decided to do my own powerful board to test it. 

Above is the FLCv2p0 (Flight computer v2.0). The first version was a homemade attempt and now this is the new version

These are the details of the board:

  • LPC1769 Cortex M3 @ 120 Mhz microprocessor wtih 512KB of flash and 64 KB of RAM
  • Two side PCB board with mounting holes (almost) compatible with DJI Flamewheel frame
  • 4 intefaces for arms: this is a ESC output and a multipourpouse input output conector with servo pinout that serves as output or input in digital, analog, or Timer capture mode for measuring frecuencies and periods (ideal for tachometers)
  • 2 other arm interface without connector for 2 extra motors
  • Two power options: USB for developing and testing and an external input (the blue one) for direct battery input. Up  to 40V can be input, then there is a stepdown high effiecncy switching regulator that regulates to 3.3v needed for all the board. There is no need for BEC (the +5V pin of the arms is unconnected cause it always cause problems and the DJI OPTO 30A that I'm using doesn't have a BEC anyway.
  • The USB port can be programmed for any USB device application
  • microSD card slot via SPI
  • Indicators: 1 led power indicator, 1 small green led for status or anything else and 4 high power sideleds for beacon and directional ligths (maybe white leds would be nice)
  • Sensors:  The is a I2C network on the board with: MPU6050 Accelerometer and gyroscope with data fusion integrated, HMC5883 magnetometer (slave to the MPU but could be bypassed), BMP085 Barometer (can be used as an altimeter), LM60 temperature sensor, 128KB EEPROM for configuration saving, 
  • Xbee Radio: is it possible to fit an Xbee standard on PRO
  • Programming: could be made via JTAG or with the built in serial bootloader via Radio (slower but very useful)
  • SPI, I2C and UART headers for external devices, sensors, etc.
  • Real time clock with calendar (implemented by the LPC1769 but there is an external crystal for clocking)

About the firmware:

I'm currently working on my thesis firmware and the simulator (on MATLAB). Cause it is not ready at all I would prefer not to publish it yet. But, I wrote a small tester firmware for all the devices that will give you an example on how to use  them, and also have a very small "template" for starting. The board is perfectly capable of running FreeRTOS (which I'm using extensively) and the IDE I'm using is the LPCXpresso Free IDE (128KB flash limit now).

Some videos:

First flight: it is a little buggy, it was my first ever flight of a RC thing (be gently :) ) and was only fliying with Gyros so no attitude controlling was made.

MPU Motion fusion testing:

And some pictures:

Ground station:

My ground station is now a xbee via USB and a PS3 joystick via bluetooth. The GS is not something I'm proud of it yet but is getting into shape slowly.

My idea now is to publish the schematics of the board open to everyone, and even the PCB files. Maybe later the firmware when I have a stable version (of course the small templates will be on github soon). I'm not wondering to be the responsible for quadrotors breaking (I broke my yesterday . I'm also thinking in selling this board already assembled (in china where I manufactured the PCBs) to easy the people acces to this board. I'm not sure if it is a great idea yet.

Currently the board is not intended for people looking for a Ready To Flight option, exactly the opposite  But I'm sure that there are people out there that make use of this kind of stuff (Arduino for example :D) and I would like to share my work with them as they do with me.

Thank you!!


Read more…