process this instance in a list of steps supplied by the designer to generate and return a line of gcode
(self, state)
| 66 | return system_point |
| 67 | |
| 68 | def gcode(self, state): |
| 69 | 'process this instance in a list of steps supplied by the designer to generate and return a line of gcode' |
| 70 | self_systemXYZ = self.inverse_kinematics(state) |
| 71 | XYZBC_str = self.XYZBC_gcode(self_systemXYZ, state.point_systemXYZ) |
| 72 | if XYZBC_str != None: # only write a line of gcode if movement occurs |
| 73 | G_str = 'G1 ' if state.extruder.on else 'G0 ' |
| 74 | F_str = state.printer.f_gcode(state) |
| 75 | E_str = state.extruder.e_gcode(self, state) |
| 76 | gcode_str = f'{G_str}{F_str}{XYZBC_str}{E_str}' |
| 77 | state.printer.speed_changed = False |
| 78 | state.point.update_from(self) |
| 79 | state.point_systemXYZ.update_from(self_systemXYZ) |
| 80 | return gcode_str.strip() # strip the final space |
no test coverage detected