gcode: Move "ok" tracking to GCodeCommand class

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor 2020-04-25 15:30:24 -04:00
parent bf4bd5cfc1
commit 2d4b520260
2 changed files with 18 additions and 29 deletions

View file

@ -304,10 +304,9 @@ class PrinterHeaters:
return " ".join(out)
def cmd_M105(self, gcmd):
# Get Extruder Temperature
gcode = self.printer.lookup_object("gcode")
reactor = self.printer.get_reactor()
msg = self._get_temp(reactor.monotonic())
did_ack = gcode.ack(msg)
did_ack = gcmd.ack(msg)
if not did_ack:
gcmd.respond_raw(msg)
def wait_for_temperature(self, heater):