override G80 for prusa specific

This commit is contained in:
Emory Barlow 2022-05-03 23:49:02 -04:00
parent 77784025a5
commit 50b55dce77
2 changed files with 27 additions and 18 deletions

View File

@ -54,7 +54,7 @@ __all__ = [
'GCodeArcMoveCW', 'GCodeArcMoveCW',
'GCodeBoringCycleDwellFeedOut', 'GCodeBoringCycleDwellFeedOut',
'GCodeBoringCycleFeedOut', 'GCodeBoringCycleFeedOut',
'GCodeCancelCannedCycle', #'GCodeCancelCannedCycle',
'GCodeCancelToolLengthOffset', 'GCodeCancelToolLengthOffset',
'GCodeCannedCycle', 'GCodeCannedCycle',
'GCodeCannedCycleReturnPrevLevel', 'GCodeCannedCycleReturnPrevLevel',
@ -336,7 +336,7 @@ from .gcodes import (
GCodeArcMoveCW, GCodeArcMoveCW,
GCodeBoringCycleDwellFeedOut, GCodeBoringCycleDwellFeedOut,
GCodeBoringCycleFeedOut, GCodeBoringCycleFeedOut,
GCodeCancelCannedCycle, #GCodeCancelCannedCycle,
GCodeCancelToolLengthOffset, GCodeCancelToolLengthOffset,
GCodeCannedCycle, GCodeCannedCycle,
GCodeCannedCycleReturnPrevLevel, GCodeCannedCycleReturnPrevLevel,

View File

@ -508,22 +508,24 @@ class GCodeRigidTapping(GCodeMotion):
param_letters = GCodeMotion.param_letters | set('K') param_letters = GCodeMotion.param_letters | set('K')
word_key = Word('G', 33.1) word_key = Word('G', 33.1)
#
class GCodeCancelCannedCycle(GCodeMotion): # Conflicts with prusa command
"""G80: Cancel Canned Cycle""" #
word_key = Word('G', 80) #class GCodeCancelCannedCycle(GCodeMotion):
# Modal Group # """G80: Cancel Canned Cycle"""
# Technically G80 belongs to the motion modal group, however it's often # word_key = Word('G', 80)
# expressed in the same line as another motion command. # # Modal Group
# This is alowed, but executed just prior to any other motion command # # Technically G80 belongs to the motion modal group, however it's often
# eg: G00 G80 # # expressed in the same line as another motion command.
# will leave the machine in rapid motion mode # # This is alowed, but executed just prior to any other motion command
# Just running G80 will leave machine with no motion mode. # # eg: G00 G80
modal_group = None # # will leave the machine in rapid motion mode
exec_order = 241 # # Just running G80 will leave machine with no motion mode.
# modal_group = None
def _process(self, machine): # exec_order = 241
machine.mode.motion = None #
# def _process(self, machine):
# machine.mode.motion = None
# ======================= Canned Cycles ======================= # ======================= Canned Cycles =======================
@ -1375,6 +1377,7 @@ class GCodeUserDefined(GCodeNonModal):
# M204 S T Acceleration settings # M204 S T Acceleration settings
# M221 S T Set extrude factor override percentage # M221 S T Set extrude factor override percentage
# M106 S Set fan speed # M106 S Set fan speed
# G80 N R V L R F B Mesh-based Z probe
class GCodePrintChecking(GCode): class GCodePrintChecking(GCode):
exec_order = 999 exec_order = 999
@ -1461,6 +1464,12 @@ class GCodeSetFanSpeed(GCode):
param_letters = set('S') param_letters = set('S')
word_key = Word('M', 106) word_key = Word('M', 106)
class GCodeMeshBasedZProbe(GCode):
exec_order = 999
modal_group = MODAL_GROUP_MAP['user_defined']
param_letters = set('NRVLRFB')
word_key = Word('G', 80)
# ======================= Utilities ======================= # ======================= Utilities =======================
def _subclasses_level(root_class, recursion_level=0): def _subclasses_level(root_class, recursion_level=0):