From 387fe51a5615a7a3b99a65124c9151e70bf56b31 Mon Sep 17 00:00:00 2001 From: Erik van der Zalm Date: Fri, 9 Mar 2012 20:20:01 +0100 Subject: [PATCH] Do not disable steppers when there are moves in the queue. --- Marlin/Marlin.pde | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/Marlin/Marlin.pde b/Marlin/Marlin.pde index f7a8c289f1..b51522317f 100644 --- a/Marlin/Marlin.pde +++ b/Marlin/Marlin.pde @@ -576,6 +576,7 @@ void process_commands() saved_feedrate = feedrate; saved_feedmultiply = feedmultiply; feedmultiply = 100; + previous_millis_cmd = millis(); enable_endstops(true); @@ -1314,12 +1315,11 @@ void prepare_move() if (destination[Y_AXIS] > Y_MAX_LENGTH) destination[Y_AXIS] = Y_MAX_LENGTH; if (destination[Z_AXIS] > Z_MAX_LENGTH) destination[Z_AXIS] = Z_MAX_LENGTH; } - + previous_millis_cmd = millis(); plan_buffer_line(destination[X_AXIS], destination[Y_AXIS], destination[Z_AXIS], destination[E_AXIS], feedrate*feedmultiply/60/100.0, active_extruder); for(int8_t i=0; i < NUM_AXIS; i++) { current_position[i] = destination[i]; } - previous_millis_cmd = millis(); } void prepare_arc_move(char isclockwise) { @@ -1345,12 +1345,14 @@ void manage_inactivity(byte debug) if(stepper_inactive_time) { if( (millis() - previous_millis_cmd) > stepper_inactive_time ) { - disable_x(); - disable_y(); - disable_z(); - disable_e0(); - disable_e1(); - disable_e2(); + if(blocks_queued() == false) { + disable_x(); + disable_y(); + disable_z(); + disable_e0(); + disable_e1(); + disable_e2(); + } } } #ifdef EXTRUDER_RUNOUT_PREVENT