Some fixes related to milling heights and depths.

Fix for large "Step Down".
Correctly handling a part that was moved down the Z axis.
Handle "Finish Depth".
This commit is contained in:
Itai Nahshon
2017-09-15 04:02:16 +03:00
committed by wmayer
parent 32ac63b4f7
commit e2e0735677
3 changed files with 5 additions and 12 deletions

View File

@@ -197,7 +197,7 @@ class ObjectOp(PathOp.ObjectOp):
pathParams['feedrate'] = self.horizFeed
pathParams['feedrate_v'] = self.vertFeed
pathParams['verbose'] = True
pathParams['resume_height'] = obj.StepDown.Value
pathParams['resume_height'] = obj.SafeHeight.Value
pathParams['retraction'] = obj.ClearanceHeight.Value
pathParams['return_end'] = True
# Note that emitting preambles between moves breaks some dressups and prevents path optimization on some controllers
@@ -237,12 +237,13 @@ class ObjectOp(PathOp.ObjectOp):
PathLog.track()
self.endVector = None
finish_step = obj.FinishDepth.Value if hasattr(obj, "FinishDepth") else 0.0
self.depthparams = PathUtils.depth_params(
clearance_height=obj.ClearanceHeight.Value,
safe_height=obj.SafeHeight.Value,
start_depth=obj.StartDepth.Value,
step_down=obj.StepDown.Value,
z_finish_step=0.0,
z_finish_step=finish_step,
final_depth=obj.FinalDepth.Value,
user_depths=None)

View File

@@ -816,7 +816,7 @@ class depth_params:
raise ValueError('z_finish_step must be less than step_down')
self.__clearance_height = clearance_height
self.__safe_height = math.fabs(safe_height)
self.__safe_height = safe_height
self.__start_depth = start_depth
self.__step_down = math.fabs(step_down)
self.__z_finish_step = math.fabs(z_finish_step)