PID settings advice

Hey. I will show the video, cube + herelink (stabilize mode). Still needs to adjust PID settings, before I can put autotune. You can see from the video: when move the stick right / left or forward / backward, guoad will shake. Throttle is about 45%, then guad hold altitude. Had difficulty keeping it stable. Purpose would be, that 50% throttle and then guad hold altitude. Would you give some advice, what setting I could change, that would be a little bit better. I have read these settings, but also I want to ask you. Thanks

There’s the tuning guide to work through:
https://ardupilot.org/copter/docs/tuning-process-instructions.html

And there’s a “helper” spreadsheet or press Alt A in MissionPlanner to set all the initial parameters discussed in the tuning process:

The Harmonic Notch filter setup, Dynamic is the one you want:
https://ardupilot.org/copter/docs/common-imu-notch-filtering.html

Work through those, and then provide a .bin log file if you’re still having trouble.

Thank you.

@xfacta

i have flown 20kg octocopter and now I’m planning to do autotune on that before I need your guidelines that just review my log and say if everything is perfect to do autotune.

https://drive.google.com/file/d/1iWpmvZ_4ho26hEv1eQQERwUa4hyHz0OE/view?usp=sharing

PIDs seem OK at this stage. I’d investigate the Harmonic Notch filtering before Autotune.
https://ardupilot.org/copter/docs/common-imu-notch-filtering.html

There’s some weight imbalance to the front, the front motors are working harder. Try to get it better balanced.

Current monitoring is not working properly, see if you can fix that.
Compasses are getting a bit skewed by motor current (throttle) - after you’ve fixed current monitoring you could do the Compass/Motor calibration - BE SAFE!
https://ardupilot.org/copter/docs/common-compass-setup-advanced.html#compassmot-compensation-for-interference-from-the-power-wires-escs-and-motors

Barometers seem to have a lot of prop wash or something, although you’re not getting high off the ground either. Probably try to get a couple more meters altitude next time then check the baro and altitude readings in the log. See if the readings are not so noisy.

Is MOT_THST_EXPO set correctly? What size props have you got?
Are the ESCs T-Motor Flame? If so then set MOT_THST_EXPO,0.2

I would set these:
ATC_INPUT_TC,0.2
PSC_ACCZ_I,0.5348
PSC_ACCZ_P,0.2674
BRD_BOOT_DELAY,5000 (allow any CAN devices to boot)
BATT_ARM_VOLT,44.3
BATT_CRT_VOLT,42
BATT_LOW_VOLT,43.2
BATT_FS_CRT_ACT,1
BATT_FS_LOW_ACT,2

Any reason to set INS_ACCEL_FILTER,15 ? You don’t seem to have any vibration or control issues. It could probably be 20.

Test your throttle failsafe (RC loss) if you havent already, and you might want to set up a channel for Emergency Motor Stop on this big beast.
RCx_OPTION,31

Use this spreadsheet, or Alt A in MissionPlanner to check your parameters match your props, with the exception of the MOT_THST_EXPO and ESC question I already asked above.

thank you for your valuable advice.
im using T.motor U8ll 85kv motor with ALpHA 60A HV esc and prop G30*10

MOT_THST_EXPO i just leave it as default value and nothing calculated.

i will incraese INS_ACCEL_ filter to 20 and test it with some high altitude and check baro against prop wash or something.

Set MOT_THST_EXPO,0.2 for those ESCs - they try to linearize the thrust.
Be sure to check all the other settings and go over all my points I raised, and any others you can think of.

I was thinking more about this - I highly recommend you set these for increased safety:
FENCE_ACTION,3
FENCE_ALT_MAX,50 <-adjust after test flights
FENCE_ENABLE,1
FENCE_RADIUS,100 <-adjust after test flights
FENCE_TYPE,3
This will make you wait for a good 3D fix and you wont be able to arm in any flight mode until that 3D fix. You have a pretty good GPS signal so it shouldn’t take long, and you will have an extra couple of minutes to think or talk :slight_smile:

Once everything is sorted out, do another test flight in AltHold mode and fly around gently, not so frequent or violent stick inputs and lets see that log.

if MOT_THST_EXPO set to 0.2 means instability in higher throttle.

because i was seen lot of discussion in forum about this parameter that if we set low value stability in low throttle where as instability in high throttle?

is that real fact?

For Alpha ESCs which do thrust linearization, something like 0.2 is appropriate. I have flown with 0 too.

1 Like

So if I set 0.2 also does not any problem.

I have too Alpha ESCs (40A LV) ,so I have to change MOT_THST_EXPO 0,2 ? Did I understand correctly? Thanks.

You probably should, might have to run Autotune again, but test and see what logs and flight performance is like.

Leonard Hall explained setting and testing MOT_THST_EXPO

  • set too high you can see instability at low throttle
  • set too low you can see instability at high throttle

Hi. I haven’t done yet autotune flight and before that I have two questions: 1) Herelink (solex) still informs: battery too low, although there is power? 2) Can I run autotune, even if the guad goes up even the throttle stick is 50%? This happens with stabilize mode but altitude hould mode works fine. I had mot_hover_learn set 2 when I fly. Thank you.
https://drive.google.com/file/d/1vvKD4JaK9OyAMTORyexHh5ESQTG0cN5p/view?usp=sharing

@xfacta

i have changed copter balance and i cant connect current sensor because it may damage the current sensor if overcurrent flown through the sensor.

i have changed MOT_THST_EXPO to 0.2 .

https://drive.google.com/file/d/19Pd-fB2qHO-dId2MVzOwa3gPq4qHvrPZ/view?usp=sharing

before MOT_THST_HOVER was 0.22 as per previous flight but after this it is changed to 0.33.

https://drive.google.com/file/d/1j3tmRPpcFOtBdpa1_E_mAUKbIh_XClaR/view?usp=sharing

above log is MOT-THST_HOVER changed to 0.33.and INS_ACC_filter also changed to 20HZ.

after above flights i was set HORMONIC NOTCH filter and made test with LOG_BAT_OPT =2 for post hormonic filter analysis. i have attached that flight log also kindly look at all log and guide me
https://drive.google.com/file/d/1kvJYvZeQI-O2R_5KrjBaFYlo9ZrNA6Pm/view?usp=sharing

https://drive.google.com/file/d/1VmjTnMKC_HyFVvsqiS-Q1pDjvjr4MahJ/view?usp=sharing