Profile image

Gyroscopes that hold roll and pitch angle?

349 YiddleHoot  3.9 years ago

I've been messing with funky trees a lot lately and can't figure out how to make a gyroscope(s) that holds the plane's roll and pitch angle instead of leveling out.

  • Log in to leave a comment
  • Profile image

    Go to the xml of the gyro, to the input of pitch, type smooth( Time*Time, Pitch)
    Same for Roll

    2 months ago
  • Profile image
    26.7k ToeTips

    @hpgbproductions
    Okay thanks again!

    1.3 years ago
  • Profile image

    @ToeTips no, it controls pitch only. You can try to control AoA by putting the whole plane on a rotator, with the gyro on that rotated section.

    1.3 years ago
  • Profile image
    26.7k ToeTips

    @hpgbproductions
    Oh okay true. Too much FTs will be a problem. One more question, could this be used to hold a 30 to 45 degree AoA preferably for landings?

    1.3 years ago
  • Profile image

    @ToeTips sure, but be careful as you can get controls that are unnatural, or unexpected by users

    1.3 years ago
  • Profile image
    26.7k ToeTips

    @hpgbproductions
    Can I use this on a elevator? To stop the craft from pitching when no inputs have been inputted?

    1.3 years ago
  • Profile image

    Just wondering sort of related to this thread but was making a vertical weapon stabilizer for tanks and stuff, using only a rotator (using the rotator horizontally) instead of a gyro and found using @hpgbproductions code I was able to get it to work, (any attached block to the rotator would always be oriented to 180degress), but was trying to figure out if you get the rotator to still be able to rotate like a normal rotator using the VTOL side bar whilst keeping the stabilization

    1.8 years ago
  • Profile image

    @FlickerDefenseIndustries compare a target stored value with the current heading and use that to control your gyro

    1.9 years ago
  • Profile image

    @hpgbproductions how about for yaw

    1.9 years ago
  • Profile image

    @CyanWasNotTheImpostor Ok I'm lost. The plane still levels out on its own despite which setting it's on. I don't understand your comment it's just not what's happening lol

    3.9 years ago
  • Profile image
    25.9k OwO

    @YiddleHoot unno
    auto orient should mean to orient it to be level automatically rather than you doing it manually

    3.9 years ago
  • Profile image

    @DerpTheSoyacfartala I'm sure, I think auto-orient affects how the force of turning the gyro works, like global vs local, I could be wrong tho

    3.9 years ago
  • Profile image
    25.9k OwO

    @YiddleHoot are you sure?

    3.9 years ago
  • Profile image

    @DerpTheSoyacfartala you mean auto orient? Turning it off still makes the plane rotate to a level position

    3.9 years ago
  • Profile image

    kek i rigged up something
    activation group 1
    pitch: smooth(-PitchAngle/180, Activate1 ? 1000 : 0)
    roll: smooth(-RollAngle/180, Activate1 ? 1000 : 0)
    .
    The smooth() function locks a value defined in the first argument when AG1 is on
    .
    example (copy the yellow part in the middle of the plane)

    +1 3.9 years ago
  • Profile image
    25.9k OwO

    change the gyros default settings, there is options to it doesn't do that

    3.9 years ago
  • Profile image

    @BagelPlane I did that but the plane keeps spazzing out, I sorta got it to work with smoothing sum(Roll-or-Pitch) but pitch and roll don't work together well, basically the end result should be a gyro you can add to a plane without control surfaces and still fly like it did have them

    3.9 years ago
  • Profile image
    24.1k BagelPlane

    Just use PID controllers.

    +3 3.9 years ago