Trex500 GF with GY401 and stock ESC in governor mode - unknown behaviour

I have setup like in the title. I managed to get the thing hover, but sometimes it hover ok and sometimes some drift occurs.
Drift happens for instance when i use throtlle more, but sometimes happens just like that. By saying drift a mean situation when (in stabilize mode all the time) I have to put roll stick full to the right to compensate drift to the left, sometimes it is drift in pitch direction. Behaviour can be compared to suddenly in flight adding trimmer to the max on one direction.

I have some vibrations, every heli has some. In my heli i have found that engine is main cause for vibrations, however i have set filters to filter out vibrations. Tail is swinging a little bit also.

I don’t know what to do as in arducopter so many thing behaves other way than documented, that I have feeling that actually everything is wrong. I am thinking of coming back to simple setup with receiver only. I have spent so many days on figuring things out that it would be waste to revert changes now. Maybe someone has idea howto fix all this issues.
Also heli is very slow to respond any controls, which is probably lack of autotuning?

What can I do to make stabilize mode work?
Which mode in adrucopter is fully manual mode?
2021-08-13-trex500-settings.param (18.9 KB) driftofflog.bin (1020 KB)

Update. In Acro mode heli is responsive, however it is still drifting like it was not trimed. It is weird that in acro heli is drifting backward and tilting more and more. In Stabilize it is drifting to the left at constant tilt. Any clues ?

So in acro the control is similar to just using your receiver only because you have H_FLYBAR enabled. In stabilize, it uses the full arducopter controller which requires you to tune. Please read through the tradheli tuning guide here. I am working on an autotune feature for heli’s but it is not ready yet.
As for the drifting in stabilize, be sure that you have calibrated the AHRS attitudes correctly that the shaft is perpendicular the the ground (level fore-aft and laterally) with pitch and roll angles of zero. And you need to set the trim roll angle for hover with the ATC_HOVR_ROL_TRM parameter. Hope this helps.

Just took a minute to look at your log. It shows that you were hovering with near 30 deg of roll attitude and 10-20 deg of pitch attitude. Do you remember the aircraft being at those attitudes while flying? Was it windy?

Also it doesn’t look like you set up your swashplate. H_COL_MAX and H_COL_MIN are default values. Did you program swashplate collective limits mechanically? what is the collective setup (i.e. max collective blade pitch and min collective blade pitch)?

I was using option in MP to put swash in max, min and mid position. I was trying to set around +10 to +12 degree at max, -10 to - 12 at min and at mid pitch is at 0 to +2 maybe. I don’t have digital pitch measurement only simple one.

It wasnt very windy, heli was hovering straight. 30 deg of roll and 10-20 pitch is impossible. Of course I had to come back to position sometimes, but at hover heli was leveled. I am thinking that arducopter sometimes get wrong attitude of the heli and sometimes it is ok.
I will wait for windless weather and try to tune it according to the manual you have provided. I didn’t do this procedure yet. However it might be that FC is to close to esc or gets too much vibrations? Matek F405-std is mounted inside the frame bellow shelf where receiver is placed. On the side of the heli there is an ESC, so there is around 4 cm distance between ESC and FC and fiber glass wall between them.

I am using external gyro. Which parameters from the tuning table do I need to tune for yaw in that case? I would like arducopter to stop messing with yaw, as gyro is doing a good job, however I think that arducopter is trying to correct gyro, as it doesn’t hold neutral position. Gyro is Futaba G401 with headlock and it doesn’t need any “help” to keep tail in one direction :slight_smile:

I am guessing that part of the parameters for yaw tuning are not in use when using external gyro. Is it right?

It shouldn’t get the attitude wrong. If it does then there is a problem with the controller or it’s not getting all the information it needs to estimate the attitude properly. Do you have a GPS connected to the controller? The Matek 405 STD does not have a compass. So if you don’t have a GPS with a compass built in then I think the controller will have a hard time keeping the attitude solution from drifting. It needs other information to keep the IMU from drifting.

Please read this post I made on another users thread who asked the same question.

I have M8N gps with compas buildin. It is on a side wall of heli, the other than ESC.

@K4cus So when you say the GPS is mounted to the side of the frame, you are saying the flat part of the disc is mounted to the side wall? If so, that is not the proper way to mount the GPS. The flat part of the disc must be on a horizontal surface with clear view of the sky. As for the compass, it is odd that I don’t see a device ID for your compass in the param file.

Do you use a Ground control station with your system, like Mission Planner or QGround Control ? If so, Does the ground control station show that the GPS has a good signal. I should say something like GPS Fixed. I would be surprised if it let you arm without having a good signal. I will have to check your log again now that I know what I am looking for. It will be a few hours before I can do that.
But my initial assessment is that since your GPS is mounted incorrectly, you are getting a bad Attitude solution which has a huge impact on how the aircraft flies.

I don’t think that gps has impact on attitude, magnetometer has. I will check about gps signal. Does stabilize mode use gps for anything? I am using betaflight which stabilize hover super fine without gps and magnetometer.

Ardupilot uses an extended kalman filter in determining the attitudes, velocities and position of the vehicle. It uses all available sensors to include GPS and magnetometer in order to reduce error in these estimated states. You can read more about it here.
Please answer my other questions in the previous post. Thanks!

Yes gps is mounted on the side, vertically with flat part of the disc.
I am using Mission Planner, I will check what gps says later, now I am at work :slight_smile:
I remember that I was calibrating compass some time ago, it supposed to be available.
I don’t see other questions in your post :slight_smile:

Hi Bill Geyer,
sorry for not answering right away, but I am fixing problems with vibrations. I have ordered new engine and it will take 30 days for delivery from China. I won’t waste our time for adjusting heli that has basic problems to be solved first.
I can confirm that gps mounted upside-down takes much longer to get lock on satellites (I tested it on my quadrocopter), so maybe position fix is also more loose when it is mounted on a side.

I will get back on this thread as soon as I fix vibrations and mount gps correctly. It will take about month I think.

You were right that gps on a side has trouble to get proper 3D fix. I will move it. I have my engine fixed also. My heli arms without gps fix. Arming check set to 1. I am arming using switch.

Is it possible to use external governor setpoint for engine, but to make it possible to use 3 or 2 different values of the set point changed by the rc channel (by switch on my radio), as I change normal idle1, idle2, and autorotation.
For now I am using rc_passthru and I will set horizontal line for engine curve (at 75%, and 85% and 0% for autorotation), but I was reading that in autonomous modes rc_passthru shouldn’t be used. So what is the correct way to do it? Using one engine speed for idle 1 and idle 2 is not right.

Hi Bill Geyer,

I did some testing on my heli.

  1. I have external gyro futaba GY-401. There was a problem with tail shaking. After I have fixed vibrations on the engine problem persist. Today I wanted to make sure that arducopter is not messing with external gyro by trying to stabilize tail as a second regulator working in series with futaba gyro. So I have assigned RCIN4 to Motor4 output (where my gyro is connected as rudder channel). To my surprise all tail problems are gone. It is clear now that arducopter set to use external gyro is still doing some pid stabilization, which is fighting with futaba gyro.
    How to set it correctly, so that arducopter will not stabilize tail? I prefer my futaba gyro over Matek FC.

  2. Second thing is my heli is flying quite nice in acro mode, however it is sluggish in stabilize mode. Howto increase gain in stabilize mode without impacting acro mode (this one is very responsive) ?

  3. From my testing I can conclude that GPS (M8N) had no impact on aircraft behavior in stabilize and acro modes. I am quite convinced that magnetometer also didn’t impact those two modes. Now GPS and magnetometer are mounted correctly with strong 3D fix, before it was on the side.

Thanks in advance.

I provided a link to another users thread on this. Please look at that post. I have not done this ever. So I can only tell you what I think works. You will have to turn off the heading hold feature in your gyro and only use the rate damping mode. You will use ardupilot to command the heading as it needs to know that to work properly for any autonomous or GPS aided modes (loiter).

You will have to tune the PIDs for stabilize mode to work properly. The most important part is to properly set the ATC_RAT_XXX_VFF gain where XXX is the axis (PIT or RLL). Please see the tuning guide link that I provided in my first post

I agree it wouldn’t affect ACRO as you are flying straight stick to head but all the issues with attitude determination are either the fact that it didn’t have a good GPS or maybe vibrations affecting the EKF. That would definitely affect stabilize mode

Thanks for Your suggestions. I will do some more investigation an post the results when I have time to do that. I think there are few people out there following this topic, so it might be useful to someone.

@K4cus let me get the autotune feature working and we can have it tune up your yaw axis. I’m hoping I can get you just as good response as your external yaw gyro. We have others that fly 3D heli’s on this forum and were able to get a tune they deemed worthy for 3D flight. I’m trying to automate that so you don’t have to figure it out on your own.

OK, when autotune for heli is done I can try doing it with my heli. :slight_smile: