Loiter mode went to land state during flight, heli started a free falling

Went today to check the 450 helicopter with pixhawk and GPS installed, in an open field.
was a pretty windy situation, but the flight was manageable, decided to try the loiter mode at an altitude of about 10 meters, the heli went into the mode,flight was not so stable but i did not expect much as the wind was pretty gusty. suddenly the heli started falling. i’ve tried adding collective command with no luck, then changed back the mode to stabilize which regained control over the collective, and i was able to stop the fall few centimetres above the ground.
Looked into the data and could not find the reason … any idea ?

following is a link to the log of this flight


@ZvikaF looks like you have your H_COL_MID too high. This should be set for the collective pitch angle that gives you zero thrust. For symmetric blades this is 0 deg collective pitch angle. How did you decide to set this parameter? I am curious only to find out if the wiki is providing bad information.

H_COL_MID is used for two reasons. 1) Collective to yaw mixing and 2) the collective position to determine when the aircraft has landed for autonomous flight. It uses other triggers like acceleration and descent rate but also if the collective is below H_COL_MID. that is why it shutdown the engine or should have shut it down.
I need to look into this a little more into this. But if you set the H_COL_MID properly then you won’t see that again.

@bnsgeyer Thanks Bill, I was really puzzled by the sudden mode change.
As I recall, I got the notion that H_COL_MID is the collective position for hovering and not zero lift…
I had fluctuations on ALT-HOLD and i think this setting stopped it.
I had flown the heli for quit a few flights with this setting without going into LAND mode during flight,
also had hovered more time in LOITER mode without triggering the LAND mode, peculiar.
It has to do something with LOITER mode since, luckily going back to stabilize saved me from crashing .
I wonder on the possibility to simulate this situation on the bench ?
Is there any difference in modes tagging between auto LAND, and LAND status (which means that the heli has landed) ?

thanks again for your time and help.

best regards

That is strange.

I will have to look at why it changed to LAND mode. I did see a GPS error in your log but didn’t dig into it. That could cause it to go into land mode.

You won’t be able to simulate this behavior on the bench. The software is smart enough to know when it is landed. You would really need to know the details of how the software works to bench test this and even then I’m not sure it would be a valid test.

Not sure what you mean by this? please explain.

@bnsgeyer thanks Bill :slight_smile:
regarding the last paragraph, my question is about the difference between LAND mode and AUTOLAND log notification, as I recall, I get the same notifications.

checked the source code on Arducopter : “land_detector.cpp” (looks relevant)
found the following reasons to go into LAND mode :
// check that collective pitch is on lower limit (should be constrained by LAND_COL_MIN)
// check that the average throttle output is near minimum (less than 12.5% hover throttle)
// check that the airframe is not accelerating (not falling or braking after fast forward flight)
// check that vertical speed is within 1m/s of zero

probably the heli went into this state:
// sets motors throttle_low_comp value depending upon vehicle state
// low values favor pilot/autopilot throttle over attitude control,
// high values favor attitude control over throttle
// has no effect when throttle is above hover throttle

if ((large_angle_request && !landing) || large_angle_error || accel_moving || descent_not_demanded) {
} else {

wonder if the heli met all pre-requests ?!

I do have GPS glitches from time to time, specially as the antenna is close to the mast, hoped i can continue like that, moving back the GPS will alter the CG and will need a big changes.
Thought that if this happens in auto mode, the system will exit to STABILIZE mode,

What you have pulled from the landing detector only determines if the vehicle has completed the landing and then it sets the land_complete flag. It does not change the mode from loiter to land.

I have to check into this further because in loiter your collective should have never been allowed below H_COL_MID except if your speed was greater than 5 m/s.

I guess it has to be able to go below the H_COL_MID while landing but once landed can not go below it

Thanks Bill, According to the source code those were the condition to get the collective to minimum position, there are more checks for setting “land complete maybe” flag, and set “land_complete” flag and disarm motors (if disarm-on-land is configured).

I have changed the H_COL_MID from 1490 to 1364 , will test later the ALT_HOLD behavior.

The 1364 was calculated from H_COL_MIN of 1300 (-3 deg) and H_COL_MAX of 1620 at 12 deg.

Did not understand the PWM meaning of the parameters, I suppose this is imaginary one, as the heli have CCPM configuration.

Also changed PILOT_THR_BHV to “high throttle cancels land”

The update_throttle_mix method that you refer to does not apply to heli’s, only to multi’s. You will notice at the beginning of that method there is a statement that reads

This means the compiler will not compile this method and thus heli does not use it.

Oops … did not notice that (the ! skipped my eyes) :slight_smile:

Tried the updated parameters in confined hovering flights, the ALT_HOLD mode worked fine.
Also could engage for a short period LOITER … at one of the checks the heli did sink slowly and completed landing, the mode did change to “landing completed”

looks as if both altitude and position handling is sluggish, is it the heli rate/position control loops or the position control loops that should be checked ?