diff --git a/js/kiri-driver-fdm.js b/js/kiri-driver-fdm.js index eed24547..64cbf515 100644 --- a/js/kiri-driver-fdm.js +++ b/js/kiri-driver-fdm.js @@ -330,6 +330,7 @@ var gs_kiri_fdm = exports; seekMMM = process.outputSeekrate * 60, retDist = process.outputRetractDist, retSpeed = process.outputRetractSpeed * 60, + retDwell = Math.round((process.outputRetractDwell || 0) * 1000), // ratio of nozzle area to filament area times // ratio of slice height to filament max noodle height emitPerMM = print.extrudePerMM(device.nozzleSize, device.filamentSize, process.sliceHeight), @@ -482,6 +483,7 @@ var gs_kiri_fdm = exports; dist = lastp ? lastp.distTo2D(out.point) : 0; + // perform retraction if (out.emit && retracted) { moveTo({e:retracted}, retSpeed, "engage " + retracted); retracted = 0; @@ -496,10 +498,12 @@ var gs_kiri_fdm = exports; moveTo({x:x, y:y}, speedMMM); } + // re-engage after post-retraction move if (!retracted && out.retract) { retracted = retDist; moveTo({e:-retracted}, retSpeed, "retract " + retDist); time += (retDist / retSpeed) * 60 * 2; // retraction time + if (retDwell) dwell(retDwell); } // update time and distance diff --git a/js/kiri.js b/js/kiri.js index 37a86f37..7cc0862b 100644 --- a/js/kiri.js +++ b/js/kiri.js @@ -85,6 +85,7 @@ self.kiri.license = exports.LICENSE; outputRetractOver: 1, outputRetractDist: 1, outputRetractSpeed: 1, + outputRetractDwell: 1, outputBrimCount: 1, outputBrimOffset: 1, outputShortPoly: 1, @@ -289,6 +290,7 @@ self.kiri.license = exports.LICENSE; outputRetractOver: 5.0, outputRetractDist: 0.5, outputRetractSpeed: 20, + outputRetractDwell: 0.2, outputWipeSpeed: 20, outputWipeDistance: 0, outputBrimCount: 2, @@ -2400,6 +2402,7 @@ self.kiri.license = exports.LICENSE; // outputRetractOver: UC.newInput("retract over", {title:"move threshold that\ntriggers retraction\n0 to disable", convert:UC.toFloat, modes:FDM}), outputRetractDist: UC.newInput("retract dist", {title:"amount to retract filament", convert:UC.toFloat, modes:FDM}), outputRetractSpeed: UC.newInput("retract rate", {title:"speed of filament\nretraction in mm/s", convert:UC.toInt, modes:FDM}), + outputRetractDwell: UC.newInput("retract dwell", {title:"time between re-engaging\nfilament and movement\nin seconds", convert:UC.toFloat, modes:FDM}), outputWipeSpeed: UC.newInput("wipe speed", {title:"speed while wiping\nnozzle in mm/s", convert:UC.toInt, modes:FDM}), outputWipeDistance: UC.newInput("wipe distance", {title:"distance to wipe nozzle after\neach enclosed island completes\nin millimeters. 0 to disable", convert:UC.toInt, modes:FDM}), outputShortPoly: UC.newInput("short outline", {title:"poly perimeter length\ntriggers short slowdown\nin millimeters", bound:UC.bound(0,200), convert:UC.toFloat, modes:FDM}), diff --git a/notes.md b/notes.md index 25a911ed..a093cfc5 100644 --- a/notes.md +++ b/notes.md @@ -59,9 +59,11 @@ # FDM todo +* fix thin wall support fill artifacts with complex nested polys +* post re-engage dwell (on first layer?) * add support expand value to multi-part spacing (which defaults to 1mm) * add lay-flat auto-rotation or from selected face -* add rafts, thin wall detection, manual supports +* add rafts, manual supports * check for support / brim intersections on first layer * solid fill every other line, two passes. minimize heat/sag. better fill between * add dashed poly output on first connected brim (when offset === 0)