resurrect wipe as a post-retraction option
This commit is contained in:
parent
dc55da0232
commit
7ab7701f8c
6 changed files with 22 additions and 12 deletions
|
|
@ -330,13 +330,13 @@
|
||||||
outputFanLayer: 1,
|
outputFanLayer: 1,
|
||||||
outputRetractDist: 1.5,
|
outputRetractDist: 1.5,
|
||||||
outputRetractSpeed: 40,
|
outputRetractSpeed: 40,
|
||||||
|
outputRetractWipe: 0,
|
||||||
outputRetractDwell: 20,
|
outputRetractDwell: 20,
|
||||||
outputBrimCount: 2,
|
outputBrimCount: 2,
|
||||||
outputBrimOffset: 2,
|
outputBrimOffset: 2,
|
||||||
outputShortPoly: 100.0,
|
outputShortPoly: 100.0,
|
||||||
outputMinSpeed: 10.0,
|
outputMinSpeed: 10.0,
|
||||||
outputCoastDist: 0,
|
outputCoastDist: 0,
|
||||||
outputWipeDistance: 0,
|
|
||||||
outputLayerRetract: false,
|
outputLayerRetract: false,
|
||||||
outputOriginCenter: true,
|
outputOriginCenter: true,
|
||||||
outputLoopLayers: "",
|
outputLoopLayers: "",
|
||||||
|
|
|
||||||
|
|
@ -1786,9 +1786,9 @@
|
||||||
advanced: UC.newGroup(LANG.ad_menu, null, {modes:FDM}),
|
advanced: UC.newGroup(LANG.ad_menu, null, {modes:FDM}),
|
||||||
outputRetractDist: UC.newInput(LANG.ad_rdst_s, {title:LANG.ad_rdst_l, convert:UC.toFloat, modes:FDM}),
|
outputRetractDist: UC.newInput(LANG.ad_rdst_s, {title:LANG.ad_rdst_l, convert:UC.toFloat, modes:FDM}),
|
||||||
outputRetractSpeed: UC.newInput(LANG.ad_rrat_s, {title:LANG.ad_rrat_l, convert:UC.toInt, modes:FDM}),
|
outputRetractSpeed: UC.newInput(LANG.ad_rrat_s, {title:LANG.ad_rrat_l, convert:UC.toInt, modes:FDM}),
|
||||||
|
outputRetractWipe: UC.newInput(LANG.ad_wpln_s, {title:LANG.ad_wpln_l, bound:UC.bound(0.0,10), convert:UC.toFloat, modes:FDM}),
|
||||||
outputRetractDwell: UC.newInput(LANG.ad_rdwl_s, {title:LANG.ad_rdwl_l, convert:UC.toInt, modes:FDM}),
|
outputRetractDwell: UC.newInput(LANG.ad_rdwl_s, {title:LANG.ad_rdwl_l, convert:UC.toInt, modes:FDM}),
|
||||||
fdmSep: UC.newBlank({class:"pop-sep", modes:FDM}),
|
fdmSep: UC.newBlank({class:"pop-sep", modes:FDM}),
|
||||||
// outputWipeDistance: UC.newInput("wipe", {title:"non-printing move at\close of polygon\nin millimeters", bound:UC.bound(0.0,10), convert:UC.toFloat, modes:FDM}),
|
|
||||||
sliceSolidMinArea: UC.newInput(LANG.ad_msol_s, {title:LANG.ad_msol_l, convert:UC.toFloat, modes:FDM}),
|
sliceSolidMinArea: UC.newInput(LANG.ad_msol_s, {title:LANG.ad_msol_l, convert:UC.toFloat, modes:FDM}),
|
||||||
outputMinSpeed: UC.newInput(LANG.ad_mins_s, {title:LANG.ad_mins_l, bound:UC.bound(5,200), convert:UC.toFloat, modes:FDM}),
|
outputMinSpeed: UC.newInput(LANG.ad_mins_s, {title:LANG.ad_mins_l, bound:UC.bound(5,200), convert:UC.toFloat, modes:FDM}),
|
||||||
outputShortPoly: UC.newInput(LANG.ad_spol_s, {title:LANG.ad_spol_l, bound:UC.bound(0,10000), convert:UC.toFloat, modes:FDM}),
|
outputShortPoly: UC.newInput(LANG.ad_spol_s, {title:LANG.ad_spol_l, bound:UC.bound(0,10000), convert:UC.toFloat, modes:FDM}),
|
||||||
|
|
|
||||||
|
|
@ -449,7 +449,6 @@
|
||||||
first = true,
|
first = true,
|
||||||
close = !options.open,
|
close = !options.open,
|
||||||
last = startPoint,
|
last = startPoint,
|
||||||
wipeDist = options.wipe || 0,
|
|
||||||
coastDist = options.coast || 0,
|
coastDist = options.coast || 0,
|
||||||
tool = options.tool;
|
tool = options.tool;
|
||||||
|
|
||||||
|
|
@ -525,10 +524,12 @@
|
||||||
origin = startPoint.add(offset),
|
origin = startPoint.add(offset),
|
||||||
zhop = process.zHopDistance || 0,
|
zhop = process.zHopDistance || 0,
|
||||||
antiBacklash = process.antiBacklash,
|
antiBacklash = process.antiBacklash,
|
||||||
|
wipeDist = process.outputRetractWipe || 0,
|
||||||
doSupport = opt.support,
|
doSupport = opt.support,
|
||||||
isBelt = device.bedBelt,
|
isBelt = device.bedBelt,
|
||||||
startClone = startPoint.clone(),
|
startClone = startPoint.clone(),
|
||||||
z = slice.z;
|
z = slice.z,
|
||||||
|
lastPoly;
|
||||||
|
|
||||||
// apply first layer extrusion multipliers
|
// apply first layer extrusion multipliers
|
||||||
if (firstLayer) {
|
if (firstLayer) {
|
||||||
|
|
@ -538,12 +539,15 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
function retract() {
|
function retract() {
|
||||||
if (preout.length) {
|
let array = preout.length ? preout : output;
|
||||||
preout.last().retract = true;
|
if (array.length) {
|
||||||
} else if (output.length) {
|
let last = array.last();
|
||||||
output.last().retract = true;
|
last.retract = true;
|
||||||
|
if (wipeDist && lastPoly && last.point) {
|
||||||
|
addOutput(array, last.point.followTo(lastPoly.center(true), wipeDist));
|
||||||
|
}
|
||||||
} else if (opt.pretract) {
|
} else if (opt.pretract) {
|
||||||
opt.pretract();
|
opt.pretract(wipeDist);
|
||||||
} else {
|
} else {
|
||||||
console.log('unable to retract. no preout or output');
|
console.log('unable to retract. no preout or output');
|
||||||
}
|
}
|
||||||
|
|
@ -583,6 +587,7 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
lastPoly = output.lastPoly = poly;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -207,7 +207,6 @@
|
||||||
// console.log({double_retract: zhop});
|
// console.log({double_retract: zhop});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// console.log({retract:zhop});
|
|
||||||
retracted = retDist;
|
retracted = retDist;
|
||||||
moveTo({e:-retracted}, retSpeed, `e-retract ${retDist}`);
|
moveTo({e:-retracted}, retSpeed, `e-retract ${retDist}`);
|
||||||
if (zhop) moveTo({z:zpos + zhop}, seekMMM, "z-hop start");
|
if (zhop) moveTo({z:zpos + zhop}, seekMMM, "z-hop start");
|
||||||
|
|
|
||||||
|
|
@ -403,9 +403,13 @@
|
||||||
first: slice.index === 0,
|
first: slice.index === 0,
|
||||||
support: slice.widget.support,
|
support: slice.widget.support,
|
||||||
onBelt: slice.onbelt,
|
onBelt: slice.onbelt,
|
||||||
pretract: () => {
|
pretract: (wipeDist) => {
|
||||||
if (lastLayer && lastLayer.length) {
|
if (lastLayer && lastLayer.length) {
|
||||||
lastLayer.last().retract = true;
|
let lastOut = lastLayer.last();
|
||||||
|
lastOut.retract = true;
|
||||||
|
if (wipeDist && lastLayer.lastPoly && lastOut.point) {
|
||||||
|
print.addOutput(lastLayer, lastOut.point.followTo(lastLayer.lastPoly.center(true), wipeDist));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -480,6 +480,8 @@ kiri.lang['en-us'] = {
|
||||||
ad_rrat_s: "retract rate",
|
ad_rrat_s: "retract rate",
|
||||||
ad_rrat_l: "speed of filament\nretraction in mm/s",
|
ad_rrat_l: "speed of filament\nretraction in mm/s",
|
||||||
ad_rdwl_s: "engage dwell",
|
ad_rdwl_s: "engage dwell",
|
||||||
|
ad_wpln_s: "retract wipe",
|
||||||
|
ad_wpln_l: "non-printing move\nafter retraction\nin millimeters",
|
||||||
ad_rdwl_l: "time between re-engaging\nfilament and movement\nin milliseconds",
|
ad_rdwl_l: "time between re-engaging\nfilament and movement\nin milliseconds",
|
||||||
ad_scst_s: "shell coast",
|
ad_scst_s: "shell coast",
|
||||||
ad_scst_l: "non-printing end\nof perimeter shells\nin millimeters",
|
ad_scst_l: "non-printing end\nof perimeter shells\nin millimeters",
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue