After a long time of trimming new planes manually and then using the TRIM_AUTO param, I decided to give the SERVO_AUTO_TRIM a try. The outcome is a bit puzzling, since after the flight, both ailerons were pointing upwards in neutral trim (see picture).
Here is the procedure I used:
- Launch the aircraft in MANUAL
- Change to AUTO on a ~500x300 m square at 200 m
- Change SERVO_AUTO_TRIM to 1
- Let the aircraft fly 5-6 rounds of the mission
- Switch to MANUAL
- Land manually
It’s maybe important to note that we set up crow flaps as here (swapping the two output channels and setting the channel reversal as needed). Log is attached.
Does anyone know what went wrong here? I suspect there is a problem with my parameters, but I can’t figure it out.
Link to files: https://cloud.geekbox.info/index.php/s/wwPFDHSBP5WdXkQ
if you have left flapperon on the right and right flapperon on the left I think its expected that the trim would be backwards.
I would recommend using the crow params for setting up crow flaps
We should probably update the wiki to point there from the link you posted.
Personally, I’d set the functions for servo 5 and 6 to aileron (4), do an auto-trim, then use that trim value and revert back to flaperon. I’m assuming the flaperon setting is causing the trim to be off.
Thank you @iampete and @Naterater ,
so I think the cleanest solution is to set up the crow params (they weren’t available when we set up our planes… 4 years ago, I think), but this will take some test flights, so for the moment we’ll either do it the old way using TRIM_AUTO, or use the workaround @Naterater suggests… but for that I’ll have to ask our pilot how comfortable he is with landing without crow flaps
Technically you could change the servo function in flight after the trimming. I recommend testing on the ground first though!
This won’t work, we have left and right flaperon functions but only a single aileron, so one side will always need to be reversed, that might be a bit too exciting for a in flight change.
So, update on this:
We set up our aircraft according to https://ardupilot.org/plane/docs/differential-spoilers.html
However, we still observe the weird behaviour of both ailerons pointing upwards after the flight. Also, the SERVO_AUTO_TRIM did not change our elevator or rudder settings. So I guess this feature in combination with differential spoilers is only good for flying wings? The wiki doesn’t explicitly mention this, but the article is using a flying wing as an example.
I think we will keep using the TRIM_AUTO param and maybe use the workaround provided by @Naterater at some point.
Auto trim should work in all dspoiler configurations. Rudder is not auto trimmed. Elevator should be trimmed, of course it could have been correct already.
This means we configured our plane incorrectly?
I’ve attached our current .param file, if anybody could take a look, I would be very grateful! eberhard.param (18.2 KB)
Its not very much help on its own for this stuff, need to also know what each output is connected to.
Yes, that makes sense of course. See attached sketch for a top-down view of our plane. The numbers refer to the SERVO outputs. So after the SERVO_AUTO_TRIM, DifferentialSpoilerLeft1 and DifferentialSpoilerRight1 would both point upwards.
This diagram looks correct to me. Can you share a log of the flight.
Here you can download the log (I uploaded both .bin and the converted .log). The picture is still valid, it shows the trim setting after the flight. https://cloud.geekbox.info/index.php/s/AfcJpBz4NPmC5NL
I’m not sure what is going on. The code looks correct to me, I did test it extensively when I added autotrim for Dspoilers.
I guess that you definitely have the servos connected as above? And both are correcting in the right direction in FBWA? That there both ending with up trim is strange, you should be only be getting the aileron trim but that would act in different directions.
I will fire up SITL and re-test if I get a chance.
Thank you Peter.
In FBWA and AUTO the plane flies perfectly fine (and the servos are also correcting correctly when testing on the ground)
First thing I will do tomorrow is double-check if the servos are wired as pictured.
We have multiple planes and it’s always possible that something went wrong when assembling this specific plane.
An additional behaviour that complicates this test a bit: When the function for Servo 5 is set to 0, all control surfaces on the wing stop working (even if there are still functions set as above for 6,7,8)
Yeah, this is expected the code checks for DifferentialSpoilerLeft1 to be assigned before it does the Dspoiler mixing, so you have to have it somewhere.
I just tested the control surfaces, they are wired exactly as shown in the sketch.
I have re-tesed in SITL using this model and params,
I messed up the trims and let it fly around for ages and they all came back to center (ish). Certainly no behavior as you have seen.
So either your setup is wrong or mine is.
today I tested it again with a different plane (of the same type, but Cube Black instead of Cube Orange and Arduplane 4.0.1 instead of 4.0.6)
We saw the same behaviour (both ailerons pointing up after the flight) with this plane too.
I will also upload the logs and pictures for this test within the next hours (same owncloud link as above, I created separate folders for the two tests)
Maybe this helps you in solving this problem if it begins to occur with other users, too.
My conclusion is that something in the general setup of our planes doesn’t seem to play well with the SERVO_AUTO_TRIM function, but I have no idea about the reason.
Edit: I annotated the pictures in test_2 for clarity, since for this plane, SERVO5 is the right Aileron (So SERVO_5_FUNCTION = 17) and SERVO6 is the left aileron (SERVO6_FUNCTION = 16)
I’m just trying to figure this Flap/Crow stuff out and searching lead me to this thread. I’m wondering if a Dspoiler_opts setting of 0 may be an issue?