🐛 Fix "no T param" handling
This commit is contained in:
@@ -134,7 +134,7 @@ static void say_stealth_status() {
|
||||
*/
|
||||
void GcodeSuite::M569() {
|
||||
if (parser.seen('S'))
|
||||
set_stealth_status(parser.value_bool(), get_target_e_stepper_from_command());
|
||||
set_stealth_status(parser.value_bool(), get_target_e_stepper_from_command(-2));
|
||||
else
|
||||
say_stealth_status();
|
||||
}
|
||||
|
||||
@@ -112,7 +112,7 @@ void GcodeSuite::M906() {
|
||||
|
||||
#if E_STEPPERS
|
||||
case E_AXIS: {
|
||||
const int8_t eindex = get_target_e_stepper_from_command();
|
||||
const int8_t eindex = get_target_e_stepper_from_command(-2);
|
||||
#if AXIS_IS_TMC(E0)
|
||||
if (eindex < 0 || eindex == 0) TMC_SET_CURRENT(E0);
|
||||
#endif
|
||||
|
||||
@@ -291,7 +291,7 @@
|
||||
break;
|
||||
#if E_STEPPERS
|
||||
case E_AXIS: {
|
||||
const int8_t eindex = get_target_e_stepper_from_command();
|
||||
const int8_t eindex = get_target_e_stepper_from_command(-2);
|
||||
TERN_(E0_HAS_STEALTHCHOP, if (eindex < 0 || eindex == 0) TMC_SET_PWMTHRS_E(0));
|
||||
TERN_(E1_HAS_STEALTHCHOP, if (eindex < 0 || eindex == 1) TMC_SET_PWMTHRS_E(1));
|
||||
TERN_(E2_HAS_STEALTHCHOP, if (eindex < 0 || eindex == 2) TMC_SET_PWMTHRS_E(2));
|
||||
|
||||
Reference in New Issue
Block a user