PX4 Firmware
PX4 Autopilot Software http://px4.io
|
#include <ecl_yaw_controller.h>
Public Types | |
enum | { COORD_METHOD_OPEN = 0, COORD_METHOD_CLOSEACC = 1 } |
Public Member Functions | |
ECL_YawController ()=default | |
~ECL_YawController ()=default | |
float | control_attitude (const struct ECL_ControlData &ctl_data) override |
float | control_euler_rate (const struct ECL_ControlData &ctl_data) override |
float | control_bodyrate (const struct ECL_ControlData &ctl_data) override |
void | set_coordinated_min_speed (float coordinated_min_speed) |
void | set_coordinated_method (int32_t coordinated_method) |
Public Member Functions inherited from ECL_Controller | |
ECL_Controller () | |
virtual | ~ECL_Controller ()=default |
void | set_time_constant (float time_constant) |
void | set_k_p (float k_p) |
void | set_k_i (float k_i) |
void | set_k_ff (float k_ff) |
void | set_integrator_max (float max) |
void | set_max_rate (float max_rate) |
void | set_bodyrate_setpoint (float rate) |
float | get_rate_error () |
float | get_desired_rate () |
float | get_desired_bodyrate () |
float | get_integrator () |
void | reset_integrator () |
Protected Member Functions | |
float | control_attitude_impl_openloop (const struct ECL_ControlData &ctl_data) |
float | control_attitude_impl_accclosedloop (const struct ECL_ControlData &ctl_data) |
Protected Member Functions inherited from ECL_Controller | |
float | constrain_airspeed (float airspeed, float minspeed, float maxspeed) |
Protected Attributes | |
float | _coordinated_min_speed {1.0f} |
float | _max_rate {0.0f} |
int32_t | _coordinated_method {COORD_METHOD_OPEN} |
Protected Attributes inherited from ECL_Controller | |
uint64_t | _last_run |
float | _tc |
float | _k_p |
float | _k_i |
float | _k_ff |
float | _integrator_max |
float | _max_rate |
float | _last_output |
float | _integrator |
float | _rate_error |
float | _rate_setpoint |
float | _bodyrate_setpoint |
Definition at line 53 of file ecl_yaw_controller.h.
anonymous enum |
Enumerator | |
---|---|
COORD_METHOD_OPEN | |
COORD_METHOD_CLOSEACC |
Definition at line 75 of file ecl_yaw_controller.h.
|
default |
|
default |
|
overridevirtual |
Implements ECL_Controller.
Definition at line 46 of file ecl_yaw_controller.cpp.
References _coordinated_method, ECL_Controller::_rate_setpoint, control_attitude_impl_accclosedloop(), control_attitude_impl_openloop(), COORD_METHOD_CLOSEACC, COORD_METHOD_OPEN, ecl_absolute_time, ecl_elapsed_time, and ECL_WARN.
Referenced by FixedwingAttitudeControl::Run().
|
protected |
Definition at line 187 of file ecl_yaw_controller.cpp.
Referenced by control_attitude().
|
protected |
Definition at line 67 of file ecl_yaw_controller.cpp.
References ECL_Controller::_rate_setpoint, ECL_ControlData::airspeed, ECL_ControlData::airspeed_min, CONSTANTS_ONE_G, math::constrain(), ECL_WARN, ISFINITE, ECL_ControlData::pitch, ECL_ControlData::pitch_rate_setpoint, math::radians(), ECL_ControlData::roll, ECL_ControlData::roll_rate_setpoint, and ECL_ControlData::roll_setpoint.
Referenced by control_attitude().
|
overridevirtual |
Implements ECL_Controller.
Definition at line 117 of file ecl_yaw_controller.cpp.
References ECL_Controller::_bodyrate_setpoint, _coordinated_method, ECL_Controller::_integrator, ECL_Controller::_integrator_max, ECL_Controller::_k_ff, ECL_Controller::_k_i, ECL_Controller::_k_p, ECL_Controller::_last_output, ECL_Controller::_last_run, ECL_Controller::_rate_error, ECL_ControlData::airspeed, ECL_ControlData::airspeed_max, ECL_ControlData::airspeed_min, ECL_ControlData::body_y_rate, ECL_ControlData::body_z_rate, math::constrain(), COORD_METHOD_CLOSEACC, dt, ecl_absolute_time, ecl_elapsed_time, f(), ISFINITE, ECL_ControlData::lock_integrator, math::max(), math::min(), ECL_ControlData::pitch, ECL_ControlData::pitch_rate_setpoint, ECL_ControlData::roll, and ECL_ControlData::scaler.
Referenced by control_euler_rate(), and FixedwingAttitudeControl::Run().
|
overridevirtual |
Implements ECL_Controller.
Definition at line 195 of file ecl_yaw_controller.cpp.
References ECL_Controller::_bodyrate_setpoint, ECL_Controller::_rate_setpoint, control_bodyrate(), ECL_ControlData::pitch, ECL_ControlData::pitch_rate_setpoint, ECL_ControlData::roll, and ECL_Controller::set_bodyrate_setpoint().
Referenced by FixedwingAttitudeControl::Run().
|
inline |
Definition at line 70 of file ecl_yaw_controller.h.
References _coordinated_method.
|
inline |
Definition at line 65 of file ecl_yaw_controller.h.
References _coordinated_min_speed.
|
protected |
Definition at line 84 of file ecl_yaw_controller.h.
Referenced by control_attitude(), control_bodyrate(), and set_coordinated_method().
|
protected |
Definition at line 81 of file ecl_yaw_controller.h.
Referenced by set_coordinated_min_speed().
|
protected |
Definition at line 82 of file ecl_yaw_controller.h.