I have been in R&D phase of UAVs for past some time, especially self-stabilization algorithms.
It may sound a dumb question but comparing DCM vs Kalman Filter, is that a fair comparison?
My understanding was that Kalman filter is used to smoothen the IMU signals and calculate precise Roll and Pitch angles. While DCM (Direction Cosine Matrix) is something (blackbox for me for now) which is actually the stabilization algorithm (as if Kalman Filter readings are fed into DCM to determine the attitude of the flying vehicle).
Then suddenly I read somewhere (I think another post of DIYdrones) that Arduino is not capable of Kalman Filter, so DCM is a better choice.
It has tunred my so-far acquired concepts upside down ;-)
Can anyone please explain the above two to me and also if there is really a connection in between them or they are rather different approaches to solve the same problem?
I wished I had been an engineer, sounds embarassing asking such a fundamental questions.
But beleive me, I am truly after it. It's so damn interesting and appealing.
Wished I could advise. I've never built a flying autonomous vehicle. For that matter, I've yet to build a functioning autonomous ground vehicle. I do agree that an off-the-shelf IMU/AHRS solution is the best way to go vs. trying to roll your own with limited experience. You can always work up to that point, but sometimes it is easier to get there if you first experiment with someone else's solution.
Thanx a lot
Your "thought" right on the "spot" ;-)
I am from Computer Science background, so I wanted to work on those areas first where I can apply my acquired skills. I shall definitely learn control theory and advanced dynamics and all related sciences, but at a slightly later stage.
Let me give it a try, will keep you guys updated
I think, developing a UAV simulation in, e.g., Matlab / Simulink, from scratch might be a better place to start, if you really wan't to understand how things work. I see the learning process the following way:
I was following this discussion and this site in general with great interest.
After reading some documents in the internet the conclusion I came about the general process of attitude estimation as follows.
Please correct me if I am wrong here.
1. In first place acceleration and angular rates are taken in to the system
2. Because these sensor inputs are so noisy the inputs are added together to get more accurate measurement.
For this approach fusion mechanism is needed and here is the place the complementary filter/ Kalman filter comes in to the role.
3. Attitude measurements found from above is related to the aircraft body itself.
ie: we cant still see the attitude with respect to the earth ( If we rotate the aircraft in a axis 20 degrees irrespective to the initial possition the attitude we get is 20 )
4. Then this attitude estimation can be used to find the attitude of the aircraft with related to the earth.
To this only the Eular method, DCM or quartarnian methods been used.
If there is something wrong in my understanding can anyone please point this out to me.
Thanks a lot in advance.
Ad 2. Yes and no. Yes, the sensor measurements obtained from cheap gyroscopes and accelerometers are quite noisy. Generally, in case of very slow rotating and non-accelerating objects, 3-axis accelerometers alone would suffice to obtain angular orientation - basing on gravity measurement, which always acts towards Earth's center. But in case of a UAV which is not slow rotating or non-accelerating also linear and centrifugal accelerations would be measured and added to gravity measurement which occludes raw gravity vector. In the long run, though, with some low-pass filtering, this still provides a noisy, but non drifting rotational orientation information. As in case of an autopilot we need precision and high frequency attitude estimate, this is where gyroscopes come into play. Because gyroscope measurements include a time-varying bias, this bias cannot be easily eliminated (e.g. via subtraction). As gyroscopes provide angular rate measurements, this signal needs to be integrated to obtain angular orientation. This is how gyroscope-drift arises. So information obtained from those two sensors, if fused, gives us an attitude estimate without drift (thanks to accelerometers) and fast enough (thanks to gyroscopes). The role of a complementary filter (called DCM by some) is to provide means to estimate gyroscope drift from accelerometer measurements and eliminate it (to put it simple)
Ad 3. Yes - a strap-down gyroscope provides angular rate measurements expressed in the body frame. Yes and no - a strap-down accelerometer measures inertial frame accelerations expressed in the body frame.
I very much recommend the lecture of Direction Cosine Matrix IMU: Theory by William Premerlani and Paul Bizard, if you haven't read it yet. It's written in an understable fashion without too much mathematical language, so it's intended for a reader like most of us here.
I really do appreciate your reply. Thanks a lot for that.
Your comments confirmed what i thought before. actually my language skills are not good enough to ask exactly what i want. :)
I read that draft document and i following this site with great interest.
where does one find such files like the pdf you linked?
I am very interested in a deeper understanding of the functioning of the ardupilot mega, maybe a code explanation/manual....