|
|
|
@ -11,7 +11,7 @@ bool Copter::stabilize_init(bool ignore_checks)
@@ -11,7 +11,7 @@ bool Copter::stabilize_init(bool ignore_checks)
|
|
|
|
|
{ |
|
|
|
|
// if landed and the mode we're switching from does not have manual throttle and the throttle stick is too high
|
|
|
|
|
if (motors.armed() && ap.land_complete && !mode_has_manual_throttle(control_mode) && |
|
|
|
|
(get_pilot_desired_throttle(channel_throttle->get_control_in(), 0.0f) > get_non_takeoff_throttle())) { |
|
|
|
|
(get_pilot_desired_throttle(channel_throttle->get_control_in()) > get_non_takeoff_throttle())) { |
|
|
|
|
return false; |
|
|
|
|
} |
|
|
|
|
// set target altitude to zero for reporting
|
|
|
|
@ -51,7 +51,7 @@ void Copter::stabilize_run()
@@ -51,7 +51,7 @@ void Copter::stabilize_run()
|
|
|
|
|
target_yaw_rate = get_pilot_desired_yaw_rate(channel_yaw->get_control_in()); |
|
|
|
|
|
|
|
|
|
// get pilot's desired throttle
|
|
|
|
|
pilot_throttle_scaled = get_pilot_desired_throttle(channel_throttle->get_control_in(), 0.0f); |
|
|
|
|
pilot_throttle_scaled = get_pilot_desired_throttle(channel_throttle->get_control_in()); |
|
|
|
|
|
|
|
|
|
// call attitude controller
|
|
|
|
|
attitude_control.input_euler_angle_roll_pitch_euler_rate_yaw(target_roll, target_pitch, target_yaw_rate, get_smoothing_gain()); |
|
|
|
|