Autotune - 90 degree roll

Hello guys,

today I tried the autotune mode for first time and the result was almost fatal crash. Started in stabilize then switched to loiter and then to autotune. When the aggressive roll happened (1:41) and the copter leveled near ground then I switched to stabilize and disarmed (little crash).

Video: https://youtu.be/5ZHqJQ5Njqw
Log: http://pgcentrum.sk/log-2018-04-02.bin

I don’t think this behavior is normal? The log analyzer returns all ‘GOOD’ values except for the compass mag field.

Test: Autotune = UNKNOWN - [?] Autotune 46974-79055
Test: Compass = FAIL - Large change in mag_field (215.77%)
Max mag field length (609.89) > recommended (550.00)

I had a lot of problems to get the compass working. First I had external compass that came together with GPS module. It did not work. Then I used the pixhawk internal compass and the result was a lot of direction (yaw) changing - toilet bowl. At last I bought HMC5883L compass and all problems stopped. Compass is placed good distance from the battery and ESC and power lines. Calibrated compass before flight 2 times (very strict) and the offsets were almost identical. Internal compass is disabled.

Should I make the distance higher? Is the mag field too high because of interference?

Still trying to learn to read the log files. Are there any high vibrations that could cause this?

It’s probably not a ESC problem - I don’t know. I use these: https://hobbyking.com/en_us/blheli-s-30a-2-6s.html Battery is 6S, motors tarot 4008 martin.

Thank you for any help!

After reading some other posts I think it can be ESC sync problem. ESC brake is active (I will try to turn it off with programming card). Is it possible that the APM handled the roll with only 5 motors like in the video?

The extreme roll was not commanded by the flight controller. In fact, it commanded the opposite roll:

The flight controller requests maximum effort from motor 1, and the opposing motor is throttled down. This suggests a hardware-related problem on motor 1.

Check for loose motor or ESC connections. Also make sure the motors and ESCs are not overheating. Sync errors are a possibility, but I suggest checking hardware first. Turning off active braking will affect performance, and I’m not sure if it will help with sync problems.

You should invoke Autotune from Position hold
That is how it works best for me

Thank you for the reply. Checked the wires and everything is OK.

Also checked the ESC settings. Spent hours trying to programme it (programming card, RC) - at last it worked with arduino + blheli suite. The brake setting is turned off but it brakes anyway (googled that it can not be turned off for dshot/multishot). Only thing that I changed is ‘commutation timing’ from medium to mediumhigh.

Also I was flying a lot today in loiter/poshold with extrem roll/pitch control, no issues at all. Nothing is overheating. Maybe I will give the autotune another try but I’m really scared that it is sync problem and may happen again.