03-16-2022
01:31 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
03-16-2022
01:31 PM
Hello @ubi.james13,
I don't know if the tool and spindle blocks have to be reinstated or not. I am attaching your program with just the G369 added, can you let me know if this runs on your machine? If so, you can add a single line to the post to get this output.
} else {
if (getProperty("useG400") && ((bFormat.getResultingValue(abc.y) == 0) || (Math.abs(bFormat.getResultingValue(abc.y)) == 90))) {
setSpindleOrientationMilling(abc);
} else {
cancelWorkPlane(); // <<< ADD THIS LINE
var compensationOffset = tool.isTurningTool() ? tool.compensationOffset : tool.lengthOffset;
var toolAxisMode = (machineState.usePolarMode || machineState.useXZCMode || machineState.axialCenterDrilling) ? 0 : 1; // D0 = tool axis is Z-axis, D1 = tool axis is X-axis
gWCSModal.reset();
writeBlock(
gWCSModal.format(368),
"X" + spatialFormat.format(0),
"Z" + spatialFormat.format(0),
"D" + spatialFormat.format(toolAxisMode),
bFormat.format((getSpindle(PART) == SPINDLE_MAIN) ? abc.y : -abc.y), // only B-axis is supported for G368
"W" + compensationOffset
);
}
Please let me know if it works and we will update the library post.

Bob Schultz
Sr. Post Processor Developer
Fusion