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: Anonymous

Hello @Anonymous,

 

I don't know if you have already modified your post, but adding the rewind/reconfigure logic to a post has become much simpler now.  You can copy the following code from the RS-274 Multi-axis post into your post.

// Start of onRewindMachine logic
var performRewinds = true; // <<< CHANGE TO 'true'

...
// End of onRewindMachine logic

And add the following commands to onOpen prior to calling setMachineConfiguration (also copied from the RS-274 Multi-axis post).

  // retract/reconfigure
  safeRetractDistance = getProperty("safeRetractDistance") != undefined ? getProperty("safeRetractDistance") :
    (typeof safeRetractDistance == "number" ? safeRetractDistance : 0);
  if (machineConfiguration.performRewinds() || (typeof performRewinds == "undefined" ? false : performRewinds)) {
    machineConfiguration.enableMachineRewinds(); // enables the rewind/reconfigure logic
    if (typeof stockExpansion != "undefined") {
      machineConfiguration.setRewindStockExpansion(stockExpansion);
      if (!receivedMachineConfiguration) {
        setMachineConfiguration(machineConfiguration);
      }
    }
  }

 You may have to make minor modifications to the code, but it should be close and give you a starting point that we can work from.



Bob Schultz
Sr. Post Processor Developer