Skip to content

Commit

Permalink
- Threading Radius, + Stock Load
Browse files Browse the repository at this point in the history
  • Loading branch information
will1742 committed Aug 23, 2021
1 parent 93dddc5 commit 47da7f6
Showing 1 changed file with 13 additions and 7 deletions.
20 changes: 13 additions & 7 deletions Haas_Lathes_BIDC/Bechtel ST-20.cps
Original file line number Diff line number Diff line change
Expand Up @@ -1193,27 +1193,29 @@ function writeToolMeasureBlockBIDC(tool) {
return;
}

writeBlock(gFormat.format(10), "L10 P" + tool.number, xOffset.format(measureTool.probeX()));
writeBlock(gFormat.format(10), "L10 P" + tool.number, xOffset.format(measureTool.probeX()));''
writeBlock(gFormat.format(10), "L10 P" + tool.number, zOffset.format(measureTool.probeZ()));
if(tool.noseRadius != 0 || tool.cornerRadius != 0) {
writeBlock(gFormat.format(10), "L10 P" + tool.number, rOffset.format(tool.cornerRadius != 0 ? tool.cornerRadius : tool.noseRadius));
}

if (tool.type == TOOL_TURNING_THREADING) {
writeBlock(gFormat.format(10), "L10 P" + tool.number, rOffset.format(tool.threadPitch*2));
}
// if (tool.type == TOOL_TURNING_THREADING) {
// writeBlock(gFormat.format(10), "L10 P" + tool.number, rOffset.format(tool.threadPitch*2));
// }

writeBlock("T" + toolFormat.format(tool.number * 100 + compensationOffset % 100));
writeComment("PROBE: " + measureTool.offsetType + ", " + probeType.name);
writeBlock(mFormat.format(104));
writeBlock(gFormat.format(212), "H" + probeType.num);
writeBlock(mFormat.format(105));
if (tool.type == TOOL_TURNING_THREADING) {
writeBlock(gFormat.format(10), "L10 P" + tool.number, rOffset.format(0));
}

// if (tool.type == TOOL_TURNING_THREADING) {
// writeBlock(gFormat.format(10), "L10 P" + tool.number, rOffset.format(0));
// }
if (measureTool.offsetType == "Indexible Drill") {
writeBlock(gFormat.format(10), "L10 P" + tool.number, xOffset.format(measureTool.machineX()));
}

writeln("");
}

Expand Down Expand Up @@ -1412,6 +1414,10 @@ function onOpen() {
writeln("N1 (START MAIN PROGRAM)");
}

writeBlock(mFormat.format(0));
writeComment("LOAD STOCK");
writeln("");

// absolute coordinates and feed per min
writeBlock(getCode("FEED_MODE_UNIT_MIN"), gPlaneModal.format(18));

Expand Down

0 comments on commit 47da7f6

Please sign in to comment.