How to detect landing and turn off motor(s)

I am getting fine performance from my singlecopter now except for one thing:

When it autolands, it often tips over. Example auto mission footage here:

It is very similar to landing an RC helicopter - if you do not get it just right and level, the flight controller thinks it feels a flight force when it is really one of the landing skids hitting first. It then commands the heli to compensate, often tipping it in the direction of whichever skid hit the ground first.

Is there a way with ArduCopter to either stop the motor immediately on touching down?

Or as an alternative, reducing the self-leveling gain right at touch-down?



I just read in the LAND flight mode instructions that the motor will automatically turn off on landing, provided that the throttle stick is low.

I had the throttle stick low since I began the mission by the mission start button in Mission Planner. However the motor did not turn off until the machine tipped over and Arducopter detected a crash.

Any thoughts please? Thanks,


LAND flight mode instructions also discuss that the barometer can get confused when the propwash near the ground disturbs the local pressure.

Dataflash log analysis of what the barometer saw on a typical landing shows some spikes when the aircraft reaches the ground. This is the baro data graphed from a typical landing:

This may be the problem, so I will next wrap the flight controller with some porous foam to keep out the propwash and near-ground disturbances.

I’m stumped. Reduced descent speeds, wrapped foam around the flight controller. The motor still does not stop on landing and pulls the machine over.

Which copter version are you using ? Can you try 3.6.6 ?


I’m using 3.6.8, and the SingleCopter frame type.

Just tried the Ground Effect Compensation feature and it did not work.



Paul, 3.6.7 changed something in the land detection algo, that’s why I suggested 3.6.6

Interesting ThePara. Your words are a much better title for my question.

I prefer to wait until I hear from one of the ArduCopter (SingleCopter) designers. If not, then I’ll try backing down to 3.6.6.



Tried 3.6.6 and it did not help.

Can I use a rangefinder instead of the flight controller’s barometer for the landing sequence?

I have a TFmini which worked well for my automated landing experiments with ArduPlane.

For copter, I cannot tell from the documentation whether you can use the rangefinder just for landing. There is talk of terrain following, but none about just landing.

If I set up the rangefinder and configured Arducopter’s rangefinder parameters to use the rangefinder from say three meters from the ground, will ArduCopter use it instead of the barometer for landing?



I successfully added a rangefinder and configured ArduCopter to use it for landing.

Below you can see in the DF log traces the baro and rangefinder data on a landing that ends with a tip over. The baro has the spike, but the rangefinder doesn’t. In fact, it looks like the baro spike happens as a result of the tip over. At that same moment the rangefinder no longer gives a valid result because with the machine on its side it does not see anything within its detection capability and the data flatlines. Just prior to that it had good distance data, as did the barometer.

However the copter still tipped over after the landing.

In another thread Randy Mackay explained to another flyer that at the moment of landing the copter is still trying to correct for position. As a consequence and especially in my case with the top-heavy SingleCopter machine, the correcting forces cause it to tip over.

So what I really need is way to turn off the motor right when the craft touches down.

Wouldn’t the accelerometers be able to detect the event from the sudden stop? How could I use that as a signal to turn off the motors?



I am still looking for a configuration or software solution to turning off the motor on touch down.

Another choice would be to have the copter stop trying to get the exact location of the landing waypoint when it is less then one meter from the ground.

In the meantime I added wider landing gear legs and got a good landing without a tip over on the first try. The motors automatically turned off after about one second.


So there are also physical solutions.



I think it is a great idea for the system to not trying to look for exact gps landing spot when 1 meter or below above terrain when in landing mode. I think it would avoid 99% of the landing tip over that sometimes occur. What do you think?
Probably this feature would need to be turned off if precision landing is used.

I think your suggestion is a great idea!!

Had three flights this evening. All three of them landed upright and did not tip over, but in two of the three the motor did not turn off until maybe five seconds after touchdown.

In these flights Mission Planner displayed the “Crash: Disarming” message after touchdown, but the DF logs did not include the crash message.

Interestingly, after it landed, the motor spun up for a few seconds, then shut down.

In the plot, the throttle channel output seems to go down to the MOT_SPIN_MIN value when it lands, but then spins up to about 1/3-throttle (1400us) for a few seconds before shutting down.

Does it do this because it thinks it is still flying?

2019-06-22 19-56-26.log (963.7 KB)

I will test changing this parameter later today. Had it set to zero. Changed it to one (meter). It may stop the navigating close to the ground.

Changing the WP_NAVALT_MIN to one meter seemed to work well. Had two good landings where the motor turned off right after touchdown and no tip-overs. For example:

I’m very happy now. Thanks Randy and the creators and testers of Arducopter.


I doubt it makes any difference, probably just a coincidence, when landing it is not navigating but tries to land on the home gps point.
That said i would be happy to be wrong and if this solves the issue i will try it too.