3.4.3 on Pixhawk 2.1 Autotune issues

Not sure if this belongs in another category so sorry in advance if this is the wrong spot. I have been working on swapping a new pixhawk 2.1 on my DJI S1000+. I have been flying it for over a year and arducopter/pixhawk has been great! I have always used autotune and it has worked out very good. I always tune one axis at a time and then save the parameters and continue to the next axis till done.

Now that I have tested my new pixhawk 2.1 setup I have been trying to autotune the roll, pitch, and yaw. I am starting with the yaw first and after about 5 minutes it finishes. The results are not that great but it is an improvement from the basic PIDs, however whenever I tune roll or pitch (i uncheck lock roll/pitch as I autotune them separately) I seem to get some weird results from what I am use to seeing. I thought it might be because a lot has seem to change from the 3.4 rc1 i used for so long to 3.4.3 or going from the original pixhawk to the pixhawk 2.1. After roll or pitch is autotuned as soon as i get off the ground it vibrates slightly but quickly. I have tried this a few times and the results are the same and autotune comes up with similar results. I have to takeoff quickly or it appears that the octocopter may tip. Since I save the parameters after each axis tune I went back to just the saved parameters after Yaw (untuned pitch and roll) and the quick vibration is gone. There was also no finishing tone from the buzzer when the autotune was completed.

This are the results I got from the pixhawk on 3.4 rc1 on the S1000+ (my last saved .param file after autotune)
ATC_ACCEL_P_MAX,59530.05
ATC_ACCEL_R_MAX,48122.94
ATC_ACCEL_Y_MAX,11570.42
ATC_ANG_PIT_P,8.291903
ATC_ANG_RLL_P,5.207353
ATC_ANG_YAW_P,4.43052
ATC_ANGLE_BOOST,1
ATC_RAT_PIT_D,0.01235184
ATC_RAT_PIT_FILT,20
ATC_RAT_PIT_I,0.17482
ATC_RAT_PIT_IMAX,0.444
ATC_RAT_PIT_P,0.17482
ATC_RAT_RLL_D,0.01619052
ATC_RAT_RLL_FILT,20
ATC_RAT_RLL_I,0.17482
ATC_RAT_RLL_IMAX,0.444
ATC_RAT_RLL_P,0.17482
ATC_RAT_YAW_D,0
ATC_RAT_YAW_FILT,5
ATC_RAT_YAW_I,0.1751279
ATC_RAT_YAW_IMAX,0.222
ATC_RAT_YAW_P,1.751279
ATC_RATE_FF_ENAB,1
ATC_SLEW_YAW,1000
AUTOTUNE_AGGR,0.07
AUTOTUNE_AXES,7
AUTOTUNE_MIN_D,0.001

Here is what I got with the yaw autotune
ATC_ACCEL_Y_MAX,27000
ATC_ANG_YAW_P,5.983694
ATC_RAT_YAW_D,0
ATC_RAT_YAW_FILT,5
ATC_RAT_YAW_I,0.1872228
ATC_RAT_YAW_IMAX,0.222
ATC_RAT_YAW_P,1.872228
ATC_RATE_FF_ENAB,1
ATC_SLEW_YAW,6000

And here is the roll autotune (some of the parameters are very close but some are very different)
ATC_ACCEL_R_MAX,110000
ATC_ANG_RLL_P,12.43967
ATC_RAT_RLL_D,0.01860433
ATC_RAT_RLL_FILT,20
ATC_RAT_RLL_I,0.4764247
ATC_RAT_RLL_IMAX,0.444
ATC_RAT_RLL_P,0.4764247

I have never had to adjust loiter or alt hold tuning after autotuning all three axis but loiter is pretty bad after tunning either pitch or roll. Is there something that has changed or am missing? Can I use the previous PID from 3.4 rc1 on my original pixhawk on 3.4.3 with the pixhawk 2.1? If so, will autotuning with these values to start help fine tune it?

Here is the log after autotune on yaw
https://drive.google.com/open?id=0B5vwo36WQS__empZUENRMEJSSjA

Here is the log after autotune on roll
https://drive.google.com/open?id=0B5vwo36WQS__N1VxeVBGQUtmZGc

Here is the log where i was going to test after yaw and roll were autotuned but i noticed the bad vibrations before I even took off. I never left the ground and decided to reload the parameters from after doing the yaw tune to get rid off the roll parameters. You can see that the vibrations spike even thought it never flew once the motors were spinning.
https://drive.google.com/open?id=0B5vwo36WQS__MFljYkpXOV9QejA

This last log was with just the yaw tune parameters and stock roll and pitch with a short grid mission. It was low with tight spacing so I think that it made the turns between lines really weird.
https://drive.google.com/open?id=0B5vwo36WQS__VFVrcWp5SnF6eFk

I have the flight controller mounted exactly the same way as before and vibrations seem to be good, never really had an issue. Its attached to the frame the battery mounts too supported by 12 isolators (Just like any other S10000+) ad all wires are secure and I have made sure the battery does not touch or rub against it when inserted. There is also a plate underneath to try and prevent prop wash when landing and disturbances from wind gust. I have attached a picture although it may be hard to see.

I am also seeing err:CPU-0 and err:CPU-1 errors in my logs that I have never seen before. Any help on autotuning this would be greatly appreciated!

Nick.

Update, based off some information I found using the nifty search tool I set the roll and pitch filters to 10hz and the yaw to 2.5hz. ATC_ANG for pitch, roll and yaw I used from pixhawk 1 on 3.4 rc1 and the rest of the settings I just picked the midpoints of the acceptable values listed in the mission planners parameter screen. Roll and pitch seem good, yaw is ok but has a noticeable altitude change, it will rise up about 2 feet and come back down on small quick yaw inputs. Slow and large angles do not seem to cause this. I know it had done this before in a previous firmware, may have been 3.3.

For now until I get more information I will probably stay away from autotune and may just manually work on the yaw as time progresses.

Hello Nick,

I don’t know if you have this problem solved now.
Apparently to me, a point which may be problematic is the fact of having flight controller in a diferent frame than the S1000.
I’m meaning that I think the PH should be directly attached to main frame, and not the lower part of the frame which is battery mounting and gimbal support, which has dumper balls between both.
These dumpers make the battery structure have a little different attitude/response between the main frame and this support, and it could produce this “lag” in the corrections from PH respect main frame.

I hope you can understand what I’m meaning, and it helps you to solve that problem.

Thanks for the tip Matt, tried it with the flight controllers mounted up top but got the same result. I switched back to the original mounting location. I agree it doesn’t seem the best spot but it works very well, I think the weight of the battery helps. I have 200 flights on the frame now and feel pretty good about it. Now I just wish I could figure out why the pixhawk 2.1 is always reporting co.pass issues but flies fine…

1 Like

I have roughly the same size Octo’s and did auto tunes with 3.4.3.
First attempt was a crash 30 sec into roll tuning.
Did my research as you have done (which I should have first)
Reduced filters and reduced aggressiveness as you have (10, .075)

I get the same vibration you describe on powering up and have to lift off quickly.
It flies smoothly but is wildly responsive, makes me tempted to try a flip :wink:

I will be retuning with aggressiveness set to the min of 0.05 as I believe this is the level that will fix this.
Will let you know how it goes.

Mike and Nick. Wondering if you landed on any final tune settings? I have the exact same bird, s1000+ and recently thought it was a good idea to to upgrade to the PIxhawk 2.1 to try out the new HERE+ RTK. And, i am using firmware 3.5.5. But i has been nothing but a hassle. :frowning: Had to turn off all but the primary compass to stop getting compass error. And this tuning problem is rough. we almost flipped too. And i have a very expensive payload. So I dont’ want to take any chances. Any final words or settings Mike, I see where you were going to try changing the aggressiveness settings?