Rover: allow scaled passthru to go to trim on rc failsafe

This commit is contained in:
Henry Wurzburg 2023-06-22 18:10:42 -05:00 committed by Peter Barker
parent 2e1b7897fd
commit 53a4194297
2 changed files with 7 additions and 1 deletions

View File

@ -62,9 +62,14 @@ void RC_Channel_Rover::init_aux_function(const aux_func_t ch_option, const AuxSw
}
bool RC_Channels_Rover::in_rc_failsafe() const
{
return rover.failsafe.bits & FAILSAFE_EVENT_THROTTLE;
}
bool RC_Channels_Rover::has_valid_input() const
{
if (rover.failsafe.bits & FAILSAFE_EVENT_THROTTLE) {
if (in_rc_failsafe()) {
return false;
}
return true;

View File

@ -32,6 +32,7 @@ class RC_Channels_Rover : public RC_Channels
public:
bool in_rc_failsafe() const override;
bool has_valid_input() const override;
RC_Channel *get_arming_channel(void) const override;