klippy: Store printer startup parameters in new "start_args" dictionary

Store pertinent information from the software startup in a dictionary
that the various printer components can access instead of in
individual variables in the Printer() class.  This makes it easier to
add future command-line options.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor 2017-08-21 17:19:43 -04:00
parent b80c488d36
commit 268834e4ae
6 changed files with 64 additions and 71 deletions

View file

@ -91,7 +91,7 @@ class PrinterHomingStepper(PrinterStepper):
logging.info("Endstop for %s is not accurate enough for stepper"
" phase adjustment" % (name,))
self.homing_stepper_phases = None
if printer.mcu.is_fileoutput():
if printer.get_start_args().get('debugoutput') is not None:
self.homing_endstop_accuracy = self.homing_stepper_phases
def enable_endstop_checking(self, move_time, step_time):
mcu_time = self.mcu_endstop.print_to_mcu_time(move_time)