Profile image

Having issues with an AutoHeading code

1,221 Novaxomix  yesterday

i am attempting to build a simple V1 missile, and the issue i am havinng is getting the thing to turn to a variable heading then holding it without oscilations. It uses only rudder inputs to do this , as the V1 had only that in real life as well. have spent around 6 hours now trying every method i can think of including using a PID controller, only for none of the options i have to work.

(HeadingIWant-(HeadingIWant>180?-360:0)-(CurrentHeading-(CurrentHeading>180?-360:0))/30)*(233.63/IAS)+(Trim/10)/(-YawRate)

  • Log in to leave a comment
  • Profile image
    1,221 Novaxomix

    @OverlordPrime this worked, thank you

    +1 15 hours ago
  • Profile image

    Find target heading relative to your v1. Then
    deltaangle(v1heading, target heading) /35
    Out this in the rudder, invert control if necessary
    You can change the 35 depending on how sensitive you want it to be.

    +1 yesterday