mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-21 21:43:33 +08:00
attitude_fw delete unused and cleanup
This commit is contained in:
@@ -48,25 +48,6 @@
|
||||
|
||||
#include "ecl_controller.h"
|
||||
|
||||
#include <stdio.h>
|
||||
#include <mathlib/mathlib.h>
|
||||
|
||||
ECL_Controller::ECL_Controller(const char *name) :
|
||||
_last_run(0),
|
||||
_tc(0.1f),
|
||||
_k_p(0.0f),
|
||||
_k_i(0.0f),
|
||||
_k_ff(0.0f),
|
||||
_integrator_max(0.0f),
|
||||
_max_rate(0.0f),
|
||||
_last_output(0.0f),
|
||||
_integrator(0.0f),
|
||||
_rate_error(0.0f),
|
||||
_rate_setpoint(0.0f),
|
||||
_bodyrate_setpoint(0.0f)
|
||||
{
|
||||
}
|
||||
|
||||
void ECL_Controller::reset_integrator()
|
||||
{
|
||||
_integrator = 0.0f;
|
||||
@@ -123,7 +104,7 @@ float ECL_Controller::constrain_airspeed(float airspeed, float minspeed, float m
|
||||
{
|
||||
float airspeed_result = airspeed;
|
||||
|
||||
if (!PX4_ISFINITE(airspeed)) {
|
||||
if (!ISFINITE(airspeed)) {
|
||||
/* airspeed is NaN, +- INF or not available, pick center of band */
|
||||
airspeed_result = 0.5f * (minspeed + maxspeed);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user