mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-07-02 01:10:34 +08:00
Land detector: fix code style
This commit is contained in:
@@ -165,6 +165,7 @@ bool MulticopterLandDetector::get_landed_state()
|
||||
|
||||
if (minimalThrust && _min_trust_start == 0) {
|
||||
_min_trust_start = now;
|
||||
|
||||
} else if (!minimalThrust) {
|
||||
_min_trust_start = 0;
|
||||
}
|
||||
@@ -197,8 +198,9 @@ bool MulticopterLandDetector::get_landed_state()
|
||||
// falling consider it to be landed. This should even sustain
|
||||
// quite acrobatic flight.
|
||||
if ((_min_trust_start > 0) &&
|
||||
(hrt_elapsed_time(&_min_trust_start) > 8 * 1000 * 1000)) {
|
||||
(hrt_elapsed_time(&_min_trust_start) > 8 * 1000 * 1000)) {
|
||||
return !get_freefall_state();
|
||||
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user