mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-22 11:53:34 +08:00
MC land detector: remove LNDMC_THR_RANGE param
- no airframe changes the default - it does not make much sense to be able to configure the 0.1 threshold but the 0.3 threshold for ground contact detection cannot be configured.
This commit is contained in:
@@ -75,7 +75,6 @@ MulticopterLandDetector::MulticopterLandDetector()
|
||||
_paramHandle.maxRotation = param_find("LNDMC_ROT_MAX");
|
||||
_paramHandle.maxVelocity = param_find("LNDMC_XY_VEL_MAX");
|
||||
_paramHandle.maxClimbRate = param_find("LNDMC_Z_VEL_MAX");
|
||||
_paramHandle.throttleRange = param_find("LNDMC_THR_RANGE");
|
||||
_paramHandle.minThrottle = param_find("MPC_THR_MIN");
|
||||
_paramHandle.hoverThrottle = param_find("MPC_THR_HOVER");
|
||||
_paramHandle.minManThrottle = param_find("MPC_MANTHR_MIN");
|
||||
@@ -121,7 +120,6 @@ void MulticopterLandDetector::_update_params()
|
||||
_params.maxRotation_rad_s = math::radians(_params.maxRotation_rad_s);
|
||||
param_get(_paramHandle.minThrottle, &_params.minThrottle);
|
||||
param_get(_paramHandle.hoverThrottle, &_params.hoverThrottle);
|
||||
param_get(_paramHandle.throttleRange, &_params.throttleRange);
|
||||
param_get(_paramHandle.minManThrottle, &_params.minManThrottle);
|
||||
param_get(_paramHandle.freefall_acc_threshold, &_params.freefall_acc_threshold);
|
||||
param_get(_paramHandle.freefall_trigger_time, &_params.freefall_trigger_time);
|
||||
@@ -320,7 +318,7 @@ bool MulticopterLandDetector::_has_low_thrust()
|
||||
bool MulticopterLandDetector::_has_minimal_thrust()
|
||||
{
|
||||
// 10% of throttle range between min and hover once we entered ground contact
|
||||
float sys_min_throttle = _params.minThrottle + (_params.hoverThrottle - _params.minThrottle) * _params.throttleRange;
|
||||
float sys_min_throttle = _params.minThrottle + (_params.hoverThrottle - _params.minThrottle) * 0.1f;
|
||||
|
||||
// Determine the system min throttle based on flight mode
|
||||
if (!_control_mode.flag_control_climb_rate_enabled) {
|
||||
|
||||
Reference in New Issue
Block a user