From be16f7489a38f9bab8d351e506e900c5c8f7ae6a Mon Sep 17 00:00:00 2001 From: Stewart Allen Date: Sun, 8 Mar 2020 11:24:28 -0400 Subject: [PATCH] fix units in export --- js/kiri-driver-cam.js | 6 +++--- js/kiri.js | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/js/kiri-driver-cam.js b/js/kiri-driver-cam.js index e2d90d43..32f5f38c 100644 --- a/js/kiri-driver-cam.js +++ b/js/kiri-driver-cam.js @@ -895,10 +895,10 @@ var gs_kiri_cam = exports; slice.index = index; switch (slice.camMode) { case CPRO.FACING: - createFacingSlices(slice, facePolys, roughToolDiam, proc.roughingOver * units, pocketOnlyRough); + createFacingSlices(slice, facePolys, roughToolDiam, proc.roughingOver, pocketOnlyRough); break; case CPRO.ROUGH: - createRoughingSlices(slice, shellRough, roughToolDiam, proc.roughingStock * units, proc.roughingOver * units, pocketOnlyRough); + createRoughingSlices(slice, shellRough, roughToolDiam, proc.roughingStock * units, proc.roughingOver, pocketOnlyRough); if (addTabsRough) addCutoutTabs(slice, roughToolDiam); break; case CPRO.FINISH: @@ -1410,7 +1410,7 @@ var gs_kiri_cam = exports; cmdSpindle = gcodes.gcodeSpindle || [ "M3 S{speed}" ], cmdDwell = gcodes.gcodeDwell || [ "G4 P{time}" ], bounds = widget.getCamBounds(settings), - units = settings.controller.units === 'in' ? 25.4 : 1, + units = 1,//settings.controller.units === 'in' ? 25.4 : 1, spro = settings.process, dev = settings.device, decimals = 4, diff --git a/js/kiri.js b/js/kiri.js index 76b5b63b..12b50c40 100644 --- a/js/kiri.js +++ b/js/kiri.js @@ -2880,8 +2880,8 @@ self.kiri.license = exports.LICENSE; camTabs: UC.newGroup("cutout tabs", null, {modes:CAM}), camTabsAngle: UC.newInput("angle", {title:"starting angle for tab spacing\nin degrees", convert:UC.toInt, bound:UC.bound(0,360), modes:CAM}), camTabsCount: UC.newInput("count", {title:"number of tabs to use\nwill be spaced evenly\naround the part", convert:UC.toInt, bound:UC.bound(1,20), modes:CAM}), - camTabsWidth: UC.newInput("width", {title:"width in workspace units\nperpendicular to part", convert:UC.toFloat, bound:UC.bound(1,100), modes:CAM}), - camTabsHeight: UC.newInput("height", {title:"height in workspace units\nfrom part bottom", convert:UC.toFloat, bound:UC.bound(1,100), modes:CAM}), + camTabsWidth: UC.newInput("width", {title:"width in workspace units\nperpendicular to part", convert:UC.toFloat, bound:UC.bound(0.1,100), modes:CAM}), + camTabsHeight: UC.newInput("height", {title:"height in workspace units\nfrom part bottom", convert:UC.toFloat, bound:UC.bound(0.1,100), modes:CAM}), camTabsOn: UC.newBoolean("enable", onBooleanClick, {title:"enable or disable tabs\ntab generation skipped when\npocket only mode enabled", modes:CAM}), output: UC.newGroup("raft", null, {modes:FDM}), @@ -2908,7 +2908,7 @@ self.kiri.license = exports.LICENSE; camTolerance: UC.newInput("tolerance", {title:"surface precision\nin workspace units", convert:UC.toFloat, bound:UC.bound(0.05,1.0), modes:CAM}), camZTopOffset: UC.newInput("z top offset", {title:"offset from stock surface\nto top face of part\nin workspace units", convert:UC.toFloat, modes:CAM}), camZBottom: UC.newInput("z bottom", {title:"offset from part bottom\nto limit cutting depth\nin workspace units", convert:UC.toFloat, modes:CAM}), - camZClearance: UC.newInput("z clearance", {title:"travel offset from z top\nin workspace units", convert:UC.toFloat, bound:UC.bound(1,100), modes:CAM}), + camZClearance: UC.newInput("z clearance", {title:"travel offset from z top\nin workspace units", convert:UC.toFloat, bound:UC.bound(0.01,100), modes:CAM}), // camPocketOnly: UC.newBoolean("pocket only", onBooleanClick, {title:"constrain to\npart boundaries", modes:CAM}), camDepthFirst: UC.newBoolean("depth first", onBooleanClick, {title:"optimize pocket cuts\nwith depth priority", modes:CAM}), outputClockwise: UC.newBoolean("clockwise", onBooleanClick, {title:"waterline milling direction", modes:CAM}),