Servers by jDrones

Tuning large 36Kg X8 drone - seeking advice


(chuckntaylor) #1

I have been working on the construction of a rather large X8 drone which has an AUW of 36Kg. The test payload in this scenario has been 20lbs.

Details of configuration:
T-Motor U11 120kv motors in an X8 coaxial configuration.
T-Motor 26x8.5 props
T-Motor 80A Flame ESCs
Pixhack flight controller with firmware 3.3.2
Mission Planner: 1.3.37
4x 22Ah 6s battery packs. These are being used in two series pairs to run the motors at 50V

The 50V power is going through a UBEC in order to power the flight controller with 12V, as 50V was rated too high for the PM sensor. I instead use telemetry via the transmitter/receiver to monitor system voltages.

This past weekend the weather was good enough to go out and do some flying. We tried to auto tune the system in order to improve its performance. But this has resulted in a lot of oscillations. After conducting an auto tune, the system seems perfectly fine. I then land the aircraft with the auto tune channel still high, and disarm in order to save the PID values. Then when I go to fly again, the system oscillates aggressively - even though the values were not doing this prior to landing and confirming the saving.

This problem may be echoed in this forum thread:
http://ardupilot.com/forum/viewtopic.php?f=80&t=11884
Some people blame firmware 3.2 and indicate that problems went away after reverting to 3.1. However, I am on firmware 3.3.2.
I do not know if these problems continued in 3.3, or if there is anything related to the problems they are describing.

Because the auto tune takes a very long time for this particular machine (almost 10 minutes per axis), I end up doing each axis at a time while auto tuning. For reference, I have provided links to videos and DataFlash files from each step taken. All DataFlash files can be downloaded here:
https://drive.google.com/open?id=0BwfUwlVJAYMJbVRMZUlLeWpVXzA

I first started off performing the auto tune on just the roll axis. Video of this can be seen here:
https://vimeo.com/159745457
The dataflash file from this flight is titled ‘2016-03-20 - 01 Auto tune Roll Axis’.

After saving the new PID values for the roll, I went to perform the auto tune for the pitch. However, when I took it into the air, the system had extreme oscillations on the roll axis. Even though the PID values were fine at the end of the roll auto tune - as before landing these values are active so that the user can test them to see if they like it. However, once the controller has been cycled and the PID settings saved, heavy oscillations occurred. You can see this behavior in this video:
https://vimeo.com/159745461
Dataflash file - “2016-03-20 - 02 Oscillations Roll Axis”

The wiki indicates that if I am seeing vibration, to try lowering the ‘RC_FEEL’ value in the software to a value of .25
As the default is 50, I first tried a value of 25. This change had no effect, so I tried .25
This too had no effect, and so I reset it to 50. I then took a screen shot of the PID values for the roll axis, reset them to default, and then moved on to trying the pitch axis.

The pitch axis went the same. Video can be seen here:
https://vimeo.com/159745458
DataFlash file - ‘2016-03-20 - 03 Auto Tune Pitch’

As you will see at the end of the video, after landing and saving the PID values, the system shows extreme oscillations on the pitch axis. Again the PID values are documented, and then reset to default in order to proceed with the next axis.

We then did the yaw axis. Video is here:
https://vimeo.com/159745459
Dataflash file is titled ‘2016-03-20 - 04 Auto Tune Yaw’

Once again, at the end of the video you will see the resulting PID’s after landing and saving results in extreme oscillations.

To see the PID values each axis auto tuned with, check out the screen grabs in this folder:
https://drive.google.com/folderview?id=0BwfUwlVJAYMJVnZ4VnVHTzJ1ZEU&usp=sharing

Probably my biggest concern when flying the machine is the fairly rapid loss in altitude when changing position in the roll or pitch directions. When in ‘altitude hold’ mode, the system goes down on an angle whenever I attempt to fly it around the field. And so we tried to adjust the ‘Altitude Hold’ gains manually. We moved the default of 1.0 to 1.2, to 1.5, and finally 2.0. I could not see any improvement, but we unfortunately ran out of batteries by this point. It did feel that landing the aircraft became more challenging as the value increased, but it is hard to know for certain.
Video of these trials can be seen here:
https://vimeo.com/159745667
DataFlash file is called: ‘2016-03-20 - 05 Altitude Hold Adjustments’

My next thought is to assign the ‘P’ value of each axis’ PID value to a channel 6 knob on the transmitter in order to manually adjust the gains during flight in order to try to dial out these oscillations. This may also prove to be a good way to try and improve ‘altitude hold’ performance. I see a lot of people saying poor altitude hold performance is often due to vibration issues on the flight controller. However, the values in the dataflash logs (except when the oscillations occur) seem to be pretty good I think. I think vibration issues are to blame for aircraft which raise or lower altitude on their own without any input whatsoever. In other words, the system simply rises or lowers while the throttle is at mid, without even trying to fly the aircraft in any particular direction. I think in our case, it is just not giving enough signal to the motors to maintain the altitude.

Currently the weather here is not very good for flying, and so I thought I would share my efforts thus far in case someone may have some insights or advice on what steps I might try in order to improve the handling of this aircraft.


(Leonard Hall) #2

Hi,

I think there is an issue with output saturation on the large copters. I will make an adjustment to autotune that will hopefully fix this issue. I am waiting to get some test data back before I proceed.

People willing to test this for me would be appreciated.

Thanks


(Mike Boland) #3

How large is large.
I am working with 8kg to 12kg copters and have experienced a strange crash in auto tune.
I am happy to test this if this weight range is of use.


(chuckntaylor) #4

Hi Leonard,
Thank you for the reply! I had made the original posting via forums.ardupilot.org. Not sure why the responses only show here on discuss.ardupilot.org.

First, it has come to my attention that the videos in my posting may not be visible to everyone. And so, I have changed the permissions on the five video links. The new links in order are:
https://vimeo.com/159745457/c18a666185
https://vimeo.com/159745461/db5ff9cfb3
https://vimeo.com/159745458/3b844c2dcd
https://vimeo.com/159745459/36163a429f
https://vimeo.com/159745667/8a398e367c

I may also be able test your new autotune solutions. Is it drones of this size (~35Kg) that this solution targets?

In the meantime, my strategy is to reset all the PID values to their default. I would then assign the channel 6 knob to tune one axis’ P value. I was thinking of setting the low point to be the default, and the high point to be what the autotune solution was last time. I know those settings ended up being too high due to the oscillations, so my thinking was I could fly the machine and determine an appropriate value somewhere in-between. Is this a reasonable strategy?

Again thank you for taking the time to look over this posting.


(Leonard Hall) #5

Hi chuckntaylor,

I have a bunch of parameter changes I would like you to try before we try my autotune changes. I can see some higher frequency oscillation in your quad at 11 and 17 Hz. I suspect we can reduce the bandwidth of your control without impacting your performance given your large weight. I have a bunch of parameter updates I would like you to try. I can’t upload a parameter file so I will put them below. Copy them into a .param file and upload them to your copter.

Please be very careful when you first take off after these parameter changes as they will affect your tune.

Your voltage reading on your battery looks funny. It seems to start lower and go up once it takes off.Is this working correctly?

Leonard

.param file:

#NOTE: 3/22/2016 6:00:15 PM Frame : chuckntaylor 20160329 Leonard
ACCEL_Z_FILT_HZ,5
ANGLE_MAX,3000
ATC_ACCEL_P_MAX,24000
ATC_ACCEL_R_MAX,24000
ATC_ACCEL_Y_MAX,9000
ATC_ANGLE_BOOST,1
ATC_RATE_FF_ENAB,1
ATC_SLEW_YAW,1000
AUTOTUNE_AGGR,0.05
AUTOTUNE_AXES,1
AUTOTUNE_MIN_D,0.004
INS_ACCEL_FILTER,5
INS_GYRO_FILTER,5
LOG_BITMASK,192509
MOT_THR_MIX_MAX,0.5
MOT_THR_MIX_MIN,0.1
MOT_THST_EXPO,0.7
MOT_THST_MAX,0.95
MOT_YAW_HEADROOM,200
RATE_PIT_FILT_HZ,5
RATE_RLL_FILT_HZ,5
RATE_YAW_FILT_HZ,2
RC_FEEL_RP,25


(Leonard Hall) #6

Hi Mike,

Large is now 30+kg. I too have a medium copter at 10kg. Things have changed a lot over the last year or so haven’t they :slight_smile:


(chuckntaylor) #7

Hi Leonardthall,
Thank you for sending these parameters to try out. Because this X8 operates at 50.4V, I have had to use a BEC to regulate the voltage first for powering the controller. Perhaps this is why the voltage reading looks funny. I use a voltage telemetry through my transmitter / receiver instead to get the actual feedback from the system.

Do you have a particular timeline for needing the results from this test? I am leaving my country in the morning for a few weeks, and return around April 20th. As such, it may take some time to try out these parameters.

Just to be clear, which DataFlash file were you looking at which showed the oscillations? Was it during an autotune session, or was it the file “2016-03-20 - 02 Oscillations Roll Axis”?


(Mike Boland) #8

Hi Leonard,
Scarily so :open_mouth:


(cookmangr) #9

Have you perform a auto tune to your copter chuck??

I have the exact same problem ad yours

After the auto tune complete i fly with the new pids and it perform great , but after i disarm and fly again i have a lot of vibrations


(chuckntaylor) #10

I tried out the setting mentioned above. The copter got about 4 feet off the ground before coming down hard and flipping over. Broke a bunch of very expensive propellers, but everything else appears to be okay. Need to inspect. Did not even get to the autotuning portion of the flight. All this happened in stabilize mode.


(cookmangr) #11

I lower the number at AUTOTUNE_AGGR from 1.0 to 0.5 and it help me a lot with auto tune


(chuckntaylor) #12

I wanted to pass along an update on the progress made with tuning the large drone. It is getting close, but I am struggling with altitude hold on the system. Whenever I apply pitch or roll in altitude hold mode, it drops altitude immediately. Here are some of the things we have tried:

  • Autotune. This resulted in heavy vibrations as described before.
  • Manual tuning. This worked out much better. The pitch and roll are responding well and feel very responsive.
  • Setting the altitude gain value to the channel 6 knob and attempting to adjust in flight. No results. If set high enough, it causes the altitude drop to still happen, just faster.
  • Tried settings advised above - resulted in crash.
  • Tried to adjust the throttle gains as per the documentation - resulted in crash.
  • Checked vibrations in logs. They are completely fine.
  • Believed barometer was faulty, and switched out for another flight controller and went to the latest stable firmware. No change.
  • Believed that perhaps it was a balance issue (too bottom heavy), and took off weights until it was completely balanced. No change.
  • This problem does not exist in stabilize mode. The aircraft flies well, has loads of power for fast vertical climbs, etc. In altitude hold mode, it climbs slowly. Went into software and adjusted the rate that it will climb in altitude to its maximum in case the system was not getting enough power to adjust altitude while moving. No change.

Summary:
As mentioned, the system shows real performance in stabilize mode. I have actually never hit full throttle, because it climbs REALLY fast - even with the 20lb test weight attached for an all-up-weight of 35Kg. In GPS mode, it holds altitude for the most part, but it also flies VERY slowly. I know this can be changed in the software though. My current theory as of yesterday is this: I believe it is a barometric issue, but not a hardware fault. The flight controller is positioned near the center with the top propellers a little higher than it. I think perhaps this system pushes so much air that it creates it’s own low-pressure bubble even when it is not close to the ground. I think that perhaps as I pitch or roll, the flight controller moves into the low-pressure bubble. This makes the flight controller believe that it has gained altitude and so lowers in elevation. When it settles, the barometer gets the actual barometric pressure and then rises back to the position it should be at. For example, when in altitude hold mode, if I input throttle during the pitch or roll movement to adjust for the drop in elevation, after the aircraft settles, it will rise up to the even higher elevation than when I started instead of maintaining a constant.

I think I do not see the altitude drops in stabilize mode because it does not use the barometer in this mode. And I believe I do not see such drastic drops in GPS mode because it is moving so slowly and so the flight controller rarely moves into the low pressure bubble to its side (or at least does not enter this low pressure bubble fast enough).

I would love to hear your thoughts and suggestions. If my theory is true, any advice for equalizing the air pressure? Foam or something similar?


(Rohan Raut) #13

I’m facing a very similar issue. With low speed ossilations in loiter mode which keep increasing if I leave it in loiter. Both in pitch and roll axis. Works like a charm in Stabilize mode. I have a flat Octa setup with wing span of 2.1meters. Would like some help on tuning it.