From ea85d419dea23cac464763c9b36e1b59c9074588 Mon Sep 17 00:00:00 2001 From: Kevin O'Connor Date: Fri, 8 Jan 2021 12:07:45 -0500 Subject: gcode: Move definition of CommandError and Coord from homing.py to gcode.py Signed-off-by: Kevin O'Connor --- klippy/extras/gcode_move.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'klippy/extras/gcode_move.py') diff --git a/klippy/extras/gcode_move.py b/klippy/extras/gcode_move.py index 08c926e9..4bdfdf8b 100644 --- a/klippy/extras/gcode_move.py +++ b/klippy/extras/gcode_move.py @@ -1,6 +1,6 @@ # G-Code G1 movement commands (and associated coordinate manipulation) # -# Copyright (C) 2016-2020 Kevin O'Connor +# Copyright (C) 2016-2021 Kevin O'Connor # # This file may be distributed under the terms of the GNU GPLv3 license. import logging @@ -34,6 +34,7 @@ class GCodeMove: gcode.register_command('G0', self.cmd_G1) gcode.register_command('M114', self.cmd_M114, True) gcode.register_command('GET_POSITION', self.cmd_GET_POSITION, True) + self.Coord = gcode.Coord # G-Code coordinate manipulation self.absolute_coord = self.absolute_extrude = True self.base_position = [0.0, 0.0, 0.0, 0.0] @@ -94,9 +95,9 @@ class GCodeMove: 'extrude_factor': self.extrude_factor, 'absolute_coordinates': self.absolute_coord, 'absolute_extrude': self.absolute_extrude, - 'homing_origin': homing.Coord(*self.homing_position), - 'position': homing.Coord(*self.last_position), - 'gcode_position': homing.Coord(*move_position), + 'homing_origin': self.Coord(*self.homing_position), + 'position': self.Coord(*self.last_position), + 'gcode_position': self.Coord(*move_position), } def reset_last_position(self): if self.is_printer_ready: -- cgit v1.2.3-70-g09d2