Instability After Repairs

That’s basically what I had, with the exception of the dynamic update (INS_HNTCH_REF).

I’ll give it a shot tomorrow and see how it flies with that turned on. Then hopefully I can go through auto tune and whatnot.

Ran a longer test flight this afternoon after enabling the harmonic notch for esc rpm’s. Everything seemed fine. Most of this flight is just a flat loiter hover. It seems pretty stable in stabilized or althold mode as well, moving around seems to level out well without bouncing around.

You need to set these for the Harmonic Notch Filter to work properly:

INS_ACCEL_FILTER,10
INS_HNTCH_BW,30
INS_HNTCH_FM_RAT,1
INS_HNTCH_FREQ,60

The frequency and bandwidth values you set can only go UP with the dynamic notch filter, so you need to set the lowest possible Freq and BW that will ever be possible and the dynamic filter will scale them up with RPM. That’s why I’ve chosen values about half of what you had (I did check the FFT graphs too).
With the values you had, centred on the approximate hover Freq, the filter would never work below that.

The attitude control is poor, but at least there’s no oscillations. This is mainly because PIDs are very low. These should be a safe starting point for an EDU450 (I’ve had some experience with them)

ATC_ANG_PIT_P,6
ATC_ANG_RLL_P,6
ATC_RAT_PIT_D,0.005
ATC_RAT_PIT_I,0.10
ATC_RAT_PIT_P,0.10
ATC_RAT_RLL_D,0.005
ATC_RAT_RLL_I,0.10
ATC_RAT_RLL_P,0.10
ATC_RAT_YAW_I,0.05
ATC_RAT_YAW_P,0.50
ATC_THR_MIX_MAN,0.5

It seems like you still had some values from your 3S experiments, so be sure to set these exactly:

BATT_ARM_VOLT,14.70
BATT_CRT_VOLT,14.00
BATT_LOW_VOLT,14.40
MOT_BAT_VOLT_MAX,16.80
MOT_BAT_VOLT_MIN,13.20

Set all of these params at once, before you fly next. I’ve only broken them out into groups for the purposes of explanation.

Alright, thanks for looking out on the battery stuff. That low volt setting at 11.2 was definitely a miss. But I have read so much different stuff about how low you can drive these, some of that was me deliberately setting things. Anyway, I took your suggestions in full.

Here’s a flight with all these changes made. It feels less boat-like. While I’m thankful for your (and others’) help, I feel like the slow kid in class.

Don’t worry - Arducopter is complex and it can be tricky to get working properly. This is an effect of working on so many different flight controllers and vehicles - there is no quick easy way to get a vehicle working well without lots of experience.
That hard work makes it rewarding :slight_smile:

Attitude control looks quite a lot better in that log!
I would run a Autotune on Pitch and Roll axis first, AUTOTUNE_AXES,3 and see how that comes up.
Later you can do Yaw autotune if needed, AUTOTUNE_AXES,4

Excellent. Thank you so much. Will report back.

By the way… Start Autotune and once it completes (stops twitching) DO NOT switch out of Autotune mode, just reposition and land, wait for disarm plus a few seconds, then switch into any mode you like.

Got the message that it saved pids for roll and pitch. Once another battery comes off the charger I’ll try it out again.

It seemed like I had a really fast vibration/oscillation after the pitch tuning was done. I couldn’t test for but a few seconds before I hit the battery FS and had to land.

Yeah, I definitely picked up a vibration. Like a washing machine on spin cycle with a slightly uneven load. It isn’t not flyable, but it is definitely not right.

Here’s a video of it, FWIW.

Sorry for the crappy video quality. Was not wanting to let go too much control in case something went wrong.

Here’s the log…

Also, I didn’t say this but I did Roll first. Landed, then did pitch. I did them that way because I didn’t want to risk running out of battery in the middle of it. I did not see the vibrations/oscillations until after pitch finished.

So I am wondering if I need to adjust the pitch D term up.

I’m mobile at the moment, will check that log in a hour or so

You’re the best. Thanks.

OK, the vibrations, actually tiny oscillations, are present in Loiter mode in Y axis.
It’s showing as a massive oscillation in motor outputs.

In the video the GPS stand is wobbling a lot. You should add an extra brace or something to make it very stiff. This may even be the cause of the issues.

I would set all these to steady everything (and fix Yaw while we are at it), then once you are happy that flight is stabilised again (after fixing the GPS stand), go back to Autotunes.

ATC_ACCEL_P_MAX,140000
ATC_ACCEL_R_MAX,160000
ATC_ANG_PIT_P,18
ATC_ANG_RLL_P,19.7
ATC_ANG_YAW_P,6
ATC_RAT_PIT_D,0.005
ATC_RAT_PIT_I,0.174
ATC_RAT_PIT_P,0.174
ATC_RAT_RLL_D,0.005
ATC_RAT_RLL_I,0.152
ATC_RAT_RLL_P,0.152
GPS_GNSS_MODE,67
PSC_POSXY_P,0.5
PSC_VELXY_D,0.25
PSC_VELXY_I,0.5
PSC_VELXY_P,1.0

Later if everything goes well we can put the PSC_ params back to defaults - I’ve specified half of their default values to reduce how tightly Loiter tries to follow the GPS position (which is wobbling all over the place with that GPS stand).

Okay. Cool. I believe you’re seeing a trick related to frame rates. The gps stand isn’t wobbling around, it is vibrating very quickly back and forth. It does look like it is wobbling but I promise you it isn’t. The entire craft is vibrating back and forth.

Yes true - a trick of the camera :slight_smile:
Those params should still apply regardless - see how that goes.

Oh, I’ll be checking to make sure things are not floppy around that stand. I am just posing that what I saw with my eyes definitely wasn’t what appeared in the video. But I have also been wrong about so much I’m not making assumptions without checking, so we’ll get it handled.

I’ve got it all set config-wise for tomorrow morning when the sun comes back out. Thanks.

The outputs are oscillating because the Rate>Pitch output is out of control. This should not be oscillating and the acceptable peak max is 0.1

@dkemxr Dave is right of course, you could drop some of my PID estimates even lower

ATC_ANG_PIT_P,10
ATC_ANG_RLL_P,12
ATC_RAT_PIT_D,0.004
ATC_RAT_PIT_I,0.12
ATC_RAT_PIT_P,0.12
ATC_RAT_RLL_D,0.0036
ATC_RAT_RLL_I,0.11
ATC_RAT_RLL_P,0.11

and keep the other things I specified before.

There’s still got to be some external factor (like that GPS stand) that is affecting the outcome of Autotune.
In the end a manual tune like we’ve been doing might give a good enough result.

I will check the GPS stand. I think I may need to tidy up some wiring as well. Long story but I think there are some loose wires able to smack the side and bottom of the FC.

That makes sense. The pre Auto Tune log posted above, now deleted, didn’t look bad for a pre-tune condition.
Kind of odd for a garden variety EDU-450, there are a lot of those flying pretty well.
Difference here is its on 4s and many are 3S?