diff --git a/ArduSub/joystick.cpp b/ArduSub/joystick.cpp index a0f13a1761..1a2d648cf6 100644 --- a/ArduSub/joystick.cpp +++ b/ArduSub/joystick.cpp @@ -295,6 +295,9 @@ void Sub::handle_jsbutton_press(uint8_t button, bool shift, bool held) pitchTrim = constrain_float(pitchTrim-10,-200,200); break; case JSButton::button_function_t::k_input_hold_set: + if(!motors.armed()) { + break; + } if (!held) { zTrim = abs(z_last-500) > 50 ? z_last-500 : 0; xTrim = abs(x_last) > 50 ? x_last : 0;