Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.
bob.schultz
in reply to: ubi.james13

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