Skip to content

Commit

Permalink
Closed Issue #31
Browse files Browse the repository at this point in the history
  • Loading branch information
will1742 committed Sep 23, 2021
1 parent c4d1b71 commit 63efe81
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 8 deletions.
15 changes: 11 additions & 4 deletions Haas_Gantry_BIDC/Bechtel SR.cps
Original file line number Diff line number Diff line change
Expand Up @@ -868,10 +868,10 @@ function onOpen() {
var tool = tools.getTool(i);
// Added 8/31/21 | Kevin Pan | pan261
if (tool.number == 1) {
// throw "Tool number 1 is reserved for probing."
throw "Tool number 1 is reserved for probing."
}
if (tool.number == 2) {
// throw "Tool number 2 is not available for use."
throw "Tool number 2 is not available for use."
}
// pan261

Expand Down Expand Up @@ -1851,13 +1851,20 @@ function onSection() {
}
}

if (!isFirstSection()) {
if (!isFirstSection() && getProperty("toolHeightValidation")) {
writeBlock(mFormat.format(0));
writeComment("CHECK TOOL AND PART");
if (!retracted) {
writeRetract(Z);
}
writeRetract(X, Y);
} else if(!isFirstSection()) {
writeBlock(mFormat.format(1));
writeComment("CHECK TOOL AND PART");
if (!retracted) {
writeRetract(Z);
}
writeRetract(X, Y);
}

if (hasParameter("operation-comment")) {
Expand All @@ -1874,7 +1881,7 @@ function onSection() {
}

if (hasParameter("notes") && getParameter("notes").toUpperCase().indexOf("APPROVED") <= -1) {
// throw "Operation \"" + getParameter("operation-comment") + "\" not approved. See a Peer Mentor."
throw "Operation \"" + getParameter("operation-comment") + "\" not approved. See a Peer Mentor."
}

if (staticProperties.showNotes) {
Expand Down
7 changes: 5 additions & 2 deletions Haas_Mills_BIDC/Bechtel DT.cps
Original file line number Diff line number Diff line change
Expand Up @@ -2411,12 +2411,15 @@ function onSection() {
}
}

if (!isFirstSection()) {
if (!isFirstSection() && getProperty("toolLengthValidation")) {
displayMedia("checkPartTool.jpg", false);
writeBlock(mFormat.format(0));
writeBlock(mFormat.format(131));
} else if (!isFirstSection()) {
writeBlock(mFormat.format(1));
writeComment("Check Part and Tool");
}

if (hasParameter("operation-comment")) {
var comment = getParameter("operation-comment");
if (comment && ((comment !== lastOperationComment) || !patternIsActive || insertToolCall)) {
Expand Down
5 changes: 4 additions & 1 deletion Haas_Mills_BIDC/Bechtel VF2.cps
Original file line number Diff line number Diff line change
Expand Up @@ -2411,10 +2411,13 @@ function onSection() {
}
}

if (!isFirstSection()) {
if (!isFirstSection() && getProperty("toolLengthValidation")) {
displayMedia("checkPartTool.jpg", false);
writeBlock(mFormat.format(0));
writeBlock(mFormat.format(131));
} else if (!isFirstSection()) {
writeBlock(mFormat.format(1));
writeComment("Check Part and Tool");
}

if (hasParameter("operation-comment")) {
Expand Down
5 changes: 4 additions & 1 deletion Haas_Mills_BIDC/Bechtel VF4.cps
Original file line number Diff line number Diff line change
Expand Up @@ -2415,10 +2415,13 @@ function onSection() {
}
}

if (!isFirstSection()) {
if (!isFirstSection() && getProperty("toolLengthValidation")) {
displayMedia("checkPartTool.jpg", false);
writeBlock(mFormat.format(0));
writeBlock(mFormat.format(131));
} else if (!isFirstSection()) {
writeBlock(mFormat.format(1));
writeComment("Check Part and Tool");
}

if (hasParameter("operation-comment")) {
Expand Down

0 comments on commit 63efe81

Please sign in to comment.