Next Generation Tilt Sensor/ Attitude Monitor

The Rocketry Forum

Help Support The Rocketry Forum:

This site may earn a commission from merchant affiliate links, including eBay, Amazon, and others.
Actually the greatest rotation rates in a rocket flight is roll (spin). Which can be an order of magnitude greater than the relatively slow turn at apogee. Apogee turns are easy. You need accurate roll position to determine tilt. In other words you need to accurately integrate all 3 rotation axes.

All 3 can be integrated pretty accurately with today's gyros.

Questions for the OP to ponder.
1. Are you using small angle identity in your quaternion commutation? If so, don't or use more than the first term in the Taylor expansion approximation.
2. How often are you normalizing your position quaternion?
 
Last edited:
Actually the greatest rotation rates in a rocket flight is roll (spin). Which can be an order of magnitude greater than the relatively slow turn at apogee. Apogee turns are easy. You need accurate roll position to determine tilt. In other words you need to accurately integrate all 3 rotation axes.

All 3 can be integrated pretty accurately with today's gyros.

Questions for the OP to ponder.
1. Are you using small angle identity in your quaternion commutation? If so, don't or use more than the first term in the Taylor expansion approximation.
2. How often are you normalizing your position quaternion?
What we’ve both been doing is arguing in the absence of using the actual apogee quaternion and other MCU data that gave rise to the this thread’s contention of a 30 degree error at apogee.

I’d like to see the actual sequence of apogee data before further speculation about its cause.

I’ve read that MPU-9250 magnetic compass readings can be off by 30 degrees unless tilt corrections have been correctly applied. And we do know that the rocket’s tilt angle is typically changing rapidly at apogee.

So it would be helpful to see the detailed 9DOF data before going on. Otherwise it’s diagnosing a cause without considering the necessary evidence.
 
What we’ve both been doing is arguing in the absence of using the actual apogee quaternion and other MCU data that gave rise to the this thread’s contention of a 30 degree error at apogee.

I’d like to see the actual sequence of apogee data before further speculation about its cause.

I’ve read that MPU-9250 magnetic compass readings can be off by 30 degrees unless tilt corrections have been correctly applied. And we do know that the rocket’s tilt angle is typically changing rapidly at apogee.

So it would be helpful to see the detailed 9DOF data before going on. Otherwise it’s diagnosing a cause without considering the necessary evidence.
Dan, that's far but:

9 DOF for determining rocket attitude is unnecessary at best and error inducing at worst.
The 3 acceleration DOF's are totally useless once the rocket is flying because there is no gravity reference to use in a filter.
The 3 mag DOF's are very noisy, not easy to calibrate and should only be used to attempt to correct for the zero offset drift of the gyro's.
3 DOF gyro readings on my device alone provide a 1 degree error up to a 60 second flight.

If you have a 30 degree error after a relatively short duration flight the most likely causes are:
1. Incorrect zero offet value
2. Badly drifting zero offset value.
3. Incorrect rotation integration algorithm.
4. Incorrect configuration of the gyro.

As UhClem pointed out earlier selecting a 30Hz high pass filter is wrong. At apogee the turn rate will be less than 30Hz and totally not sensed by the gyro. In this case its not the apogee turn was too fast, it was too slow.
 
Last edited:
I’d like to see the actual sequence of apogee data before further speculation about its cause.
The cause was pretty obviously the use of a high pass filter on the data. Besides removing most of the important flight data it also makes measuring the gyro zero offsets impossible.

In any case, here is my attempt at quaternions.
 
Dan, that's far but:

9 DOF for determining rocket attitude is unnecessary at best and error inducing at worst.
The 3 acceleration DOF's are totally useless once the rocket is flying because there is no gravity reference to use in a filter.
The 3 mag DOF's are very noisy, not easy to calibrate and should only be used to attempt to correct for the zero offset drift of the gyro's.
3 DOF gyro readings on my device alone provide a 1 degree error up to a 60 second flight.

If you have a 30 degree error after a relatively short duration flight the most likely causes are:
1. Incorrect zero offet value
2. Badly drifting zero offset value.
3. Incorrect rotation integration algorithm.
4. Incorrect configuration of the gyro.

As UhClem pointed out earlier selecting a 30Hz high pass filter is wrong. At apogee the turn rate will be less than 30Hz and totally not sensed by the gyro. In this case its not the apogee turn was too fast, it was too slow.
The 30 degree error resulted from the data! You’re not wanting to look at the data to see how the error came about??!!

You’ve listed high rocket axial spin as more significant in this error than changes in tilt. But looking at the data would support or discount this assertion. Let’s look at the data (along with the conditions under which it was collected) to see what the problem was.

If something is pretty obvious the data should support it.

Otherwise we’re just pounding the table on opposite sides.
 
In any case, here is my attempt at quaternions.
This was an interesting presentation, but its main focus were the details and problems of 32kSPS MPU-9250 data collection and logging rather than a justification of the need for it.

The actual signal contained in the data was clear at a much lower frequency than 32kSPS.

I'm using quaternion differentials at about 500Hz. It seems to work OK shortly after liftoff, but by apogee I'm off by as much as 30 degrees.
Closely looking at this seems to mean that this is a tilt calculation that’s derived from an accumulation of quaternion differential measurements.

Additionally
I'm doing rotation updates at 500Hz which is pretty quick, and the accuracy seems to drop off right when the rocket is flopping over.
— this indicates that the 30 degree tilt error primarily occurs at apogee, and not during the much longer ascent time during which the tilt results are also being calculated.

Since there’s no indication that a rocket’s roll rate increases at apogee, how can gyroscope crosstalk from roll axis be the main contributing cause for the 30 degree error since most of it happens at apogee.

While I have not yet done a detailed analysis of the MPU-9250’s data sheet regarding gyroscope axis crosstalk, I still think it would help to see the actual launch data and the conditions under which it was collected.

From my past experience as a developer of embedded scientific data collection modules, there might even be a problem with error accumulation with summing small numbers into large ones using simple floating point, especially over many seconds at 500SPS and above, especially if floating point calculations are used. The mantissa information of the small number gets truncated so the error in resulting sum shows increasing error. Such problems are easily remedied by converting the data to long 32 or 64 bit integers with the data’s lsb of resolution before summing.

One way to simply test whether its a small number summing problem would be to reduce the data collection rate from 500 to 50SPS and see if the characteristics of the calculated tilt error changes.

If there’s a constant crosstalk contribution from the gyroscopic roll axis, the tilt error should be relatively flat, instead of growing during apogee.

My point here is that error problems can be difficult to resolve and might require looking in many places.
 
Back
Top