Thursday, June 21, 2012

Quadcopter: Inertial Position Tracking - RIP

Yep, you read that title right. IPT is dead.

After playing with my sensor for the last few months, I finally opened up an excel spreadsheet to figure out what kind of accuracy I need to make IPT work. Using some rough figures, I need a sensor that is at least 1000x+ more sensitive & accurate than my current one. One set of numbers I used suggest that 5000x is probably closer to what I need. Another way of looking at this is that my current sensor has a resolution of roughly 0.004g while I need something closer to 0.0000008g. There are sensors which provide ~2x more resolution, but clearly that is not going to be sufficient. Sensor drift over time and temperature will also be a significant issue. Similar accuracy issues exist with the gyro unit.

A second issue is that it's is quite likely that the sample rate needs to be much higher than the 800Hz I am currently using, but this is just a guess. One way to deal with noise is to sample at a rate that is high enough that it can be fully described by the data, and as such cancels itself. The other way is to use math, possibly a frequency domain filter. In the case of a filter, extremely low signal distortion is a must due to the super high degree of accuracy needed to keep the position tracking accurate over a long period of time.

The high degree of resolution needed to track position requires a processor that can handle very precise numbers very quickly. The 32bit floating point numbers supported by the Arduino libraries are accurate to 6-7 decimal digits of accuracy (the ATmega328 has no built in float support). To keep the accuracy needed for IPT there needs ~10+ digits of accuracy. This would require either doing the math in 64bit float (a "Double" - accurate to ~15 places) or maybe as a 32bit fixed point number using a custom library to avoid precision loss during operations. The Arduino would be horribly slow processing 64bit floats and I'm not inclined to write a custom fixed point math library at the moment. The easy solution to this problem is going with an ARM processor. This would provide a fantastic increase in processing power compared to the Arduino.

Although using my current hardware will not work to create an inertial position tracking system, I have not given up on the concept. I intend to look into using analog sensors paired to external high speed 24bit A/D converters and see if that will provide the needed accuracy. Sensor drift will still be a concern, but I think some of the ideas I have for controlling their temperatures will help a lot.

At this point I have completed the physical build of the quadcopter and am 99.9% done with programming. It will be controlled with the typical multicopter control scheme. Stability testing and tuning will begin this week. My next post will cover this current status more completely.

That is all for now. Let me know if you have any questions.

Thanks for reading and please sign up on the right if you want to be automatically notified when I post more updates.