OpenRocket active 6DOF fin stabilization and guidance extension?

sadara

Member
Joined
Oct 31, 2022
Messages
6
Reaction score
1
Location
Perth, WA
Does anyone have a script (preferably JavaScript or python) for fin based active stabilization and path following?
I have the 1DOF ( Degree of freedom ) roll stabilization code, and it would be trivial to extend this to 3DOF stabilization, but I figure I will ask before I try for full 6DOF.
Ideally, this would allow me to roughly tune the PID parameters of the flight computer before trying to launch real hardware.

In case anyone is wondering why you would want to do this, there are two main reasons:
Firstly, 3DOF stabilization allows you to reduce the stability margin to 0% (or even less if you are brave/stupid). This means you reduce drag by shrinking the fins, and also allows you to reduce mass by removing ballast, reducing rocket length, and shrinking the fins.
Secondly, active guidance (full 6DOF) can allow the rocket to fly along a nearly straight path directly upward from the launch rail, allowing significantly higher altitudes to be reached.
 
Last edited:

lakeroadster

Improvise, Adapt and Overcome
TRF Supporter
Joined
Mar 3, 2018
Messages
6,453
Reaction score
6,634
Location
Central Colorado
Does anyone have a script (preferably JavaScript or python) for fin based active stabilization and path following?
I have the 1DOF roll stabilization code, and it would be trivial to extend this to 3DOF stabilization, but I figure I will ask before I try for full 6DOF.
Ideally, this would allow me to roughly tune the PID parameters of the flight computer before trying to launch real hardware.

In case anyone is wondering why you would want to do this, there are two main reasons.
Firstly, 3DOF stabilization allows you to reduce the stability margin to 0% (or even less if you are brave/stupid). This means you reduce drag by shrinking the fins, and also allows you to reduce mass by removing ballast, reducing rocket length, and shrinking the fins.
Secondly, active guidance (full 6DOF) can allow the rocket to fly along a nearly straight path directly upward from the launch rail, allowing significantly higher altitudes to be reached.
DOF?

DOF.jpg
 

sadara

Member
Joined
Oct 31, 2022
Messages
6
Reaction score
1
Location
Perth, WA
Be nice, not everyone knows the nomenclature for this stuff. It is especially bad for non-native English speakers.
 

Titan II

Well-Known Member
Joined
Aug 23, 2013
Messages
1,464
Reaction score
576
Be nice, not everyone knows the nomenclature for this stuff. It is especially bad for non-native English speakers.
1. The person I responded to is not a non-native English speaker.
2. The person I responded to dishes out a lot of crap to others. Actually, I owe him one.
3. I am not sure what you mean by "In case anyone is wondering why you would want to do this, there are two main reasons."
4. We have been flying active stabilization for years.
 

lakeroadster

Improvise, Adapt and Overcome
TRF Supporter
Joined
Mar 3, 2018
Messages
6,453
Reaction score
6,634
Location
Central Colorado
You do not know what that means? You are joking. Right?

I have some ideas... but no, I didn't know specifically what it means.

That's why I asked.

1667223520894.png



OOP... Out Of Production... I hate the use of acronyms when the OP (Original Poster) doesn't clarify at it's first usage.
 
Last edited:

Banzai88

Lvl 2, Wallet..even more destroyed
TRF Supporter
Joined
Jul 15, 2015
Messages
3,414
Reaction score
1,825
I had zero idea what DOF was, either, even though I have read over some of the various active stabilization threads. I presumed from context that it had to do with stabilization, and turned to the Google : Google Results on 3dof stabilization searches

Upon realizing what it was, I also realized that any answer I would have is well beyond my technical scope.
 

Chad

Well-Known Member
Joined
Jul 23, 2018
Messages
414
Reaction score
249
Location
Dallas
I'm not aware of any but it sounds really cool. Read through the "I could just use a little guidance" thread, if anyone has something like that they would be in that thread.

 

sadara

Member
Joined
Oct 31, 2022
Messages
6
Reaction score
1
Location
Perth, WA
3. I am not sure what you mean by "In case anyone is wondering why you would want to do this, there are two main reasons."
I meant for there to be a ":" rather than a "."

Do you have any simulation code for OpenRocket?
I'm going to roll my own guidance computer, IMU, telemetry system, and quaternion autopilot, but I need to figure out the basics of fourier rates and dynamic response before I start.
 

sadara

Member
Joined
Oct 31, 2022
Messages
6
Reaction score
1
Location
Perth, WA
DoF = degrees of freedom

For example, 6DOF is typically accelometers and gyros. 9dof adds magnetometer. 10dof adds a baro sensor.
Not quite what this means in this context, and it is a bastardization of the term at the best of times. When talking about autopilots and control, I always felt that sensor channels should be called something else, not DOF. It is very easy to reach 20 channels of data, for example XYZ accel, UVW gyro, XYZ mag; Airspeed, Mach, baro, UW AoA pitot + Air temp and humidity; GPS based XYZ position and XYZ doppler velocity (absolute ground speed, which is needed to compensate for wind drift); gets you 22 channels, but I wouldn't call it 22DOF. These 22 channels are the standard for most aircraft autopilots, and are pretty simple to implement in a tiny autopilot.
 
Last edited:

heada

Well-Known Member
Joined
Jan 18, 2009
Messages
5,513
Reaction score
2,911
Location
Indianapolis, Indiana
Not quite what this means in this context, and it is a bastardization of the term at the best of times. When talking about autopilots and control, I always felt that sensor channels should be called something else, not DOF. It is very easy to reach 20 channels of data, for example XYZ accel, UVW gyro, XYZ mag, Airspeed, Mach and static barometric pitot, UW AoA pitot or vane, Air temp and humidity, XYZ position and XYZ doppler velocity (absolute ground speed, which is needed to compensate for wind drift) from GPS gets you 22 channels, but I wouldn't call it 22DOF. These 22 channels are the standard for most aircraft autopilots, and are pretty simple to implement in a tiny autopilot.
And the vast majority of those are not used in rocketry and are irrelevant. Nearly all of flight computers are 1DOF (baro) some few add accel to give 4DOF. There are a handful that are used for active flight control that also add gyro and mag for 10DOF. There may be 1 or 2 that also directly use GPS but most that include GPS only use it as a secondary source since they are restricted above specific velocities unless you somehow get an unrestricted one ($$$$)

aircraft are not rockets and rockets are not aircraft. I wish you luck in your search.
 

sadara

Member
Joined
Oct 31, 2022
Messages
6
Reaction score
1
Location
Perth, WA
And the vast majority of those are not used in rocketry and are irrelevant. Nearly all of flight computers are 1DOF (baro) some few add accel to give 4DOF. There are a handful that are used for active flight control that also add gyro and mag for 10DOF. There may be 1 or 2 that also directly use GPS but most that include GPS only use it as a secondary source since they are restricted above specific velocities unless you somehow get an unrestricted one ($$$$)

aircraft are not rockets and rockets are not aircraft. I wish you luck in your search.
No one uses GPS directly, even military GPS is far to slow. I've made several autopilots based on the above, and they are all relevant for rocket flight. I think I will actually need 2 sets of accelerometers for a model rocket, because the G forces have far to much dynamic range during launch.
From your reply above, are you implying that the Airspeed, AoA, Air Temperature and humidity are unneeded? How do you compensate your control system for transitions into transonic and supersonic?
 

Alan15578

Well-Known Member
Joined
Feb 11, 2018
Messages
774
Reaction score
273
Not quite what this means in this context, and it is a bastardization of the term at the best of times. When talking about autopilots and control, I always felt that sensor channels should be called something else, not DOF. It is very easy to reach 20 channels of data, for example XYZ accel, UVW gyro, XYZ mag; Airspeed, Mach, baro, UW AoA pitot + Air temp and humidity; GPS based XYZ position and XYZ doppler velocity (absolute ground speed, which is needed to compensate for wind drift); gets you 22 channels, but I wouldn't call it 22DOF. These 22 channels are the standard for most aircraft autopilots, and are pretty simple to implement in a tiny autopilot.
That is better than your first post. For rigid bodies it is just 6 DOF. Additional degrees of freedom could be for control fin or gimbal angles, structural deflections. etc. Channels has nothing to do with DOF, just the number of data streams. Autopilots and navigators generally include several state estimators, as well as filters, and guidance and control laws. If you have sufficient CPU capability you can often get by with cheaper sensors and more state estimators. Adding sensors is good, but you are not adding degrees of freedom. On the other hand, marketeers are selling to hobbyist consumers, not control engineers, so they will abuse the terminology any way that tends to boost sales.
 

alexzogh

Well-Known Member
TRF Supporter
Joined
Sep 30, 2010
Messages
958
Reaction score
599
Location
Northern Virginia
Having traveled down this rabbit hole more than once I really recommend a 9 or 10DOF IMU (intertial measuring unit for those that don't know) that also has a DMP (digital motion processor). Calculating the quaternion vectors from the raw outputs to derive the 3d values necessary for true 3d orientation that is necessary for active stabilization is very taxing on a small CPU, as well as your brain. A DMP can just spit out the calibrated 3d values using sensor fusion algorithms. Many also have good code libraries that get you very far down the field in development. You can spend your time and effort on the fun stuff.

Then again, having mastered quaternion math, it was very satisfying, but I wouldn't recommend it to garage electronics makers.
 
Top