fix logic error that blocked gcode prefix
This commit is contained in:
parent
a8e827c6da
commit
9e0c263ee8
1 changed files with 1 additions and 2 deletions
|
|
@ -337,13 +337,12 @@ var gs_kiri_fdm = exports;
|
|||
append("; --- startup ---");
|
||||
for (var i=0; i<device.gcodePre.length; i++) {
|
||||
var line = device.gcodePre[i];
|
||||
if (line.indexOf('E') > 0) {
|
||||
if (device.extrudeAbs && line.indexOf('E') > 0) {
|
||||
line.split(' ').forEach(function (tok) {
|
||||
// use max E position from gcode-preamble
|
||||
if (tok[0] == 'E') outputLength = Math.max(outputLength, parseFloat(tok.substring(1)));
|
||||
});
|
||||
}
|
||||
if (device.extrudeAbs)
|
||||
append(constReplace(line, consts));
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue