Servers by jDrones

Soaring/Gliding for Planes

Hello, my Pixracer has finally been released from customs^^

I have a question about the configuration.
I imagine the following scenario.
I fly manually by FPV and am in sufficient altitude. Can I now switch on the soaring mode? Does it work? And if so, how do I have to configure it in the parameters?
Thanks for the information and assistance.

Hi Patrick,
as far as I understand the instructions (https://ardupilot.org/plane/docs/soaring.html?highlight=soaring) , you have to activate the soaring function in AUTO, FBWB or CRUISE mode.

Hi all,

The soaring feature has recently been improved for better stability, usability and performance. These changes are now available in the latest builds from within Mission Planner and will be in future beta and stable releases.

I’ve also added a small feature that isn’t in master yet and needs some testing - automatic learning of the glide polar parameters SOAR_POLAR_CD0 and SOAR_POLAR_B during a still air calibration flight. The method seems to work well in simulation and in early flight tests and should make tuning easier on new aircraft.

This only works if you are flying in still air with the new parameter SOAR_POLAR_LEARN set to 1 (set it to 0 again after the calibration flight). It’s still important to set the wing loading parameter SOAR_POLAR_K first by measuring all up weight and looking up the wing area. 5 seconds of data with zero throttle output, steady airspeed target and roll angle below 10 degrees are needed before any learning is done to minimize noise.

The best way to use this is with the RC switch for SOAR_ENABLE_CH in the middle position and with periods at several different airspeed targets - e.g. see attached plot from a simulated flight. This can be done either in FBWB mode using the throttle stick or in AUTO mode with DO_CHANGE_SPEED mission items - see attached example mission file (don’t load this directly as it’s in Australia!).

After the flight the log items PLRN.CD0 and PLRN.B show the convergence of the estimates, and the parameters SOAR_POLAR_CD0 and SOAR_POLAR_B will be updated to the final values.

CMAC-glidepolar.txt (1.1 KB)

I’m keen to see any logs involving this feature - the firmware builds are here (edited), let me know if you need a different board built.

Sam

1 Like

Hi Sam,
That seems to be very helpful. Could you build a FW for MatekF405-Wing pls?
I would like to test it if the stormy weather will change. Currently the RC-airfields are closed, but allone “on the green lawn” flying is allowed here.

Regards
Willy

Hi Sam, just a simple question, I am a bit confused about which board supports auto-Soaring function:

  1. Pixhawk 1 with 1 Mb. Flash ?
  2. Holybro Pixhawk 4.?
    Thank you…

@Quaxwilly I’ve built for the Matek boards and updated the link in my last post, hope you get better weather!

@ton999 Soaring is supported on all boards except the following:

  • KakuteF7Mini
  • KakuteF7
  • sparky2
  • Pixhawk1-1M
  • OMNIBUSF7V2
  • fmuv2

Sam

Ok.Tks. Sam. I like to try this function with Matek F765 or Holybro Pixhawk…

Hello

I’ve done several test for soaring. But I’m not able to get a stable glide.

I have increased PTCH2SRV_IMAX to 4000 and TECS_INTEG_GAIN to 0.3.

I have set SOAR_VSPEED to a large number 50, switched the SOAR_ENABLE_CH > 1700 and set flight mode to FBWB. The plane always tries to maintain the altitude, keeps the nose up until it is too slow, thereafter the nose goes down and everything begins again.

Which parameters are wrong?

Thanks for your help!

Hi Manauel,

Difficult to say, do you have a SD card log?

Thanks for your answer!

I’ve just rereaded the autotuning procedure.

Maybee my STAB_PITCH_DOWN parameter is too low? At the moment it is 2.
I try to increase it.

I will post a SD card log after next flight.

hello again!

Demanded Airspeed is 6 m/s. I think this is too slow!

ARSPD_FBW_MIN is 6 m/s. Should I increase this value?

I enhanced the ARSPD_FBW_MIN to 10 or 11.

But I have still the same problem:

Hi Manauel, can you post the log?

Hello Samuel

Thanks for your help!!

Here is the logfile:
Soaring active is from 14:29:

Hi Manauel,

I see you’re using a recent beta, but the recent soaring changes aren’t yet in the beta builds, only latest. So I’d recommend you use latest. The next beta will have the soaring changes.

The actual problem is that you have TECS_SPDWEIGHT=1.0, so the autopilot is raising the nose to try to climb and is stalling. The recent soaring changes override TECS_SPDWEIGHT to 2.0 internally when soaring is enabled and is suppressing throttle, so this is no longer an issue

Sam

Hi Sam

Thanks a lot for your help!

it workes now!
But it I had some problems to upload the FW. In Mission Planner (V 1.3.70) the stable FW for planes is still 4.05. And I was not able to upload the hex-file to my Pixracer. Mission Planner always asked if the destination board is a linux. After I hit no - there was a secend question - and finaly the update cancelled.

With QgroudControl it was not possible to upload a hex file. This program requires bin (and other files) *.hex are not supported.
I could finally install FW4.1 with QGroudControl via developper build.

I still have a question:
Which parameter is responsible for the glide-speed?
TRIM_ARSPD_CM???

Hi Samuel, Manauel.
Could you explain how you installed the firmware a little more. I tried to load the bl_hex file and also the normal .hex file with MP and Qgroundcontrol om my Matek F765 wing, but got errors.
Could you give some hints how to install via the developer build. Is there somewhere an explanation?
I am now flying with arduplane 4.0.5 but like to improve the thermalling on my Cirrus 3,5 m. F5J. (No contests of course).
Thanks, Maarten.

Hi Maarten,

Could you try to upload the .apj file please? I think this is the best one to upload.

Sam

Hi Manauel,

Yes TRIM_ARSPD_CM sets the glide speed in AUTO and LOITER. In CRUISE and FBWB modes it is set by the throttle stick with reference to ARSPD_FBW_MIN and MAX.

Sam

Hi Sam.

Thanks for the reply. I was succesfull on the first try with the .apj file. I downloaded it in my Radian Pro for testing. I am looking forward to test your program as soon as possible.
On the stable 4.0.5 it took me quite some time to tune all the parameters, but while flying in a thermal I had only occasional succes. Also the cruise mode while searching thermals did not behave as usual. Not tracking on course.

Maarten.

Servers by jDrones