diff --git a/src/kiri/conf.js b/src/kiri/conf.js index b80c8273..7879a7fc 100644 --- a/src/kiri/conf.js +++ b/src/kiri/conf.js @@ -19,11 +19,23 @@ // remove fields from o(bject) that don't exist in d(efault) function fill_cull_once(obj, def) { if (!obj) return; - // add missing + // handle renaming + for (let k in obj) { + if (obj.hasOwnProperty(k)) { + let nam = renamed[k] || k; + if (nam !== k) { + // handle field renames + obj[nam] = obj[k]; + delete obj[k]; + } + } + } + // fill missing for (let k in def) { if (def.hasOwnProperty(k)) { let okv = obj[k]; if ((okv === undefined || okv === null)) { + // handle fill // console.log({fill: k}); obj[k] = def[k]; } @@ -49,6 +61,9 @@ } function valueOf(val, dv) { + if (typeof(val) === 'string' && Array.isArray(dv)) { + val = [val]; + } return typeof(val) !== 'undefined' ? val : dv; } @@ -94,11 +109,14 @@ originCenter: valueOf(set.origin_center, false), extrudeAbs: valueOf(set.extrude_abs, false), spindleMax: valueOf(set.spindle_max, 0), - gcodeFan: valueOf(cmd.fan_power, ''), - gcodeTrack: valueOf(cmd.progress, ''), + gcodeFan: valueOf(cmd.fan_power, []), + gcodeTrack: valueOf(cmd.progress, []), gcodeLayer: valueOf(cmd.layer, []), gcodePre: valueOf(code.pre, []), gcodePost: valueOf(code.post, []), + // post processor script of which only one exists + // for XYZ.daVinci.Mini.w triggered in kiri.export + // in the fdm driver to turn gcode into base64 gcodeProc: valueOf(code.proc, ''), gcodePause: valueOf(code.pause, []), gcodeDwell: valueOf(code.dwell, []), @@ -174,6 +192,38 @@ return settings; } + // auto field renaming on import + const renamed = { + roughingTool: "camRoughTool", + roughingSpindle: "camRoughSpindle", + roughingDown: "camRoughDown", + roughingOver: "camRoughOver", + roughingSpeed: "camRoughSpeed", + roughingPlunge: "camRoughPlunge", + roughingStock: "camRoughStock", + roughingPocket: "camRoughVoid", + roughingOn: "camRoughOn", + finishingTool: "camOutlineTool", + finishingSpindle: "camOutlineSpindle", + finishingDown: "camOutlineDown", + finishingOver: "camOutlineOver", + finishingSpeed: "camOutlineSpeed", + finishingPlunge: "camOutlinePlunge", + finishingOn: "camOutlineOn", + finishingXOn: "camContourXOn", + finishingYOn: "camContourYOn", + drillTool: "camDrillTool", + drillSpindle: "camDrillSpindle", + drillDownSpeed: "camDrillDownSpeed", + drillDown: "camDrillDown", + drillDwell: "camDrillDwell", + drillLift: "camDrillLift", + drillingOn: "camDrillingOn", + camPocketOnlyRough: "camRoughPocket", + camPocketOnlyFinish: "camOutlinePocket", + outputClockwise: "camConventional" + }; + let CONF = KIRI.conf = { // --------------- helper functions normalize: normalize, @@ -208,8 +258,8 @@ gcodePost: [], gcodePause: [], gcodeProc: "", - gcodeFan: "", - gcodeTrack: "", + gcodeFan: [], + gcodeTrack: [], gcodeLayer: [], gcodeFExt: "", extruders:[{ @@ -348,40 +398,45 @@ processName: "default", camFastFeed: 6000, camFastFeedZ: 300, - roughingTool: 1000, - roughingSpindle: 1000, - roughingDown: 2, - roughingOver: 0.5, - roughingSpeed: 1000, - roughingPlunge: 250, - roughingStock: 0, - roughingPocket: true, - roughingOn: true, - finishingTool: 1000, - finishingSpindle: 1000, - finishingDown: 3, - finishingOver: 0.5, - finishingAngle: 85, - finishingSpeed: 800, - finishingPlunge: 250, - finishingOn: true, - finishingXOn: true, - finishingYOn: true, - finishCurvesOnly: false, - drillTool: 1000, - drillSpindle: 1000, - drillDownSpeed: 250, - drillDown: 5, - drillDwell: 250, - drillLift: 2, - drillingOn: false, + camRoughTool: 1000, // roughingTool + camRoughSpindle: 1000, // camRoughSpindle + camRoughDown: 2, // roughingDown + camRoughOver: 0.5, // roughingOver + camRoughSpeed: 1000, // roughingSpeed + camRoughPlunge: 250, // roughingPlunge + camRoughStock: 0, // roughingStock + camRoughVoid: true, // roughingPocket + camRoughOn: true, // roughingOn + camOutlineTool: 1000, // finishingTool + camOutlineSpindle: 1000,// finishingSpindle + camOutlineDown: 3, // finishingDown + camOutlineOver: 0.5, // finishingOver + camOutlineSpeed: 800, // finishingSpeed + camOutlinePlunge: 250, // finishingPlunge + camOutlineOn: true, // finishingOn + camContourTool: 1000, + camContourSpindle: 1000,// (new) + camContourSpeed: 1000, // (new) + camContourAngle: 85, // finishingAngle + camContourCurves: false,// finishCurvesOnly + camContourXOn: true, // finishingXOn + camContourYOn: true, // finishingYOn + camTraceTool: 1000, + camTraceEnable: false, + camDrillTool: 1000, // drillTool + camDrillSpindle: 1000, // drillSpindle + camDrillDownSpeed: 250, // drillDownSpeed + camDrillDown: 5, // drillDown + camDrillDwell: 250, // drillDwell + camDrillLift: 2, // drillLift + camDrillingOn: false, // drillingOn camTabsAngle: 0, camTabsCount: 4, camTabsWidth: 5, camTabsHeight: 5, camTabsOn: false, - camPocketOnlyRough: false, - camPocketOnlyFinish: false, + camRoughPocket: false, // camPocketOnlyRough + camOutlinePocket: false, // camPocketOnlyFinish camDepthFirst: true, camEaseDown: false, camOriginTop: true, @@ -393,7 +448,7 @@ camStockY: 0, camStockZ: 0, camStockOffset: true, - outputClockwise: false, + camConventional: false, // outputClockwise outputOriginCenter: false, outputInvertX: false, outputInvertY: false diff --git a/src/kiri/init.js b/src/kiri/init.js index 09e83a2c..f773bf9f 100644 --- a/src/kiri/init.js +++ b/src/kiri/init.js @@ -1272,29 +1272,31 @@ ], {modes:FDM, expert:true, class:"ext-buttons"}), gcode: UC.newGroup(LANG.dv_gr_gco, $('device'), {group:"dgco", inline:true, modes:GCODE}), - gcodeFan: UC.newInput(LANG.dv_fanp_s, {title:LANG.dv_fanp_l, modes:FDM, size:"40%", text:true}), - gcodeTrack: UC.newInput(LANG.dv_prog_s, {title:LANG.dv_prog_l, modes:FDM, size:"40%", text:true}), + gcodeFanTrack: UC.newRow([ + (UI.gcodeFan = UC.newGCode(LANG.dv_fanp_s, {title:LANG.dv_fanp_l, modes:FDM, area:gcode})).button, + (UI.gcodeTrack = UC.newGCode(LANG.dv_prog_s, {title:LANG.dv_prog_l, modes:FDM, area:gcode})).button + ], {modes:FDM, class:"ext-buttons row"}), gcodeLayerPause: UC.newRow([ - (UI.gcodeLayer = UC.newGCode(LANG.dv_layr_s, {title:LANG.dv_layr_l, modes:FDM, size:14, height: 2, area:gcode})).button, - (UI.gcodePause = UC.newGCode(LANG.dv_paus_s, {title:LANG.dv_paus_l, modes:FDM, size:14, height:3, area:gcode})).button, + (UI.gcodeLayer = UC.newGCode(LANG.dv_layr_s, {title:LANG.dv_layr_l, modes:FDM, area:gcode})).button, + (UI.gcodePause = UC.newGCode(LANG.dv_paus_s, {title:LANG.dv_paus_l, modes:FDM, area:gcode})).button ], {modes:FDM, class:"ext-buttons row"}), gcodeSpace: UC.newBoolean(LANG.dv_tksp_s, onBooleanClick, {title:LANG.dv_tksp_l, modes:CAM_LASER}), gcodeStrip: UC.newBoolean(LANG.dv_strc_s, onBooleanClick, {title:LANG.dv_strc_l, modes:CAM}), gcodeFExt: UC.newInput(LANG.dv_fext_s, {title:LANG.dv_fext_l, modes:CAM_LASER, size:7, text:true}), gcodeLaserOnOff: UC.newRow([ - (UI.gcodeLaserOn = UC.newGCode(LANG.dv_lzon_s, {title:LANG.dv_lzon_l, modes:LASER, size:14, height:3, area:gcode})).button, - (UI.gcodeLaserOff = UC.newGCode(LANG.dv_lzof_s, {title:LANG.dv_lzof_l, modes:LASER, size:14, height:3, area:gcode})).button, + (UI.gcodeLaserOn = UC.newGCode(LANG.dv_lzon_s, {title:LANG.dv_lzon_l, modes:LASER, area:gcode})).button, + (UI.gcodeLaserOff = UC.newGCode(LANG.dv_lzof_s, {title:LANG.dv_lzof_l, modes:LASER, area:gcode})).button, ], {modes:LASER, class:"ext-buttons row"}), gcodeCam1: UC.newRow([ - (UI.gcodeChange = UC.newGCode(LANG.dv_tool_s, {title:LANG.dv_tool_l, modes:CAM, size:14, height:2, area:gcode})).button + (UI.gcodeChange = UC.newGCode(LANG.dv_tool_s, {title:LANG.dv_tool_l, modes:CAM, area:gcode})).button ], {modes:CAM, class:"ext-buttons row"}), gcodeCam2: UC.newRow([ - (UI.gcodeDwell = UC.newGCode(LANG.dv_dwll_s, {title:LANG.dv_dwll_l, modes:CAM, size:14, height:2, area:gcode})).button, - (UI.gcodeSpindle = UC.newGCode(LANG.dv_sspd_s, {title:LANG.dv_sspd_l, modes:CAM, size:14, height:2, area:gcode})).button + (UI.gcodeDwell = UC.newGCode(LANG.dv_dwll_s, {title:LANG.dv_dwll_l, modes:CAM, area:gcode})).button, + (UI.gcodeSpindle = UC.newGCode(LANG.dv_sspd_s, {title:LANG.dv_sspd_l, modes:CAM, area:gcode})).button ], {modes:CAM, class:"ext-buttons row"}), gcodeHeadFoot: UC.newRow([ - (UI.gcodePre = UC.newGCode(LANG.dv_head_s, {title:LANG.dv_head_l, modes:GCODE, size:14, height:3, area:gcode})).button, - (UI.gcodePost = UC.newGCode(LANG.dv_foot_s, {title:LANG.dv_foot_l, modes:GCODE, size:14, height:3, area:gcode})).button + (UI.gcodePre = UC.newGCode(LANG.dv_head_s, {title:LANG.dv_head_l, modes:GCODE, area:gcode})).button, + (UI.gcodePost = UC.newGCode(LANG.dv_foot_s, {title:LANG.dv_foot_l, modes:GCODE, area:gcode})).button ], {modes:GCODE, class:"ext-buttons row"}), layout: UC.newGroup(LANG.op_menu, $('prefs-gen'), {inline: true}), @@ -1352,48 +1354,54 @@ sliceSupportNozzle: UC.newSelect(LANG.sp_nozl_s, {title:LANG.sp_nozl_l, modes:FDM, expert:true}, "extruders"), sliceSupportEnable: UC.newBoolean(LANG.enable, onBooleanClick, {modes:FDM}), - fdmRaft: UC.newGroup(LANG.fr_menu, null, {modes:FDM, marker:true}), - outputRaftSpacing: UC.newInput(LANG.fr_spac_s, {title:LANG.fr_spac_l, convert:UC.toFloat, bound:UC.bound(0.0,3.0), modes:FDM}), - outputRaft: UC.newBoolean(LANG.enable, onBooleanClick, {title:LANG.fr_nabl_l, modes:FDM}), - - roughing: UC.newGroup(LANG.cr_menu, null, {modes:CAM, marker:true}), - roughingTool: UC.newSelect(LANG.cc_tool, {modes:CAM}), - roughingSpindle: UC.newInput(LANG.cc_spnd_s, {title:LANG.cc_spnd_l, convert:UC.toInt, modes:CAM}), - roughingOver: UC.newInput(LANG.cc_sovr_s, {title:LANG.cc_sovr_l, convert:UC.toFloat, bound:UC.bound(0.1,1.0), modes:CAM}), - roughingDown: UC.newInput(LANG.cc_sdwn_s, {title:LANG.cc_sdwn_l, convert:UC.toFloat, modes:CAM}), - roughingSpeed: UC.newInput(LANG.cc_feed_s, {title:LANG.cc_feed_l, convert:UC.toInt, modes:CAM}), - roughingPlunge: UC.newInput(LANG.cc_plng_s, {title:LANG.cc_plng_l, convert:UC.toInt, modes:CAM}), - roughingStock: UC.newInput(LANG.cr_lsto_s, {title:LANG.cr_lsto_l, convert:UC.toFloat, modes:CAM}), - roughingPocket: UC.newBoolean(LANG.cr_clrp_s, onBooleanClick, {title:LANG.cr_clrp_l, modes:CAM}), - camPocketOnlyRough: UC.newBoolean(LANG.cc_pock_s, onBooleanClick, {title:LANG.cc_pock_l, modes:CAM}), - roughingSep: UC.newBlank({class:"pop-sep"}), - roughingOn: UC.newBoolean(LANG.enable, onBooleanClick, {modes:CAM}), - - finishing: UC.newGroup(LANG.cf_menu, null, {modes:CAM, marker:true}), - finishingTool: UC.newSelect(LANG.cc_tool, {modes:CAM}), - finishingSpindle: UC.newInput(LANG.cc_spnd_s, {title:LANG.cc_spnd_l, convert:UC.toInt, modes:CAM}), - finishingOver: UC.newInput(LANG.cc_sovr_s, {title:LANG.cc_sovr_l, convert:UC.toFloat, bound:UC.bound(0.05,1.0), modes:CAM}), - finishingDown: UC.newInput(LANG.cc_sdwn_s, {title:LANG.cc_sdwn_l, convert:UC.toFloat, modes:CAM}), - finishingAngle: UC.newInput(LANG.cf_angl_s, {title:LANG.cf_angl_l, convert:UC.toFloat, bound:UC.bound(45,90), modes:CAM}), - finishingSpeed: UC.newInput(LANG.cc_feed_s, {title:LANG.cc_feed_l, convert:UC.toInt, modes:CAM}), - finishingPlunge: UC.newInput(LANG.cc_plng_s, {title:LANG.cc_plng_l, convert:UC.toInt, modes:CAM}), - camPocketOnlyFinish: UC.newBoolean(LANG.cc_pock_s, onBooleanClick, {title:LANG.cc_pock_l, modes:CAM}), - finishCurvesOnly: UC.newBoolean(LANG.cf_curv_s, onBooleanClick, {title:LANG.cf_curv_l, modes:CAM}), - finishingSep: UC.newBlank({class:"pop-sep"}), - finishingOn: UC.newBoolean(LANG.cf_watr_s, onBooleanClick, {title:LANG.cf_watr_l, modes:CAM}), - finishingXOn: UC.newBoolean(LANG.cf_linx_s, onBooleanClick, {title:LANG.cf_linx_l, modes:CAM}), - finishingYOn: UC.newBoolean(LANG.cf_liny_s, onBooleanClick, {title:LANG.cf_liny_l, modes:CAM}), - - drilling: UC.newGroup(LANG.cd_menu, null, {modes:CAM, marker:true}), - drillTool: UC.newSelect(LANG.cc_tool, {modes:CAM}), - drillSpindle: UC.newInput(LANG.cc_spnd_s, {title:LANG.cc_spnd_l, convert:UC.toInt, modes:CAM}), - drillDown: UC.newInput(LANG.cd_plpr_s, {title:LANG.cd_plpr_l, convert:UC.toFloat, modes:CAM}), - drillDownSpeed: UC.newInput(LANG.cc_plng_s, {title:LANG.cc_plng_l, convert:UC.toFloat, modes:CAM}), - drillDwell: UC.newInput(LANG.cd_dwll_s, {title:LANG.cd_dwll_l, convert:UC.toFloat, modes:CAM}), - drillLift: UC.newInput(LANG.cd_lift_s, {title:LANG.cd_lift_l, convert:UC.toFloat, modes:CAM}), - drillingSep: UC.newBlank({class:"pop-sep"}), - drillingOn: UC.newBoolean(LANG.enable, onBooleanClick, {modes:CAM}), + fdmRaft: UC.newGroup(LANG.fr_menu, null, {modes:FDM, marker:true}), + outputRaftSpacing: UC.newInput(LANG.fr_spac_s, {title:LANG.fr_spac_l, convert:UC.toFloat, bound:UC.bound(0.0,3.0), modes:FDM}), + outputRaft: UC.newBoolean(LANG.enable, onBooleanClick, {title:LANG.fr_nabl_l, modes:FDM}), + camRough: UC.newGroup(LANG.cr_menu, null, {modes:CAM, marker:true}), + camRoughTool: UC.newSelect(LANG.cc_tool, {modes:CAM}), + camRoughSpindle: UC.newInput(LANG.cc_spnd_s, {title:LANG.cc_spnd_l, convert:UC.toInt, modes:CAM}), + camRoughOver: UC.newInput(LANG.cc_sovr_s, {title:LANG.cc_sovr_l, convert:UC.toFloat, bound:UC.bound(0.1,1.0), modes:CAM}), + camRoughDown: UC.newInput(LANG.cc_sdwn_s, {title:LANG.cc_sdwn_l, convert:UC.toFloat, modes:CAM}), + camRoughSpeed: UC.newInput(LANG.cc_feed_s, {title:LANG.cc_feed_l, convert:UC.toInt, modes:CAM}), + camRoughPlunge: UC.newInput(LANG.cc_plng_s, {title:LANG.cc_plng_l, convert:UC.toInt, modes:CAM}), + camRoughStock: UC.newInput(LANG.cr_lsto_s, {title:LANG.cr_lsto_l, convert:UC.toFloat, modes:CAM}), + camRoughVoid: UC.newBoolean(LANG.cr_clrp_s, onBooleanClick, {title:LANG.cr_clrp_l, modes:CAM}), + camRoughPocket: UC.newBoolean(LANG.cc_pock_s, onBooleanClick, {title:LANG.cc_pock_l, modes:CAM}), + camRoughSep: UC.newBlank({class:"pop-sep"}), + camRoughOn: UC.newBoolean(LANG.enable, onBooleanClick, {modes:CAM}), + camOutline: UC.newGroup(LANG.co_menu, null, {modes:CAM, marker:true}), + camOutlineTool: UC.newSelect(LANG.cc_tool, {modes:CAM}), + camOutlineSpindle: UC.newInput(LANG.cc_spnd_s, {title:LANG.cc_spnd_l, convert:UC.toInt, modes:CAM}), + camOutlineOver: UC.newInput(LANG.cc_sovr_s, {title:LANG.cc_sovr_l, convert:UC.toFloat, bound:UC.bound(0.05,1.0), modes:CAM}), + camOutlineDown: UC.newInput(LANG.cc_sdwn_s, {title:LANG.cc_sdwn_l, convert:UC.toFloat, modes:CAM}), + camOutlineSpeed: UC.newInput(LANG.cc_feed_s, {title:LANG.cc_feed_l, convert:UC.toInt, modes:CAM}), + camOutlinePlunge: UC.newInput(LANG.cc_plng_s, {title:LANG.cc_plng_l, convert:UC.toInt, modes:CAM}), + camOutlinePocket: UC.newBoolean(LANG.cc_pock_s, onBooleanClick, {title:LANG.cc_pock_l, modes:CAM}), + camOutlineSep: UC.newBlank({class:"pop-sep"}), + camOutlineOn: UC.newBoolean(LANG.cf_watr_s, onBooleanClick, {title:LANG.cf_watr_l, modes:CAM}), + camContour: UC.newGroup(LANG.cn_menu, null, {modes:CAM, marker:true}), + camContourTool: UC.newSelect(LANG.cc_tool, {modes:CAM}), + camContourSpindle: UC.newInput(LANG.cc_spnd_s, {title:LANG.cc_spnd_l, convert:UC.toInt, modes:CAM}), + camContourSpeed: UC.newInput(LANG.cc_feed_s, {title:LANG.cc_feed_l, convert:UC.toInt, modes:CAM}), + camContourAngle: UC.newInput(LANG.cf_angl_s, {title:LANG.cf_angl_l, convert:UC.toFloat, bound:UC.bound(45,90), modes:CAM}), + camContourCurves: UC.newBoolean(LANG.cf_curv_s, onBooleanClick, {title:LANG.cf_curv_l, modes:CAM}), + camContourSep: UC.newBlank({class:"pop-sep"}), + camContourXOn: UC.newBoolean(LANG.cf_linx_s, onBooleanClick, {title:LANG.cf_linx_l, modes:CAM}), + camContourYOn: UC.newBoolean(LANG.cf_liny_s, onBooleanClick, {title:LANG.cf_liny_l, modes:CAM}), + // camTracing: UC.newGroup(LANG.cu_menu, null, {modes:CAM, marker:true}), + // camTraceTool: UC.newSelect(LANG.cc_tool, {modes:CAM}), + // camTracingSep: UC.newBlank({class:"pop-sep"}), + // camTraceEnable: UC.newBoolean(LANG.enable, onBooleanClick, {title:'todo', modes:CAM}), + camDrill: UC.newGroup(LANG.cd_menu, null, {modes:CAM, marker:true}), + camDrillTool: UC.newSelect(LANG.cc_tool, {modes:CAM}), + camDrillSpindle: UC.newInput(LANG.cc_spnd_s, {title:LANG.cc_spnd_l, convert:UC.toInt, modes:CAM}), + camDrillDown: UC.newInput(LANG.cd_plpr_s, {title:LANG.cd_plpr_l, convert:UC.toFloat, modes:CAM}), + camDrillDownSpeed: UC.newInput(LANG.cc_plng_s, {title:LANG.cc_plng_l, convert:UC.toFloat, modes:CAM}), + camDrillDwell: UC.newInput(LANG.cd_dwll_s, {title:LANG.cd_dwll_l, convert:UC.toFloat, modes:CAM}), + camDrillLift: UC.newInput(LANG.cd_lift_s, {title:LANG.cd_lift_l, convert:UC.toFloat, modes:CAM}), + camDrillSep: UC.newBlank({class:"pop-sep"}), + camDrillingOn: UC.newBoolean(LANG.enable, onBooleanClick, {modes:CAM}), camTabs: UC.newGroup(LANG.ct_menu, null, {modes:CAM, marker:true}), camTabsAngle: UC.newInput(LANG.ct_angl_s, {title:LANG.ct_angl_l, convert:UC.toInt, bound:UC.bound(0,360), modes:CAM}), camTabsCount: UC.newInput(LANG.ct_numb_s, {title:LANG.ct_numb_l, convert:UC.toInt, bound:UC.bound(1,20), modes:CAM}), @@ -1403,7 +1411,6 @@ camTabsOn: UC.newBoolean(LANG.enable, onBooleanClick, {title:LANG.ct_nabl_l, modes:CAM}), camSep1: UC.newGroup(null, null, {modes:CAM, class:"set-sep"}), - camStock: UC.newGroup(LANG.cs_menu, null, {modes:CAM}), camStockX: UC.newInput(LANG.cs_wdth_s, {title:LANG.cs_wdth_l, convert:UC.toFloat, bound:UC.bound(0,9999), modes:CAM}), camStockY: UC.newInput(LANG.cs_dpth_s, {title:LANG.cs_dpth_l, convert:UC.toFloat, bound:UC.bound(0,9999), modes:CAM}), @@ -1426,7 +1433,7 @@ outputFillMult: UC.newInput(LANG.ou_flml_s, {title:LANG.ou_exml_l, convert:UC.toFloat, bound:UC.bound(0.0,2.0), modes:FDM}), outputSparseMult: UC.newInput(LANG.ou_spml_s, {title:LANG.ou_exml_l, convert:UC.toFloat, bound:UC.bound(0.0,2.0), modes:FDM}), outputFanLayer: UC.newInput(LANG.ou_fanl_s, {title:LANG.ou_fanl_l, convert:UC.toInt, bound:UC.bound(0,100), modes:FDM, expert:true}), - outputClockwise: UC.newBoolean(LANG.ou_conv_s, onBooleanClick, {title:LANG.ou_conv_l, modes:CAM}), + camConventional: UC.newBoolean(LANG.ou_conv_s, onBooleanClick, {title:LANG.ou_conv_l, modes:CAM}), camEaseDown: UC.newBoolean(LANG.cr_ease_s, onBooleanClick, {title:LANG.cr_ease_l, modes:CAM}), camDepthFirst: UC.newBoolean(LANG.ou_depf_s, onBooleanClick, {title:LANG.ou_depf_l, modes:CAM}), outputOriginBounds: UC.newBoolean(LANG.or_bnds_s, onBooleanClick, {title:LANG.or_bnds_l, modes:LASER}), @@ -1744,6 +1751,12 @@ return svg; } + function mklbl(src) { + let lbl = DOC.createElement('label'); + lbl.innerText = src; + return lbl; + } + $('mode-fdm').appendChild(mksvg(icons.fdm)); $('mode-sla').appendChild(mksvg(icons.sla)); $('mode-cam').appendChild(mksvg(icons.cnc)); @@ -1971,8 +1984,8 @@ $('rot_x_gt').onclick = () => { API.selection.rotate( d,0,0) }; $('rot_y_lt').onclick = () => { API.selection.rotate(0,-d,0) }; $('rot_y_gt').onclick = () => { API.selection.rotate(0, d,0) }; - $('rot_z_lt').onclick = () => { API.selection.rotate(0,0,-d) }; - $('rot_z_gt').onclick = () => { API.selection.rotate(0,0, d) }; + $('rot_z_lt').onclick = () => { API.selection.rotate(0,0, d) }; + $('rot_z_gt').onclick = () => { API.selection.rotate(0,0,-d) }; UI.modal.onclick = API.modal.hide; UI.modalBox.onclick = (ev) => { ev.stopPropagation() }; diff --git a/src/kiri/main.js b/src/kiri/main.js index 9c4a1f6f..7a485fb6 100644 --- a/src/kiri/main.js +++ b/src/kiri/main.js @@ -578,6 +578,7 @@ } layer = bound(layer, 0, API.var.layer_max); + if (layer < API.var.layer_lo) API.var.layer_lo = layer; API.var.layer_hi = layer; API.event.emit("slider.label"); diff --git a/src/kiri/ui.js b/src/kiri/ui.js index 69ae99e3..a2270df7 100644 --- a/src/kiri/ui.js +++ b/src/kiri/ui.js @@ -372,7 +372,6 @@ let opt = options || {}, row = lastDiv, btn = DOC.createElement("button"), - pop = DOC.createElement("div"), txt = DOC.createElement("textarea"), area = opt.area; @@ -381,6 +380,7 @@ txt.setAttribute("style", "resize: none"); txt.onblur = inputAction; + btn.setAttribute("class", "basis-50"); btn.appendChild(DOC.createTextNode(label)); btn.onclick = function(ev) { diff --git a/src/mode/cam/driver.js b/src/mode/cam/driver.js index a870de2e..d7ea7d3b 100644 --- a/src/mode/cam/driver.js +++ b/src/mode/cam/driver.js @@ -23,9 +23,9 @@ }, CPRO = CAM.process = { ROUGH: 1, - FINISH: 2, - FINISH_X: 3, - FINISH_Y: 4, + OUTLINE: 2, + CONTOUR_X: 3, + CONTOUR_Y: 4, FACING: 5, DRILL: 6 }, @@ -55,12 +55,11 @@ api.event.on("settings.saved", (settings) => { let proc = settings.process; api.ui.camTabs.marker.style.display = proc.camTabsOn ? 'flex' : 'none'; - api.ui.roughing.marker.style.display = proc.roughingOn ? 'flex' : 'none'; - api.ui.drilling.marker.style.display = proc.drillingOn ? 'flex' : 'none'; - api.ui.finishing.marker.style.display = - proc.finishingOn || - proc.finishingXOn || - proc.finishingYOn ? 'flex' : 'none'; + api.ui.camRough.marker.style.display = proc.camRoughOn ? 'flex' : 'none'; + api.ui.camDrill.marker.style.display = proc.camDrillingOn ? 'flex' : 'none'; + api.ui.camOutline.marker.style.display = proc.camOutlineOn ? 'flex' : 'none'; + api.ui.camContour.marker.style.display = + proc.camContourXOn || proc.camContourYOn ? 'flex' : 'none'; }); } @@ -386,11 +385,11 @@ outp = settings.process, units = settings.controller.units === 'in' ? 25.4 : 1, resolution = outp.camTolerance * units, - diameter = getToolDiameter(settings, proc.finishingTool), - tool = getToolById(settings, proc.finishingTool), - toolStep = diameter * proc.finishingOver, + diameter = getToolDiameter(settings, proc.camOutlineTool), + tool = getToolById(settings, proc.camOutlineTool), + toolStep = diameter * proc.camOutlineOver, traceJoin = diameter / 2, - pocketOnly = proc.camPocketOnlyFinish, + pocketOnly = proc.camOutlinePocket, bounds = widget.getBoundingBox().clone(), minX = bounds.min.x,// - diameter, maxX = bounds.max.x,// + diameter, @@ -412,7 +411,7 @@ diameter: diameter, resolution: resolution }, - toolOffset = createToolProfile(settings, proc.finishingTool, topo), + toolOffset = createToolProfile(settings, proc.camOutlineTool, topo), newslices = [], newlines, newtop, @@ -503,14 +502,14 @@ } // do x linear finishing - if (proc.finishingXOn) { + if (proc.camContourXOn) { startTime = time(); // emit slice per X for (x = minX; x <= maxX; x += toolStep) { gridx = Math.round(((x - minX) / boundsX) * stepsx); ly = gridy = 0; slice = newSlice(gridx, mesh.newGroup ? mesh.newGroup() : null); - slice.camMode = CPRO.FINISH_X; + slice.camMode = CPRO.CONTOUR_X; slice.lines = newlines = []; newtop = slice.addTop(newPolygon().setOpen()).poly; newtrace = newPolygon().setOpen(); @@ -560,14 +559,14 @@ } // do y linear finishing - if (proc.finishingYOn) { + if (proc.camContourYOn) { startTime = time(); // emit slice per Y for (y = minY; y <= maxY; y += toolStep) { gridy = Math.round(((y - minY) / boundsY) * stepsy); lx = gridx = 0; slice = newSlice(gridy, mesh.newGroup ? mesh.newGroup() : null); - slice.camMode = CPRO.FINISH_Y; + slice.camMode = CPRO.CONTOUR_Y; slice.lines = newlines = []; newtop = slice.addTop(newPolygon().setOpen()).poly; newtrace = newPolygon().setOpen(); @@ -845,19 +844,19 @@ sliceAll = widget.slices = [], unitsName = settings.controller.units, units = unitsName === 'in' ? 25.4 : 1, - roughToolDiam = getToolDiameter(conf, proc.roughingTool), - finishToolDiam = getToolDiameter(conf, proc.finishingTool), - drillToolDiam = getToolDiameter(conf, proc.drillTool), - procRough = proc.roughingOn && proc.roughingDown && roughToolDiam, - procFinish = proc.finishingOn && proc.finishingDown && finishToolDiam, - procFinishX = proc.finishingXOn && proc.finishingPlunge && finishToolDiam, - procFinishY = proc.finishingYOn && proc.finishingPlunge && finishToolDiam, + roughToolDiam = getToolDiameter(conf, proc.camRoughTool), + finishToolDiam = getToolDiameter(conf, proc.camOutlineTool), + drillToolDiam = getToolDiameter(conf, proc.camDrillTool), + procRough = proc.camRoughOn && proc.camRoughDown && roughToolDiam, + procFinish = proc.camOutlineOn && proc.camOutlineDown && finishToolDiam, + procFinishX = proc.camContourXOn && proc.camOutlinePlunge && finishToolDiam, + procFinishY = proc.camContourYOn && proc.camOutlinePlunge && finishToolDiam, anyFinish = procFinish || procFinishX || procFinishY, - procFacing = proc.roughingOn && proc.camZTopOffset, - procDrill = proc.drillingOn && proc.drillDown && proc.drillDownSpeed, - sliceDepth = Math.max(0.1, Math.min(proc.roughingDown, proc.finishingDown) / 3) * units, - pocketOnlyRough = proc.camPocketOnlyRough, - pocketOnlyFinish = proc.camPocketOnlyFinish, + procFacing = proc.camRoughOn && proc.camZTopOffset, + procDrill = proc.camDrillingOn && proc.camDrillDown && proc.camDrillDownSpeed, + sliceDepth = Math.max(0.1, Math.min(proc.camRoughDown, proc.camOutlineDown) / 3) * units, + pocketOnlyRough = proc.camRoughPocket, + pocketOnlyFinish = proc.camOutlinePocket, addTabsRough = procRough && proc.camTabsOn && !pocketOnlyRough, addTabsFinish = procFinish && proc.camTabsOn && !pocketOnlyFinish, tabWidth = proc.camTabsWidth * units, @@ -865,7 +864,7 @@ mesh = widget.mesh, bounds = widget.getBoundingBox(), zMin = Math.max(bounds.min.z, proc.camZBottom) * units, - roughingStock = proc.roughingStock * units, + camRoughStock = proc.camRoughStock * units, shellRough, shellFinish, facePolys, @@ -959,14 +958,14 @@ if (procRough && !pocketOnlyRough) { // expand shell by half tool diameter + stock to leave - shellRough = facePolys = POLY.expand(shellRough, (roughToolDiam / 2) + roughingStock, 0); + shellRough = facePolys = POLY.expand(shellRough, (roughToolDiam / 2) + camRoughStock, 0); } else { // expand shell minimally triggering a clean shellRough = facePolys = POLY.expand(shellRough, 0.01, 0); } if (anyFinish && pocketOnlyRough && !pocketOnlyFinish) { - facePolys = POLY.expand(shellRough, (roughToolDiam / 2) + roughingStock, 0); + facePolys = POLY.expand(shellRough, (roughToolDiam / 2) + camRoughStock, 0); } if (anyFinish && pocketOnlyFinish) { @@ -977,7 +976,7 @@ if (procFacing) { let ztop = bounds.max.z, zpos = ztop + (proc.camZTopOffset * units), - zstep = proc.roughingDown * units; + zstep = proc.camRoughDown * units; while (zpos >= ztop) { zpos = zpos - Math.min(zstep, zpos - ztop); @@ -996,16 +995,16 @@ if (procRough) { let selected = []; - selectSlices(slices, proc.roughingDown * units, CPRO.ROUGH, selected); + selectSlices(slices, proc.camRoughDown * units, CPRO.ROUGH, selected); sliceAll.appendAll(selected); - if (!proc.roughingPocket) { - thruHoles = holes(slices, roughToolDiam + roughingStock); + if (!proc.camRoughVoid) { + thruHoles = holes(slices, roughToolDiam + camRoughStock); } } if (procFinish) { let selected = []; - selectSlices(slices, proc.finishingDown * units, CPRO.FINISH, selected); + selectSlices(slices, proc.camOutlineDown * units, CPRO.OUTLINE, selected); sliceAll.appendAll(selected); } @@ -1076,9 +1075,9 @@ let tool; let profile; if (procFinish) { - tool = getToolById(conf, proc.finishingTool); + tool = getToolById(conf, proc.camOutlineTool); if (tool.type !== 'endmill') { - profile = createToolProfile(conf, proc.finishingTool, widget.topo); + profile = createToolProfile(conf, proc.camOutlineTool, widget.topo); } } @@ -1090,14 +1089,14 @@ switch (slice.camMode) { case CPRO.FACING: modekey = "facing"; - createFacingSlices(slice, facePolys, roughToolDiam, proc.roughingOver, pocketOnlyRough); + createFacingSlices(slice, facePolys, roughToolDiam, proc.camRoughOver, pocketOnlyRough); break; case CPRO.ROUGH: modekey = "roughing"; - createRoughingSlices(slice, shellRough, roughToolDiam, roughingStock, proc.roughingOver, pocketOnlyRough, thruHoles); + createRoughingSlices(slice, shellRough, roughToolDiam, camRoughStock, proc.camRoughOver, pocketOnlyRough, thruHoles); if (addTabsRough) addCutoutTabs(slice, roughToolDiam); break; - case CPRO.FINISH: + case CPRO.OUTLINE: modekey = "finishing"; if (profile) findTracingPaths(widget, slice, tool, profile); createFinishingSlices(slice, shellFinish, finishToolDiam, pocketOnlyFinish); @@ -1119,7 +1118,7 @@ let tops = slice.tops, layers = slice.layers, outline = layers.outline, - open = (slice.camMode === CPRO.FINISH_X || slice.camMode === CPRO.FINISH_Y); + open = (slice.camMode === CPRO.CONTOUR_X || slice.camMode === CPRO.CONTOUR_Y); layers.outline.clear(); // slice raw edges layers.trace.clear(); // roughing @@ -1137,13 +1136,13 @@ let layer; slice.tops.forEach(function(top) { switch (slice.camMode) { - case CPRO.FINISH: + case CPRO.OUTLINE: layer = layers.solid; break; - case CPRO.FINISH_X: + case CPRO.CONTOUR_X: layer = layers.bridge; break; - case CPRO.FINISH_Y: + case CPRO.CONTOUR_Y: layer = layers.flat; break; default: // roughing @@ -1217,9 +1216,9 @@ depthFirst = process.camDepthFirst, easeDown = process.camEaseDown, tolerance = process.camTolerance * units, - drillDown = process.drillDown * units, - drillLift = process.drillLift * units, - drillDwell = process.drillDwell, + drillDown = process.camDrillDown * units, + drillLift = process.camDrillLift * units, + drillDwell = process.camDrillDwell, newOutput = widgetIndex === 0 ? [] : print.output, layerOut = [], printPoint, @@ -1463,8 +1462,8 @@ switch (slice.camMode) { case modes.FACING: - setTool(process.roughingTool, process.roughingSpeed, 0); - spindle = Math.min(spindleMax, process.roughingSpindle); + setTool(process.camRoughTool, process.camRoughSpeed, 0); + spindle = Math.min(spindleMax, process.camRoughSpindle); slice.tops.forEach(function(top) { if (!top.traces) return; let polys = []; @@ -1477,7 +1476,7 @@ } }); // set winding specified in output - POLY.setWinding(polys, process.outputClockwise, false); + POLY.setWinding(polys, process.camConventional, false); printPoint = poly2polyEmit(polys, printPoint, function(poly, index, count) { poly.forEachPoint(function(point, pidx, points, offset) { camOut(point.clone(), offset !== 0); @@ -1487,17 +1486,17 @@ }); break; case modes.ROUGH: - case modes.FINISH: - let dir = process.outputClockwise; + case modes.OUTLINE: + let dir = process.camConventional; if (slice.camMode === modes.ROUGH) { - setTool(process.roughingTool, process.roughingSpeed, process.roughingPlunge); - spindle = Math.min(spindleMax, process.roughingSpindle); + setTool(process.camRoughTool, process.camRoughSpeed, process.camRoughPlunge); + spindle = Math.min(spindleMax, process.camRoughSpindle); depthData.roughDiam = toolDiam; } else { - setTool(process.finishingTool, process.finishingSpeed, process.finishingPlunge); - spindle = Math.min(spindleMax, process.finishingSpindle); + setTool(process.camOutlineTool, process.camOutlineSpeed, process.camOutlinePlunge); + spindle = Math.min(spindleMax, process.camOutlineSpindle); depthData.finishDiam = toolDiam; - if (!process.camPocketOnlyFinish) { + if (!process.camOutlinePocket) { dir = !dir; } } @@ -1529,14 +1528,14 @@ } }); break; - case modes.FINISH_X: - case modes.FINISH_Y: + case modes.CONTOUR_X: + case modes.CONTOUR_Y: if (isNewMode || !printPoint) { // force start at lower left corner printPoint = newPoint(bounds.min.x,bounds.min.y,zmax); } - setTool(process.finishingTool, process.finishingSpeed, process.finishingPlunge); - spindle = Math.min(spindleMax, process.finishingSpindle); + setTool(process.camContourTool, process.camContourSpeed, process.camFastFeedZ); + spindle = Math.min(spindleMax, process.camContourSpindle); depthData.finishDiam = toolDiam; // todo find closest next trace/trace-point slice.tops.forEach(function(top) { @@ -1547,7 +1546,7 @@ polys.push({first:poly.first(), last:poly.last(), poly:poly}); }); if (depthFirst) { - (slice.camMode === modes.FINISH_X ? depthData.linearx : depthData.lineary).appendAll(polys); + (slice.camMode === modes.CONTOUR_X ? depthData.linearx : depthData.lineary).appendAll(polys); } else { printPoint = tip2tipEmit(polys, printPoint, function(el, point, count) { poly = el.poly; @@ -1562,7 +1561,7 @@ }); break; case modes.DRILL: - setTool(process.drillTool, process.drillDownSpeed, process.drillDownSpeed); + setTool(process.camDrillTool, process.camDrillDownSpeed, process.camDrillDownSpeed); // drilling is always depth-first slice.tops.forEach(function(top) { if (!top.traces) return; @@ -1577,8 +1576,8 @@ if (depthFirst) { // roughing depth first if (depthData.rough.length > 0) { - setTool(process.roughingTool, process.roughingSpeed, process.roughingPlunge); - spindle = Math.min(spindleMax, process.roughingSpindle); + setTool(process.camRoughTool, process.camRoughSpeed, process.camRoughPlunge); + spindle = Math.min(spindleMax, process.camRoughSpindle); printPoint = poly2polyDepthFirstEmit(depthData.rough, printPoint, function(poly, index, count, fromPoint) { let last = null; if (easeDown && poly.isClosed()) { @@ -1592,12 +1591,12 @@ } newLayer(); return last; - }, depthData.roughDiam * process.roughingOver * 1.01); + }, depthData.roughDiam * process.camRoughOver * 1.01); } // finishing depth first if (depthData.finish.length > 0) { - setTool(process.finishingTool, process.finishingSpeed, process.finishingPlunge); - spindle = Math.min(spindleMax, process.finishingSpindle); + setTool(process.camOutlineTool, process.camOutlineSpeed, process.camOutlinePlunge); + spindle = Math.min(spindleMax, process.camOutlineSpindle); printPoint = poly2polyDepthFirstEmit(depthData.finish, printPoint, function(poly, index, count, fromPoint) { let last = null; if (easeDown && poly.isClosed()) { @@ -1616,8 +1615,8 @@ } // two modes for deferred finishing: x then y or combined if (process.finishCurvesOnly) { - setTool(process.finishingTool, process.finishingSpeed, process.finishingPlunge); - spindle = Math.min(spindleMax, process.finishingSpindle); + setTool(process.camOutlineTool, process.camOutlineSpeed, process.camOutlinePlunge); + spindle = Math.min(spindleMax, process.camOutlineSpindle); // combined deferred linear x and y finishing let linearxy = [].appendAll(depthData.linearx).appendAll(depthData.lineary); printPoint = tip2tipEmit(linearxy, printPoint, function(el, point, count) { @@ -1632,8 +1631,8 @@ return lastPoint; }); } else { - setTool(process.finishingTool, process.finishingSpeed, process.finishingPlunge); - spindle = Math.min(spindleMax, process.finishingSpindle); + setTool(process.camOutlineTool, process.camOutlineSpeed, process.camOutlinePlunge); + spindle = Math.min(spindleMax, process.camOutlineSpindle); // deferred linear x finishing if (depthData.linearx.length > 0) { // force start at lower left corner @@ -1666,7 +1665,7 @@ // drilling is always depth first if (depthData.drill.length > 0) { - setTool(process.drillTool, process.drillDownSpeed, process.drillDownSpeed); + setTool(process.camDrillTool, process.camDrillDownSpeed, process.camDrillDownSpeed); emitDrills(depthData.drill); } @@ -1885,7 +1884,7 @@ } if (!stripComments) { - append(`; Generated by Kiri:Moto ${KIRI.VERSION}`); + append(`; Generated by Kiri:Moto ${KIRI.version}`); append(`; ${new Date().toString()}`); filterEmit(["; Bed left:{left} right:{right} top:{top} bottom:{bottom}"], consts); append(`; Target: ${settings.filter[settings.mode]}`); diff --git a/src/mode/fdm/driver.js b/src/mode/fdm/driver.js index 13441fa3..753857bc 100644 --- a/src/mode/fdm/driver.js +++ b/src/mode/fdm/driver.js @@ -915,7 +915,7 @@ device = settings.device, extruders = device.extruders, process = settings.process, - fan_power = device.gcodeFan, + gcodeFan = device.gcodeFan, gcodeLayer = device.gcodeLayer, gcodeTrack = device.gcodeTrack, tool = 0, @@ -1008,7 +1008,7 @@ arr.forEach(function(line) { appendSub(line) }); } - append(`; Generated by Kiri:Moto ${KIRI.VERSION}`); + append(`; Generated by Kiri:Moto ${KIRI.version}`); append(`; ${new Date().toString()}`); appendSub("; Bed left:{left} right:{right} top:{top} bottom:{bottom}"); append(`; Target: ${settings.filter[settings.mode]}`); @@ -1142,8 +1142,8 @@ } // enable fan at fan layer - if (fan_power && layer === process.outputFanLayer) { - appendSub(fan_power); + if (gcodeFan && layer === process.outputFanLayer) { + appendAllSub(gcodeFan); } // second layer transitions @@ -1242,7 +1242,7 @@ // emit tracked progress if (gcodeTrack && progress != lastProgress) { - appendSub(gcodeTrack); + appendAllSub(gcodeTrack); lastProgress = progress; } diff --git a/web/kiri/index.css b/web/kiri/index.css index 60b7c349..bf746589 100644 --- a/web/kiri/index.css +++ b/web/kiri/index.css @@ -92,7 +92,7 @@ select option[favorite="1"] { th, tr, td, span, div, label, button { user-select: none; } -th, tr, td { +th, tr, td, label { white-space: nowrap; } .noselect { @@ -117,6 +117,9 @@ th, tr, td { .auto { flex-basis: auto; } +.basis-50 { + flex-basis: 50%; +} .grow { flex-grow: 1; } @@ -411,13 +414,16 @@ th, tr, td { .lt-enabled:hover .pop-lcol { display: flex; } -@media only screen -and (min-device-width : 768px) -and (max-device-width : 1024px) -and (orientation : landscape) { +@media only screen and (max-height : 850px) { + .lt-menu, .pop-lcol { + font-size: 16px !important; + } .lt-menu svg { font-size: 30px !important; } + .pop-lcol svg { + font-size: 20px !important; + } } .ext-buttons button { diff --git a/web/kiri/index.html b/web/kiri/index.html index 25c9ab2d..ab4c8111 100644 --- a/web/kiri/index.html +++ b/web/kiri/index.html @@ -160,6 +160,7 @@ +
reset
diff --git a/web/kiri/lang/en.js b/web/kiri/lang/en.js index 2c6dfccb..a2e6e2e4 100644 --- a/web/kiri/lang/en.js +++ b/web/kiri/lang/en.js @@ -1,4 +1,4 @@ -// english. other language maps will defer to english +"spindle rpm"// english. other language maps will defer to english // map for any missing key/value pairs kiri.lang['en'] = kiri.lang['en-us'] = { @@ -39,10 +39,10 @@ kiri.lang['en-us'] = { dv_prog_l: "output on each % progress", dv_layr_s: "layer", dv_layr_l: "output at each\nlayer change", - dv_tksp_s: "token spacing", - dv_tksp_l: "gcode token spacer", + dv_tksp_s: "token spacer", + dv_tksp_l: "add a space between\ngcode axis parameters\nG0X0Y0X0\nvs\nG0 X0 Y0 Z0", dv_strc_s: "strip comments", - dv_strc_l: "strip gcode comments", + dv_strc_l: "strip gcode comments\ncomments begin with ;", dv_fext_s: "file extension", dv_fext_l: "file name extension", dv_dwll_s: "dwell", @@ -229,7 +229,7 @@ kiri.lang['en-us'] = { // CNC COMMON terms cc_tool: "tool", - cc_spnd_s: "spindle speed", + cc_spnd_s: "spindle rpm", cc_spnd_l: "spindle speed in\nrevolutions / minute", cc_sovr_s: "step over", cc_sovr_l: "0.1 - 1.0\npercentage of\ntool diameter", @@ -250,7 +250,7 @@ kiri.lang['en-us'] = { cc_rzpd_l: "max z moves feedrate\nin workspace units / minute", // CNC ROUGHING - cr_menu: "roughing", + cr_menu: "rough", cr_lsto_s: "leave stock", cr_lsto_l: "horizontal offset from vertical faces\nstock to leave for finishing pass\nin workspace units", cr_ease_s: "ease down", @@ -258,21 +258,30 @@ kiri.lang['en-us'] = { cr_clrp_s: "pocket clear", cr_clrp_l: "mill out entire pocket instead\nof just cutting the outline", - // CNC FINISHING - cf_menu: "finishing", + // CNC OUTLINE + co_menu: "outline", + cf_watr_s: "enable", + cf_watr_l: "enable contour finishing\ndisabled when pocketing", + + // CNC CONTOUR + cn_menu: "contour", cf_angl_s: "max angle", cf_angl_l: "angles greater than this\nare considered vertical", - cf_watr_s: "enable waterline", - cf_watr_l: "enable contour finishing\ndisabled when pocketing", - cf_linx_s: "enable linear x", - cf_linx_l: "linear x-axis finishing", - cf_liny_s: "enable linear y", - cf_liny_l: "linear y-axis finishing", cf_curv_s: "curves only", cf_curv_l: "limit linear cleanup\nto curved surfaces", + cf_linx_s: "enable x pass", + cf_linx_l: "linear x-axis finishing", + cf_liny_s: "enable y pass", + cf_liny_l: "linear y-axis finishing", + + // CNC CONTOUR + cu_menu: "trace", + + // CNC FINISHING + // cf_menu: "finishing", // CNC DRILLING - cd_menu: "drilling", + cd_menu: "drill", cd_plpr_s: "plunge per", cd_plpr_l: "max plunge between\ndwell periods\nin workspace units\n0 to disable", cd_dwll_s: "dwell time",