# Arducopter HNotch configuration

@xfacta i have been running AC4.1.5 and performed Hnotch procedure.

from above FFT plot where i should consider 1st peak frequency 60hz or i should consider 125hz the highest peak .
log also shared here.
parameter file:
NoTCH configuration.param (17.4 KB)

60Hz, and 11 harmonics

I had a clarification for selecting the peak, do we select the peak with the highest amplitude or the lowest frequency (even if it had a lower amplitude)?

For example in the above case, if the 60 Hz peak was lower than the 125 Hz - how would we decide on the notch frequency?

Thanks!

How come we know that it’s 11 harmonic?

First plus second plus fouth harmonic = 1 + 2 + 8 = 11

Thank you for your suggestion but still i confused that how would you say it’s 1+ 2 + 8 = 11…can you explain more clearly with above FFT graph that how you arrived that.

first frequency is the main one and is also called first harmonic (2⁰ = 1)
double that and you get the second harmonic (2¹ = 2)
the third is harmonic (3*the main frequency) is not that high, so ignore that
the fourth is high so enable it (2³ = 8)

Add the numbers and set INS_HNTCH_HMNCS parameter to 11

1 Like

Do you referring gyro x peak value?..it’s not referring gyro z peak…?

Can you point out in the graph itself which one is 1st peak and 2nd peak and thrid and fourth peak…

From your answer i am assuming that gyro x is 3rd peak is the small one…is that my assumption correct?

Irrespective of X, Y, or Z the first second and fourth gyro harmonics have the highest peaks.

Is that is correct.

But among the all peaks the 3rd peak is only less about 0.02 amplitude only …in future FFT graph how i can confirm which harmonic peak can be negligible.

Fly the copter and log the post notch filter FFT. If all is ok there will be no noise there.

That is the only way to make sure you got it right.

1 Like

Ok thank you i will let you know the post Filter results with.

@xfacta
after configure INS_HNOTCH FILTER i got below post graph:

after that i start the autotuned process for the roll and pitch .
but while tuning i got message that autotune level failed manually tune any how autotune successfully completed after 15min of time landed safely and disarm to save the new PID tune value.
i got below autotuned parameters:

then again took off in stabilize mode it was well while hovering but when i try to do the fast forward movement i got little oscillation on stopping .then i reduced pitch rate value equal to roll rate value,
after that its looks ok then changed to loiter mode to check the position hold and its looks ok when no wind but when there is wind quad start oscillation and can not hold the position and also while descending the quad at 1.5m/s its start wobbling .how to improve those areas…

I also looked log still rate controller very noisy after setting Hnotch filter .

I am attaching all log for reference.

Cant tell much from that log since it doesnt have the batch logging enabled for the Harmonic Notch Filter, nor does it have any HNOTCH settings enabled.

Set these:
INS_HNTCH_ENABLE,1 ← set this then refresh params to see the rest
INS_HNTCH_MODE,1
INS_HNTCH_REF,0.16
INS_HNTCH_FREQ,80
INS_HNTCH_BW,40
INS_HNTCH_ATT,40
INS_LOG_BAT_OPT,0
and do a hover test for a while, no violent movements

In the Google drive link i have attached all log file which contains before notch and after notch with parameters file also …
Could you able to acces the file ?

@xfacta kindly refer to this also this is batch IMU logging log which i also plotted the log and showed here FFT.

Sorry, I downloaded the correct file, then opened the wrong one to examine

Make INS_HNTCH_REF = 0.245 instead of 0.3

Yaw is not tracking well and it seems to be affecting pitch and roll badly
I think these are too low
ATC_ANG_PIT_P,4
ATC_ANG_RLL_P,4
they might be better at about 6
and these
ATC_RAT_PIT_D,0.0036
ATC_RAT_RLL_D,0.0036
you could try at 0.006 but hover for a very short time and check for hot motors or a strange mechanical sounding noise. If you have that reduce those to about 0.0048 and see how it is.

Also try increasing these from 0.3/0.03
ATC_RAT_YAW_I,0.07
ATC_RAT_YAW_P,0.7

The compass is slightly affected by throttle (current) so you could try moving it a bit further away, or doing the Compass/Motor calibration - be aware of the danger and carefully follow the procedure.

If you want pre filter log and parameter file please access the 1st post of this topic.

When look at the pitch and roll desired rate and actual rate very very noisy and not even following.i have seen motor out put also very noise and its not looking linear too.

But when in loiter mode quad flying very well solid hover but it’s not consistent,if light wind also shaking badly.

My curre ATC_ANG_ RLL and PIT value is 11 and 9 respectively.
I have set ATC_ RLL_ D and PIT _ D is set to 0.005 after autotuned value creating oscillation.
Can you see my post that i have posted auto tuned pid valued and i have changed value from autotuned value to fly better…
I have tried loiter for about 30min and small auto mode also for checking it’s performance ,by look wise it’s flying 80% ok…but when i look bin outputs it very noisy…

I have configured INS_HNotch filters too very precisioly.

hi @xfacta as per your suggestion i have configured Hnotch_Ref value to 0.245 and ATC_RAT_YAW_I = 0.07 and P = 0.7 had a test flight today. But still have more very noisy rate control output. But still my vibration level are with in the limit only it reaches only 20 .

i have attached some of Rate and attitude graph of roll and pitch here

you can notice that still i got lot of noise in the output of attitude and rate controller.
i have attached log here also:M690A 26-04-2022 - Google Drive