Help setting up Arace Griffin QuadPlane in SITL with Realflight Evolution SOLVED

I am trying to set up SITL to fly the Arace Griffin QuadPlane RealFlight model with 4.3.1 stable. I have most of the basics working (see below), but the plane flies like it’s possessed.

Can someone help me understand what I have missed?

I got the RFX file and parm file from here:

Loaded the model into RealFlight Evolution and turned on “RealFlight Link” (which seems to be what they call flightaxis now) - and started SITL using This works, SITL starts and connects and I get the little green messages in RealFlight saying that it is connected.

The command I used to start SITL is

tools/autotest/  --debug --lldb \
        --f flightaxis:realflightpc.local \
        --aircraft=Griffin --frame=quadplane \
        --out=udp: --console --map

After everything settled down, I typed the following commands in to and watch the fun (not) of ArduPilot trying desperately to loiter, failing and then crashing.

param load Griffin.parm
arm throttle
rc 3 1700

This was the result:

Have you loaded another plane to test ? also did you load the Pram then save and refresh then save? I have a VTOL called Diamond that you could try in Github WIP.

I did the first rev of the VTOL Griffin model post improvements. Try: Start RF then load MP go to simulation flightaxis click on the plane icon. that should connect MP to RF hit the spacebar. load the plane and setup the config using the Pram file save refresh and save. Make sure RF is setup correctly like background pause to no.

1 Like

I loaded the Griffin and I have issues not like yours but with the motors. I think it best if you ask Andrew to review.

1 Like

As per above, I loaded the param file using using

param load Griffin.parm

When you say “setup the config using the param file” - I’m assuming that you mean this?

mavproxy doesn’t have a “refresh” for params, so I just loaded the file again.

param load Griffin.parm

So now I have this,

a big improvement, but not stable enough for autotune tor run, I’m getting this:

AP: AutoTune: Yaw Rate D Up 0%
AP: AutoTune: failing to level, please tune manually
AP: AutoTune: Yaw Rate D Up 0%
AP: AutoTune: Yaw Rate D Up 0%
AP: AutoTune: failing to level, please tune manually
AP: AutoTune: Yaw Rate D Up 0%
AP: EKF2 IMU0 switching to compass 1
AP: EKF2 IMU1 switching to compass 1
AP: AutoTune: Yaw Rate D Up 0%
AP: AutoTune: failing to level, please tune manually
AP: AutoTune: Yaw Rate D Up 0%
AP: AutoTune: failing to level, please tune manually

So I decided the PIDs were wrong (not that I really understand them), so I started manually changing them just to see what would happen. Guess what - massive improvement. Basically the Q “P” values for Roll and Pitch were way too high. I manually set them as follows:

param set Q_A_RAT_PIT_P 0.1
param set Q_A_RAT_RLL_P 0.1

And suddenly the plane was stable enough that autotune would run. It now looks like this:

So I successfully completed autotune of all three axes and got the following new gains:

Q_A_RAT_PIT_D    0.0017924299463629723
Q_A_RAT_PIT_I    0.11233694851398468
Q_A_RAT_PIT_P    0.11233694851398468

Q_A_RAT_RLL_D    0.0010000000474974513
Q_A_RAT_RLL_I    0.10434277355670929
Q_A_RAT_RLL_P    0.10434277355670929

Q_A_RAT_YAW_I    0.10013037919998169
Q_A_RAT_YAW_P    1.001303791999817
Q_A_RAT_YAW_D    0.0

which are quite different to the ones that I loaded from Griffin.parm from GitHub - specifically

Q_A_RAT_PIT_D    0.005000
Q_A_RAT_PIT_I    0.100000
Q_A_RAT_PIT_P    0.150000

Q_A_RAT_RLL_D    0.003000
Q_A_RAT_RLL_I    0.250000
Q_A_RAT_RLL_P    0.200000

Q_A_RAT_YAW_D    0.020000
Q_A_RAT_YAW_I    0.100000
Q_A_RAT_YAW_P    2.000000

I then loaded VTOL-quicktune.lua and ran successfully, which generated the following:

Q_A_RAT_PIT_D    0.002890312112867832
Q_A_RAT_PIT_I    0.09230741858482361
Q_A_RAT_PIT_P    0.09230741858482361

Q_A_RAT_RLL_D    0.0022393492981791496
Q_A_RAT_RLL_I    0.08301571011543274
Q_A_RAT_RLL_P    0.08301571011543274

Q_A_RAT_YAW_D    0.010000008158385754
Q_A_RAT_YAW_I    0.10279499739408493
Q_A_RAT_YAW_P    0.4999999403953552

Try VTOL-quicktune.lua BTW can you load another VTOL?

One more: SITL_Models/RealFlight/WIP/Brandon/Tuvak at master · ArduPilot/SITL_Models · GitHub

I wanted to use the regular autotune because the real plane I want to test this in (T1 Ranger VTOL) has a FC that doesn’t have enough memory to run Lua.

Thanks for your help @Quadzilla , I now have it working and tuned nicely. I’ve proposed some changes to the wiki docs about SITL/RealFlight to reflect what I’ve leaned which boils down to:

  • Performance is CRITICAL. If the machine running RealFlight is underpowered it will not just look bad, it will actually affect the simulation as SITL tries to cope with the weird behavior caused by jerkiness of the simulation in RealFlight. I bought a new PC - it made a huge difference.
  • It seems like the Griffin.parm gains for Q_A_RAT* may need to be updated. At least what I saw (see above) is that the gains in the file were not good. I’m not sure if this is due to RealFlight Evolution, or maybe my setup, but it definitely wasn’t just a case of “load and go”.
  • QAUTOTUNE keeps reporting “failing to level, please tune manually”, but this is misleading. If there are not too many of these messages, you can let it finish and it will improve the tune. Even more interesting, if this happens, run the QAUTOTUNE again - and it will get a better tune. I ran the tune about 3 times on each axis to get it rock solid.

Very cool can you share you Parms file on Discord I like to fly it.

Here is a video of the Griffin flying after QAUTOTUNE and AUTOTUNE. Flies nice!

And here is the parm file -
Griffin-2022-12-08-autotuned.parm (32.1 KB)

Hello @timtuxworth @Quadzilla

I am new to RealFlight and just about to order Real Flight, please advice what version can be used with Ardupilot? I read on their website , now is version 9 Evolution…old version 8 is no more available.
Can I use Frsky Q7 or D9 ? I don’t have other RC than Frsky… Do I need special cable from the Frsky to my PC ?

I really want to do SITL using Mission Planner like you did.
Thank you for your help.

Hi @ton999 , it took me a while to figure out that RealFlight is the best way to go for ArduPilot simulation. But since I did, I’m very happy with it. Go for the very newest one - ReaFlight Evolution, and definitely don’t go earlier than 9.5S.
Honestly to make it as easy as possible, spend the extra couple of $ to buy the package with the “InterLink DX” controller. It’s only for RealFlight, but will save you a lot of messing around.
I use RealFlight wth my EdgeTX Jumper T-Lite, which took a bit of setting up, and I think it might be possible to configure to run with your FRSky transmitters if they have a USB connection to the PC that can run in joystick mode, but that’s a question for FRSky.

Make sure your PC is newer with reasonable performance and a good graphics card that supports DirectX.

Hi @timtuxworth
Thank you for your quick response…
I will do as your advice…
My best regards

This conversation was what the kick I needed to order and install Realflight for settting and tuning my Vtol :slight_smile:

@timtuxworth I took me some time to realize that call was not OK
–f flightaxis
it should be

Here is my startup --model=flightaxis: --aircraft=Griffin --frame=quadplane --console --map

Not sure what you mean about not OK. It definitely works for me, but I’ll try your suggestion.

The redundant usage of -f and —frame that are the same parameter

Yes I found that confusing. But look at the docs, -f is specifically documented to set flightaxis but is also used for Frame ( --frame is frame, -f is also frame but also flightaxis,). So I found by testing that -f can be used for flightaxis and --frame for frame. It makes no sense to me that --model is for flightaxis.

See here in the section on “Connecting to SITL running on a separate machine.”

Yes I agree the documentation is misleading and this is why I reported back with a working command fhat can make the SITL corretly connect to RealFlight

Hi, One repeatable issue is where only rebooting the computer will fix and starting back up flightaxis on my machine. You still can connect sometimes but the Prams don’t fully update. I just had this issue a few days ago so if an issues seem to be plaguing you restart the computer and update Prams.

1 Like