First up, pretty much all quad planes should start out using these settings:
The bad news is this is a classic ESC sync loss. You need to do your standard due diligence on your ESC setup. You should check to make sure that all your wiring and setup is done correctly in case it is a loose wire or something similar.
The things that reduce the chance of sync loss are keeping all power wires gently twisted from the battery to the ESC, avoid large loops.
Ideally you would reproduce the sync loss issue on the bench. Then you can make changes to minimise the chance of desync happening. To reduce the chance of sync loss you can increase the minimum throttle or increase the timing value.
Thank you @Leonardthall for quick help!
I have already started the re-build and will incorporate all the feedback to make it a success this time around.
Noted for all future QuadPlane setups.
I have tested all ESCs and Motors individually and they are working fine. So this indeed is an ESC Sync Loss.
1 pair of 10-gauge power wire runs from PDB (mounted in fuselage) to centre of each boom (0.8m wire), where it splits into two ESC inputs. A loose twist was applied every 8 inches on the power wire to avoid the same. The ESC signal wire is routed alongside the power wire, using an anti-interference twisted servo extension cord (90 cm)
Is there a need to shield the power or signal wire using aluminium based shielding tape?
Minimum throttle was set to 23%. But i noticed that the motor spins very slowly at this point (using Motor Test and setting Throttle to 23%). Perhaps this is because of the Throttle Expo. Can you please point out how the parameters Q_THROTTLE_EXPO and Q_M_THST_EXPO affect the output level?
As for timing, the arduplane documentation says RCOU.C5-RCOU.C8 are set at 400Hz update rate for a QuadPlane setup. Digging into the ESC manual, i found that it supports OneShot and i have set Q_M_PWM_TYPE to the default Normal. Is it recommended to switch to OneShot if the ESC supports it?
The main way to test this is to do step pwm inputs from near minimum to maximum. Basically you need to abuse the low end of the RPM range with fast steps to high RPM.
This seems quiet high. Make sure you have calibrated the ESC’s.
They don’t impact the minimum and maximum throttle settings. At minimum throttle you should have an assertive rotation but not so much that it is producing a significant amount of thrust.
I was talking about the ESC phase timing. This is not a setting in Ardupilot, it is an ESC setting. There are a few settings in BLHeli that might help. RC Test Bench is a good reference for BL Heli settings.
This is probably not going to be any great improvement in your system. So at this point I would not add another variable.
No, it sets the target overshoot for the tests. This overshoot needs to be between 5% and 10% for best performance. However, the tests can’t tell the difference between noise and the actual movement so we set it to the upper range by default. The noise in the system will mean it ends up lower.
Autotune works between 10 and 20 degrees on the angle steps and aborts if it goes over 20 degrees. So this would have no impact on autotune.
Sorry to revive the topic but we’re trying to do an autotune of our Qplane and are not getting desired results.
We set flight mode 6 to Qautotune and went for a test. We take off in Qhover and then toggle into Qautotune when we’re in the air. From what I’ve read on here we should see it twitch rapidly about its roll axis but we don’t get any reaction at all. Furthermore we can’t see the correct parameters in the parameter list. We’re running arduplane 4.0.5.
We managed to get it started by updating to fw 4.1.0! Unfortunately our rig flips when we exceed 15 degrees so when autotuning the roll axis we flip immediately. Will update here and here if we figure it out.
As per the Tuning Instructions Guide these Acceleration rate parameters must be set according to the propellor size (which is proportional to UAV size & weight).
However, @Leonardthall recommended these for Pretty much ALL Quadplanes which does make sense as high rate of acceleration in Roll & Pitch is neither desirable nor safe for a Quadplane. I would start-off with these parameters for a Quadplane and work from there.
Today something very similar happened to me. I believe I followed all advices from this thread regarding parameters. I took off, the VTOL was oscillating a bit. However, it kept position nicely, so I decided to switch to QAUTOTUNE. Since I set it to the lowest aggressiveness I thought it should be fine. It seems like it started autotune, but a few seconds into it the VTOL flipped to its left and crashed top-down.
In the logs I can see that RATE.Rdes all of a sudden goes to -170deg, which should be the reason for the crash. However I didn’t even touch the joysticks during the flight
Its a Cube Black, two GPS, one flow sensor and a rangefinder.
@snakeeater I am very sorry to hear about your crash but I think I was pretty clear in the instructions lined above that you should not start autotune until you have “ensured that the current tune is good enough to recover from the repeated tests run by Autotune”. Given:
Ok, thanks for the clear assessment. Thats what I was considering too. I thought my D gains were already quite low, but obviously i will lower them further and be more cautious regarding vibrations before starting the Autotune.
So you recon the PIDs were the main problem? That spike in the graph above is not some sensor failure/reset because of wrong parameters or anything, but it was actually the first normal cycle of autotune? I would like to understand it from the data.
I think this gave me a completely wrong feeling about those parameters. My initial try was 0.3 based on that and the plane flipped right at the start, thats why I was rather positive how it went this time. Of cause I am just one point of experience, but my VTOL should be a rather average setup. Maybe it should be considered weather the documentation should be updated?
If you have any oscillation then you can’t proceed with Autotune.
The good news is I don’t see any oscillation in yaw. Can you show where you think you see it?
You do have some high frequency noise at about 80 Hz that you would benefit from removing with a notch or harmonic notch depending on where it comes from. A batch fft log would be the way to go here see what it shows.
Your filter settings look ok otherwise though.
In any case I would add the notch filtering after the FFT log flight before proceeding to Autotune. I suspect you would get away with it though. I just would do the setup properly first.
Your log looks like it is oscillating in both Alt Hold and pitch. So I would read through the instructions above and make the appropriate changes I describe there. If you follow the instructions step by step you should do well.
Ok, I set up a harmonic notch filter linked to the throttle.
Did a few test flights. Everything looked good, so I proceeded with an autotune. First thing I noticed was a sharp yaw to the left, which surprised me because autotune is supposed to start with roll and I had Q_AUTOTUNE_AXES set to 1.
I gave it a few more minutes and didn’t like what I was seeing so I abandoned the autotune.
A few concerns:
The autotune seems too aggressive for a 2m QPLANE. Q_AUTOTUNE_AGGR is set to 0.1. Should I lower this to .05. AUTOTUNE_LEVEL is set to 6, which is default and consistent with the recommendation. Should I reduce the level?
The other concern is current draw during the autotune. It spikes to 160 amps. The four ESCs are rated at 60 amps and the Mauch Power module is rated at 200 amps. But the battery, connector, esc and engines are getting warmer than desired. I am concerned it may get too hot during an autotune. I plan to do one axis at a time, land, let it cool and do the next axis. And I am thinking reducing the aggressive may reduce the current spikes?
Long term I am not too concerned about the heat because we only plan to be vtol for a few minutes for takeoff and landing.
Any suggestions about how to proceed are greatly appreciated.
Link to the log for the attempt at tuning. It consists of two test flights and the autotune flight.
We went autotuning recently and only managed to finish around the pitch axis. I’ve read previously that the PID’s are saved even if the autotuning did not finish completely. This seems to be wrong or maybe we are missing something.
I attempted another QAUTOTUNE today. It started out ok, but progressively deteriorated to a point where I was no longer comfortable continuing. My concern is large movements in the yaw and pitch axes while I am tuning the roll axis. I understand some motion on the other axes is normal, but both yaw and pitch seemed excessive and borderline unstable. At one point, the nose pitched down 35 degrees. Yaw is literally all over the place with several 180+ swings.
The winds were calm.
Vibrations look good
CG is at the recommended location.
The engines are close to the same PWM while hovering.
Not sure what else to check. But don’t have confidence in moving forward with the tune.
Attached, please find an image Des Pitch, Des Roll, Des Yaw. and a link to the log file.
You are starting autotune from Q_Loiter. This does a bunch of stuff for you like keeping you pointed in the right direction and fighting drift.
If you start it from Q_Hover then you will have to do all that yourself. I do it all the time like this so I didn’t think of it.
Basically do it on a calm day in a big field and let it drift with the air. Try to keep the axis being tuned 90 degrees to the air flow. ( I am deliberately not saying breeze or wind because you want really calm).