Accelerometer question for IMU Experts

I'm sure there's plenty of experienced IMU builders on this board who can resolve this question (see here: (starting at the 5th comment) and here: (starting at post #443) for more discussions). In fact the question may even have been answered here earlier (in which case I apologize for re-asking it, but I couldn't find it). The question has both a practical aspect in terms of IMU component & s/w design and a theoretical one in terms of trying to understand the relevant physics. Read carefully, because I don't think this is a noobie question.Assume a 3-axis accelerometer is mounted close to the center of gravity of a quadrotor with the Z axis of the sensor aligned reasonably well with the thrust axis of the rotors and the X and Y axes aligned with 2 of the arms of the quad. If the flying quad is at a non-zero bank angle (i.e. is rotated about the x-axis from a level hover), what will the Y axis accelerometers read? In this case, the vehicle will be accelerating laterally in the earth axes (and possibly vertically depending on the magnitude of the thrust vector compared to the gravitational one). One school of thought claims that the Y accelerometer in this case should read effectively zero (assuming that aerodynamic drag, vibration due to rotors, noise, errors due to sensor misalignment, coriolis and centripetal forces, etc. are either negligible or accounted for). The reasoning is that all the forces should be coming from the rotor thrust, which is always in the Z body axis for a quad. By a similar argument, the X axis accelerometer should also read zero for any pitch angle. (I think the argument holds to some extent for helicopters as well, but the force vector will not always be in the Z body axis direction due to rotor flapping.)The opposing argument is that there are plenty of quadrotors out there that use accelerometers to self-level, perhaps as part of a Kalman or complementary filter algorithm. It would seem unlikely for them to work as well as we know they do if the X and Y sensors were reading zero regardless of the vehicle tilt. How do we resolve this conundrum? Is the model of how accelerometers work flawed? I believe it is valid to model the resultant output of any accelerometer by determining the net force and subtracting the gravitational force vector. This works if the sensor is stationary (it will read as if it were accelerating away from the ground at 1 g), or if it is in free-fall (reads zero). Is this model correct in general for arbitrary motion? Are these other forces on the quad that I'm ignoring important somehow?I'd prefer if your answer includes one or more of the following: time history graphs of a FLYING vehicle (we know we can measure tilt of a stationary sensor), or a free body diagram, or a set of equations, or a reference to a textbook or paper. As I said, I'm trying to understand the physics of the situation.Here's a picture, if it helps: This shows the forces in the earth vertical axis as being balanced, but I don't think that condition is necessary for the X body axis accelerometer to read zero.Thanks in advance.- Roy
E-mail me when people leave their comments –

You need to be a member of diydrones to add comments!

Join diydrones


  • Hi guys, I came late to this debate its been 3 years. I read all your comments about what acce sensor measures and understand that it measures specific torques\accelerations, every force except the gravity.

    Here is m y situation, I have a 3 axis acce sensor on my Opilan sensor shield (APM kit v.1.4), check

    I also understand that the acce sensor is giving me reasonable responses due to rotation movements but not due to linear movements. I think acce sensor are more sensitive to linear forces rather than centripetal!!, am I right?.

    The centripetal force due to rotation causes an centrifugal acceleration and can clearly be observed through the terminal outputs of the acce sensor, but when I linearly move the board forward, backward, upward and downward aburptly, I just get trivial responses which also does not make sense in terms of axis movments. Why the sensor is responding accurately due to cetripetal force not the linear force Any comments? . Thanks

  • Brian,

    I was just wondering if you had found it necessary to pull out any of the fixed-wing specific compensation routines or if you had to do much tuning to get it to work in the tri.

    Good luck with DIYD competition.

    - Roy
  • T3
    Yes, I have the PicPilot installed in the Y-UFO and it's using the blended Gyro/Accelerometer DCM solution. I have the platform basically stabalized, but there is more work to be done. I've temporarily put it on the back burner while I get a second PicPilot running in my Easy Star clone. I'm trying to get far enough to make a run at the DIY Drones competition.

    The advantage of the blended solution over just accelerometers is that the accelerometers are not used instantaniously to determine the orientation. The gyros measure the instantaniouse change in orientation and the acceleromters are just used for a vary long time constant correction term. It eliminates many of the issues of an accelerometer only solution.

    I'll get back to the tri rotor soon and I can post some plots of teh DCM based orientation vs the straight accelerometer solution (both are floating around in the code)

  • @Tom,

    Yes, I've been following the DCM write-ups and UAV Dev Board progress. However, it is more suited to fixed-wing vehicles. I've also been reading the source material - the papers by Mahony et al - which are geared toward VTOL UAVs (probably quadrotors, but not necessarily).

    I do hope to implement the Mahony algorithm in my quadrotor someday, perhaps even using the quaternion solution. Before I read about that, I developed a complementary filter whic has been used (by others) in flying quads. Of course, it relies on using accelerometers to measure tilt and offset gyro drift.

    BTW, the Mahony papers don't mention any issue with the X & Y accels being zero. They acknowledge that the accelerometer measures the physical acceleration minus the gravity vector, and even that the rotor thrust is just in the body z-axis. They think that the vehicle will not be in accelerated flight for long periods, so it doesn't matter that the accelerometer is occasionally a degraded inclinometer. Quoting from the paper:

    For the sys-
    tems considered, there is no sufficiently good model
    of the system dynamics available to distinguish the
    body-fixed frame acceleration from the gravita-
    tional component. However, for the quasi-stationary
    fight conditions considered for VTOL mAV systems
    it is reasonable to assume that the low frequency con-
    tent of [the body acceleration] is zero. We assume that there is a cutoff
    frequency (typically around 0.1 to 1 Hz) below which
    the measured acceleration is a
    reasonable approximation of the gravitational force.


    If you're still listening - didn't you develop a tri-rotor Y-Ufo using your PIC32 board and the DCM code? Did you do anything fancy to code to make it work for a VTOL vehicle?

    I'll report back if a have any actual data to show you.

    - Roy
  • Brian,

    Quote: "I'm in 100% agreement that we are in 90% agreement. Actually based on your last paragraph I think were in 99% agrement as that has essentially been my stance all along. So I guess I'm in 95% agreement that we're in 90% agreement."
    This made me laugh!

    I think we are now in 100% agreement. I will get out a shovel to bury this poor horse...

    This was a great question. It got me thinking in a new way.

  • T3
    Hey Tom,
    I'm in 100% agreement that we are in 90% agreement. Actually based on your last paragraph I think were in 99% agrement as that has essentially been my stance all along. So I guess I'm in 95% agreement that we're in 90% agreement.

    I particullarly like your inclined plane story with the friction component. If you replace friction with drag you'll have exactly what my previouse posts are stating. As you accelerate lateraly the drag force will increase until the forces equalize at which point you can precisly measure your roll angle. The equations I describe (with the exception of the sign error that Roy found - Thanks Roy) will precisly describe what the accelerometers will measure(Ignoreing second order effects of noise misalignment ect..). No mystical ideas or faith based assumptions, just simple balancing of forces which is essentialy all an accelerometer does, measure the net forces along a given axis.

    I think that understanding is important, because at the end of the day I think if someone asked us to stabalize a platform using only accelerometers you would turn the job down and say it couldn't be done where I would say I can do that but there will some significant limitations. The inherent lag in error feedback would mean a slow control loop to avoid instability which would result in a platform that wandered around. It would be much better then no stabalization loop but could be improved upon greatly with the addition of other sensors such as gyros, GPS or tracker.

    I'm enjoying the conversation. I could see us discussing the issue while drawing diagrams on a napkin in Starbucks and enjoying a cappuccino. But I think at this point were down to semantics and have pretty much beat the horse to death. To avoid the risk of confussing or anoying people I'll go into a holding pattern on the subject unless someone has a specific question or wants to discuse augmenting the accelerometers with other sensors.

  • Brian,

    I think we are all in 90% agreement. We all agree that accelerometers alone are not sufficient for determining attitude for an aircraft in an accelerating state, which was the original point of this discussion (as I understand it). How to include other sensors, be they gyros, GPS, or something else, is fodder for another discussion.

    I will, however, defend my statement that an accelerometer cannot measure gravity. It does measure reaction (specific) forces from bodies in contact. For example, the Z-axis accelerometer on a level table measures not the (specific) force of gravity, but the reaction (specific) force of the table acting on the accelerometer. Thus, it measures an acceleration of 1 G in the upwards (positive Z) direction.
    Now put that accelerometer on an inclined plane such that the body-X axis is pointed "down". In this case, the Z-axis accelerometer measures less than 1 G and the X-axis accelerometer measures a non-zero negative value. Why? The friction force of the plane provides an opposing force in the body X axis that exactly opposes the component of the gravity force projected into the body X-axis. I am sure we all agree on this point.
    Now, sprinkle some magic physics dust on the inclined plane such that there is no friction between the plane and the accelerometer. What will happen? The accelerometer will begin to accelerate down the plane in the positive body X-axis direction. What will the accelerometers measure? The Z-axis will measure the same thing as before: slightly less than 1 G upwards. The X-axis accelerometer, however, will measure zero. Why? The only external force acting on the body X-axis is gravity, and this is exactly like the accelerometer in free-fall.

    Like I said before, if the body in motion (airplane, quad, rocket, etc) is in a steady-state (no net accelerations) then the only accelerations measured by an accelerometer will be the resultant forces opposing gravity. The roll and pitch angles are therefore easily calculated. If the body is not in steady-state, then accelerometers alone can not provide the pitch and roll.

  • T3
    You state that the accelerometers wont measure gravity, only the thrust. In reality accelerometers only measure specific force. This force can be generated by acceleration or by a gravitational field. The only time a gravitational fields force goes to zero is when a body is in free fall. I'm sure you will agree that when an acceleromter is sitting on a table it will read 1 G in the upwards direction. One perspective of this is that it's measuring the force of the table pushing up on the acceleromter. If thats your perspective that's fine, it works. I'm sure you would also agree that if you had a two axis accelerometer sitting on a table and rolled it over 90 degress that now the y axis acceleromter would read 1 G up, and for every angle in between 0 and 90 degrees you would get a reading in both accelerometers of a varying ratio depending on angle. That ratio can be used to determine the angle of roll.
    Now consider that instead of a table you are suspending the acceleromters from a string. Would they not behave in exactly the same way? Now instead of a string imagine the acceleromters are supported by a column of air. Wouldn't they still behave in the same manor? As long as the acceleromters are not in free fall they will measure the force of gravity, and the ratio of the two sensors can be used to determine orientation.
    What we have shown though is that the roll estimate is corrupted by lateral acceleration be it from thrust or wind or a banking turn.
    I'd be happy to talk about possible ways to correct this I'm just not sure where this is headed. As has been pointed out gyros can do wonders in several ways when combined with the DCM approach and/or a kalman filter. Even when used straight for rate dampening they can have a positive impact on the problem.

  • 100KM
    not true i found that when accelerating it can cause drastic errors in pitch estimate therefor i estimated changes in speed using gps then applied it using the COS of the angle of the pitch axis therefore canceling out the error due to changes in speed. yes this is more pronounced and in all 6 directions in a heli but the theory and math is the same .if you want a definitive answer and don't think i understand because my imu was developed for airplanes then ask jackcrossfire he has developed an imu just for quads however their probably is a good reason he has not commented on this .any way enough idle chatter back to work for me.
  • Wayne.

    Tom understands the problem.

    In a quadrotor (or any rotorcraft where the rotor cannot move independently of the body), non-zero pitch and roll immediately cause lateral acceleration that cancels out the acceleration of gravity on those axes.

    In an airplane, that doesn't happens because you reach a steady-state velocity quickly.

    This is such a counter-intuitive topic that this conversation could go on forever; occasionally someone new joins the fray who hasn't thought about it yet, and then the cycle repeats. :-)
    See related links to what you are looking for.
This reply was deleted.