diff --git a/libraries/AP_HAL_SITL/SITL_State.cpp b/libraries/AP_HAL_SITL/SITL_State.cpp index f5a4ca0ca5..176d41922d 100644 --- a/libraries/AP_HAL_SITL/SITL_State.cpp +++ b/libraries/AP_HAL_SITL/SITL_State.cpp @@ -440,6 +440,17 @@ bool SITL_State::_read_rc_sitl_input() } pwm_pkt; const ssize_t size = _sitl_rc_in.recv(&pwm_pkt, sizeof(pwm_pkt), 0); + + if (_sitl->rc_fail == SITL::SIM::SITL_RCFail_Throttle950) { + // discard anything we just read from the "receiver" and set + // values to bind values: + for (uint8_t i=0; irc_fail == SITL::SIM::SITL_RCFail_Throttle950) { - if (i == 2) { - // set throttle (assumed to be on channel 3...) - pwm = 950; - } else { - // centre all other inputs - pwm = 1500; - } - } pwm_input[i] = pwm; } }