Profile image

AAI Cyclone EF.2 ArAF

105k GuyFolk  3.1 years ago
72 downloads
Unlisted No Tags
Auto Credit Based on Beefy's AAI Cyclone EF.2 ArAF

Hi Beefy.
I look through your plane and have modify the code a bit.
- I think your code that lower the roll sensitive as aoa get higher is not enough and it does nothing to the plane when it start rolling. So I've modify the roll code to actually use roll rate into calculation and I also have the sensitivity of roll correction changing depend of the situation. ( RollRate/(x) which x will increase or decrease automatically )
- I assume your rudder code can inverse in the case of flying backward so I simplified for you and also I have the code correct for yaw rate instead of angle of slip because the plane is naturally stable at yaw axis so there is no need for it. So it'll somewhat smoother in the yaw axis.
- I've increased nose weight so it'll be more manageable at high speed, when at high speed and I suddenly pull up, the plane is so pitch unstable no FT code is enough to keep aoa low and then all hell break loose from there. Actually the roll problem is a part because the unstableness, because it is too much for the canard it make the plane go to higher aoa than comfort so it is super sensitive to roll.

And for how I used to write code, I follow some of my own rules lol.

I hope you understand a somewhat abstract concept like coding.
This is my form.
clamp( PID( Pitch, PitchRate/x (+/-) AngleOfAttack/y ,P,I,D) ,-1,1)
Yeah, you can mix and match those flight parameters, those will turn out according to the proportion of x and y and what is actually matters. (At high aoa, the aoa part is way larger than pitch so the aoa part will have more effect to the control surface)

Ps. Have you take a look to my Raptor? What I've said about the code in your previous post was implemented in my Raptor. And I hope the code is not too messy for you to read. #shameless advertisement

General Characteristics

  • Predecessor AAI Cyclone EF.2 ArAF
  • Successors 1 airplane(s) +280 bonus
  • Created On Windows
  • Wingspan 27.1ft (8.3m)
  • Length 44.3ft (13.5m)
  • Height 15.7ft (4.8m)
  • Empty Weight 30,103lbs (13,654kg)
  • Loaded Weight 36,448lbs (16,532kg)

Performance

  • Power/Weight Ratio 0.369
  • Wing Loading 87.4lbs/ft2 (426.5kg/m2)
  • Wing Area 417.2ft2 (38.8m2)
  • Drag Points 1224

Parts

  • Number of Parts 477
  • Control Surfaces 2
  • Performance Cost 2,191
  • Log in to leave a comment
  • Profile image
    105k GuyFolk

    @Beefy
    The problem is I don't know what inverselerp called in term of programming but it'll be just a simple linear graph and the slope will depend on range a to b in inverselerp(a,b,IAS).

    And also some tips for PID in rudder, it was PID(target,current,1,0,-1) which isn't do well because the D value was negative, I view D as damper so I use it like 0.1 so it'll not over-damped, your code was -1 so it'll do the opposite of damping and do it hard lol.

    +1 3.1 years ago
  • Profile image
    55.4k Beefy

    Is there any way lerp/inverselerp could be written in Desmos so that i could see it as a graph?

    3.1 years ago
  • Profile image
    55.4k Beefy

    @GuyFolk wow, your pid code is really conceptually simple! I am very impressed 😭

    3.1 years ago
  • Profile image
    105k GuyFolk

    @Beefy

    +2 3.1 years ago

This post is unlisted and upvoting is disabled.