gcode: "gcode_position" and toolhead "position" as get_status() named tuple

Add "gcode_position" named tuple to gcode.get_status(). Add a
"position" named tuple to toolhead.get_status().

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor 2019-05-28 17:40:19 -04:00 committed by KevinOConnor
parent 4ccc218b06
commit 6e88320d62
3 changed files with 6 additions and 2 deletions

View file

@ -417,6 +417,7 @@ class ToolHead:
status = "Ready"
return { 'status': status, 'print_time': print_time,
'estimated_print_time': estimated_print_time,
'position': homing.Coord(*self.commanded_pos),
'printing_time': print_time - last_print_start_time }
def _handle_request_restart(self, print_time):
self.motor_off()