mirror of https://github.com/ArduPilot/ardupilot
AP_Motors: Tradheli - maintain consistent variable types as used in calcs
add override to declaration of new functions
This commit is contained in:
parent
cca58e393a
commit
51d4029f03
|
@ -74,10 +74,10 @@ public:
|
|||
bool rotor_speed_above_critical() const override { return _rotor.get_rotor_speed() > _rotor.get_critical_speed(); }
|
||||
|
||||
// get_governor_output
|
||||
float get_governor_output() const { return _rotor.get_governor_output(); }
|
||||
float get_governor_output() const override { return _rotor.get_governor_output(); }
|
||||
|
||||
// get_control_output
|
||||
float get_control_output() const { return _rotor.get_control_output(); }
|
||||
float get_control_output() const override { return _rotor.get_control_output(); }
|
||||
|
||||
// calculate_scalars - recalculates various scalars used
|
||||
void calculate_scalars() override;
|
||||
|
|
|
@ -55,10 +55,10 @@ public:
|
|||
bool rotor_speed_above_critical() const override { return _rotor.get_rotor_speed() > _rotor.get_critical_speed(); }
|
||||
|
||||
// get_governor_output
|
||||
float get_governor_output() const { return _rotor.get_governor_output(); }
|
||||
float get_governor_output() const override { return _rotor.get_governor_output(); }
|
||||
|
||||
// get_control_output
|
||||
float get_control_output() const { return _rotor.get_control_output(); }
|
||||
float get_control_output() const override { return _rotor.get_control_output(); }
|
||||
|
||||
// calculate_scalars - recalculates various scalars used
|
||||
void calculate_scalars() override;
|
||||
|
|
|
@ -69,7 +69,7 @@ public:
|
|||
float get_rotor_speed() const;
|
||||
|
||||
// set_rotor_rpm - when speed sensor is available for governor
|
||||
void set_rotor_rpm(int16_t rotor_rpm) {_rotor_rpm = rotor_rpm; }
|
||||
void set_rotor_rpm(int16_t rotor_rpm) {_rotor_rpm = (float)rotor_rpm; }
|
||||
|
||||
// get_governor_output
|
||||
float get_governor_output() const { return _governor_output; }
|
||||
|
@ -113,11 +113,11 @@ private:
|
|||
float _thrcrv_poly[4][4]; // spline polynomials for throttle curve interpolation
|
||||
uint16_t _power_slewrate = 0; // slewrate for throttle (percentage per second)
|
||||
float _collective_in; // collective in for throttle curve calculation, range 0-1.0f
|
||||
int16_t _rotor_rpm; // rotor rpm from speed sensor for governor
|
||||
float _rotor_rpm; // rotor rpm from speed sensor for governor
|
||||
float _governor_disengage = 0.0f; // throttle percentage where governor disenages to allow return to flight idle
|
||||
float _governor_droop_setting = 0.0f; // governor droop setting, range 0-100%
|
||||
float _governor_output = 0.0f; // governor output for rotor speed control
|
||||
int16_t _governor_setpoint = 0.0f; // governor speed setpoint, range 800-3500 rpm
|
||||
float _governor_setpoint = 0.0f; // governor speed setpoint, range 800-3500 rpm
|
||||
bool _governor_engage = false; // RSC governor status flag for soft-start
|
||||
float _governor_tc = 0.0f; // governor throttle curve gain, range 50-100%
|
||||
|
||||
|
|
|
@ -73,10 +73,10 @@ public:
|
|||
bool rotor_speed_above_critical() const override { return _main_rotor.get_rotor_speed() > _main_rotor.get_critical_speed(); }
|
||||
|
||||
// get_governor_output
|
||||
float get_governor_output() const { return _main_rotor.get_governor_output(); }
|
||||
float get_governor_output() const override { return _main_rotor.get_governor_output(); }
|
||||
|
||||
// get_control_output
|
||||
float get_control_output() const { return _main_rotor.get_control_output(); }
|
||||
float get_control_output() const override{ return _main_rotor.get_control_output(); }
|
||||
|
||||
// calculate_scalars - recalculates various scalars used
|
||||
void calculate_scalars() override;
|
||||
|
|
Loading…
Reference in New Issue