mirror of https://github.com/Desuuuu/klipper.git
gcode: Report the final print_time in debuginput mode
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
parent
9213646c63
commit
1f7c3fc8ec
|
@ -91,7 +91,6 @@ class PrinterStepperEnable:
|
||||||
el.motor_disable(print_time)
|
el.motor_disable(print_time)
|
||||||
self.printer.send_event("stepper_enable:motor_off", print_time)
|
self.printer.send_event("stepper_enable:motor_off", print_time)
|
||||||
toolhead.dwell(DISABLE_STALL_TIME)
|
toolhead.dwell(DISABLE_STALL_TIME)
|
||||||
logging.debug('; Max time of %f', print_time)
|
|
||||||
def motor_debug_enable(self, stepper, enable):
|
def motor_debug_enable(self, stepper, enable):
|
||||||
toolhead = self.printer.lookup_object('toolhead')
|
toolhead = self.printer.lookup_object('toolhead')
|
||||||
toolhead.dwell(DISABLE_STALL_TIME)
|
toolhead.dwell(DISABLE_STALL_TIME)
|
||||||
|
@ -104,7 +103,6 @@ class PrinterStepperEnable:
|
||||||
el.motor_disable(print_time)
|
el.motor_disable(print_time)
|
||||||
logging.info("%s has been manually disabled", stepper)
|
logging.info("%s has been manually disabled", stepper)
|
||||||
toolhead.dwell(DISABLE_STALL_TIME)
|
toolhead.dwell(DISABLE_STALL_TIME)
|
||||||
logging.debug('; Max time of %f', print_time)
|
|
||||||
def _handle_request_restart(self, print_time):
|
def _handle_request_restart(self, print_time):
|
||||||
self.motor_off()
|
self.motor_off()
|
||||||
def cmd_M18(self, gcmd):
|
def cmd_M18(self, gcmd):
|
||||||
|
|
|
@ -675,6 +675,8 @@ class GCodeParser:
|
||||||
def request_restart(self, result):
|
def request_restart(self, result):
|
||||||
if self.is_printer_ready:
|
if self.is_printer_ready:
|
||||||
print_time = self.toolhead.get_last_move_time()
|
print_time = self.toolhead.get_last_move_time()
|
||||||
|
if result == 'exit':
|
||||||
|
logging.info("Exiting (print time %.3fs)" % (print_time,))
|
||||||
self.printer.send_event("gcode:request_restart", print_time)
|
self.printer.send_event("gcode:request_restart", print_time)
|
||||||
self.toolhead.dwell(0.500)
|
self.toolhead.dwell(0.500)
|
||||||
self.toolhead.wait_moves()
|
self.toolhead.wait_moves()
|
||||||
|
|
Loading…
Reference in New Issue