diff --git a/src/mode/cam/prepare.js b/src/mode/cam/prepare.js index 6008d7c6..efcd2857 100644 --- a/src/mode/cam/prepare.js +++ b/src/mode/cam/prepare.js @@ -312,11 +312,11 @@ } } - // synth new plunge rate - if (synthPlunge && deltaZ <= -tolerance) { + // set new plunge rate + if (deltaZ < -tolerance) { let threshold = Math.min(deltaXY / 2, absDeltaZ), modifier = threshold / absDeltaZ; - if (threshold && modifier && deltaXY > tolerance) { + if (synthPlunge && threshold && modifier && deltaXY > tolerance) { // use modifier to speed up long XY move plunge rates rate = Math.round(plungeRate + ((feedRate - plungeRate) * modifier)); } else {