<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: HELP w/FANUC Post in HSM Post Processor Forum</title>
    <link>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/8148583#M13966</link>
    <description>&lt;P&gt;Thank you for your help. It did post without the retracts but it will not post if I select Use Smoothing in my post properties. I get the following message. Could you help with this issue? I would be greatly appreciative.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Information: Configuration: FANUC&lt;BR /&gt;Information: Vendor: Fanuc&lt;BR /&gt;Information: Posting intermediate data to 'C:\Users\Robert Chad Brown\AppData\Local\Fusion 360 CAM\nc\1001.nc'&lt;BR /&gt;Error: Failed to post process. See below for details.&lt;BR /&gt;...&lt;BR /&gt;Code page changed to '1252 (ANSI - Latin I)'&lt;BR /&gt;Start time: Monday, July 23, 2018 1:30:32 PM&lt;BR /&gt;Code page changed to '20127 (US-ASCII)'&lt;BR /&gt;Post processor engine: 4.2.1 41970&lt;BR /&gt;Configuration path: C:\Users\Robert Chad Brown\AppData\Roaming\Autodesk\Fusion 360 CAM\Posts\fanuc .3 .cps&lt;BR /&gt;Include paths: C:\Users\Robert Chad Brown\AppData\Roaming\Autodesk\Fusion 360 CAM\Posts&lt;BR /&gt;Configuration modification date: Monday, July 23, 2018 1:30:17 PM&lt;BR /&gt;Output path: C:\Users\Robert Chad Brown\AppData\Local\Fusion 360 CAM\nc\1001.nc&lt;BR /&gt;Checksum of intermediate NC data: 0f3aade5e3596b0e9e45c2428ce80bd4&lt;BR /&gt;Checksum of configuration: c973401d94d35a96134a80210f6531bf&lt;BR /&gt;Vendor url: &lt;A href="http://www.fanuc.com" target="_blank"&gt;http://www.fanuc.com&lt;/A&gt;&lt;BR /&gt;Legal: Copyright (C) 2012-2018 by Autodesk, Inc.&lt;BR /&gt;Generated by: Fusion 360 CAM 2.0.4285&lt;BR /&gt;...&lt;BR /&gt;Error: Error: Cannot cancel length compensation if the machine is not fully retracted.&lt;BR /&gt;^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^&lt;BR /&gt;Stack dump:&lt;BR /&gt;validate(false,"Cannot cancel length compensation if the machine is not fully retracted.")@:2666&lt;BR /&gt;disableLengthCompensation()@C:\Users\Robert Chad Brown\AppData\Roaming\Autodesk\Fusion 360 CAM\Posts\fanuc .3 .cps:478&lt;BR /&gt;onSection()@C:\Users\Robert Chad Brown\AppData\Roaming\Autodesk\Fusion 360 CAM\Posts\fanuc .3 .cps:1111&lt;/P&gt;&lt;P&gt;Failed while processing onSection() for record 877.&lt;BR /&gt;Error: Failed to invoke function 'onSection'.&lt;BR /&gt;Error: Failed to invoke 'onSection' in the post configuration.&lt;BR /&gt;Error: Failed to execute configuration.&lt;BR /&gt;Stop time: Monday, July 23, 2018 1:30:32 PM&lt;BR /&gt;Post processing failed.&lt;/P&gt;</description>
    <pubDate>Mon, 23 Jul 2018 13:32:36 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2018-07-23T13:32:36Z</dc:date>
    <item>
      <title>HELP w/FANUC Post</title>
      <link>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/8142967#M13964</link>
      <description>&lt;P&gt;I have posted code that is spot drilling two holes in each part. After the first part, spindle returns to G53 Z0 to move over 2". How do I eliminate this form occuring?&lt;/P&gt;</description>
      <pubDate>Fri, 20 Jul 2018 00:39:58 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/8142967#M13964</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-07-20T00:39:58Z</dc:date>
    </item>
    <item>
      <title>Re: HELP w/FANUC Post</title>
      <link>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/8145313#M13965</link>
      <description>&lt;P&gt;The retract move is handled in the onSection function and will retract whenever the post determines that there is a tool change, or a change in the WCS or Work Plane.&amp;nbsp; The following code handles the retract.&lt;/P&gt;
&lt;PRE&gt;if (insertToolCall || newWorkOffset || newWorkPlane || forceSmoothing) {
    
    // stop spindle before retract during tool change
    if (insertToolCall &amp;amp;&amp;amp; !isFirstSection()) {
      onCommand(COMMAND_STOP_SPINDLE);
    }
    
    // retract to safe plane
    writeRetract(Z); // retract
    forceXYZ();&lt;/PRE&gt;
&lt;P&gt;If you don't want the tool to fully retract when the WCS changes, you can make the following changes to the code.&amp;nbsp; In this example it will still retract when there is a tool change or the Work Plane changes (3+2 operations).&lt;/P&gt;
&lt;PRE&gt;if (insertToolCall || newWorkOffset || newWorkPlane || forceSmoothing) {
    
    // stop spindle before retract during tool change
    if (insertToolCall &amp;amp;&amp;amp; !isFirstSection()) {
      onCommand(COMMAND_STOP_SPINDLE);
    }
    
    &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;if (insertToolCall || newWorkPlane) {  // insert this line&lt;/STRONG&gt;&lt;/FONT&gt;
      // retract to safe plane
      writeRetract(Z); // retract
      forceXYZ();
    &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;} // insert this line&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 20 Jul 2018 21:52:28 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/8145313#M13965</guid>
      <dc:creator>bob.schultz</dc:creator>
      <dc:date>2018-07-20T21:52:28Z</dc:date>
    </item>
    <item>
      <title>Re: HELP w/FANUC Post</title>
      <link>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/8148583#M13966</link>
      <description>&lt;P&gt;Thank you for your help. It did post without the retracts but it will not post if I select Use Smoothing in my post properties. I get the following message. Could you help with this issue? I would be greatly appreciative.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Information: Configuration: FANUC&lt;BR /&gt;Information: Vendor: Fanuc&lt;BR /&gt;Information: Posting intermediate data to 'C:\Users\Robert Chad Brown\AppData\Local\Fusion 360 CAM\nc\1001.nc'&lt;BR /&gt;Error: Failed to post process. See below for details.&lt;BR /&gt;...&lt;BR /&gt;Code page changed to '1252 (ANSI - Latin I)'&lt;BR /&gt;Start time: Monday, July 23, 2018 1:30:32 PM&lt;BR /&gt;Code page changed to '20127 (US-ASCII)'&lt;BR /&gt;Post processor engine: 4.2.1 41970&lt;BR /&gt;Configuration path: C:\Users\Robert Chad Brown\AppData\Roaming\Autodesk\Fusion 360 CAM\Posts\fanuc .3 .cps&lt;BR /&gt;Include paths: C:\Users\Robert Chad Brown\AppData\Roaming\Autodesk\Fusion 360 CAM\Posts&lt;BR /&gt;Configuration modification date: Monday, July 23, 2018 1:30:17 PM&lt;BR /&gt;Output path: C:\Users\Robert Chad Brown\AppData\Local\Fusion 360 CAM\nc\1001.nc&lt;BR /&gt;Checksum of intermediate NC data: 0f3aade5e3596b0e9e45c2428ce80bd4&lt;BR /&gt;Checksum of configuration: c973401d94d35a96134a80210f6531bf&lt;BR /&gt;Vendor url: &lt;A href="http://www.fanuc.com" target="_blank"&gt;http://www.fanuc.com&lt;/A&gt;&lt;BR /&gt;Legal: Copyright (C) 2012-2018 by Autodesk, Inc.&lt;BR /&gt;Generated by: Fusion 360 CAM 2.0.4285&lt;BR /&gt;...&lt;BR /&gt;Error: Error: Cannot cancel length compensation if the machine is not fully retracted.&lt;BR /&gt;^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^&lt;BR /&gt;Stack dump:&lt;BR /&gt;validate(false,"Cannot cancel length compensation if the machine is not fully retracted.")@:2666&lt;BR /&gt;disableLengthCompensation()@C:\Users\Robert Chad Brown\AppData\Roaming\Autodesk\Fusion 360 CAM\Posts\fanuc .3 .cps:478&lt;BR /&gt;onSection()@C:\Users\Robert Chad Brown\AppData\Roaming\Autodesk\Fusion 360 CAM\Posts\fanuc .3 .cps:1111&lt;/P&gt;&lt;P&gt;Failed while processing onSection() for record 877.&lt;BR /&gt;Error: Failed to invoke function 'onSection'.&lt;BR /&gt;Error: Failed to invoke 'onSection' in the post configuration.&lt;BR /&gt;Error: Failed to execute configuration.&lt;BR /&gt;Stop time: Monday, July 23, 2018 1:30:32 PM&lt;BR /&gt;Post processing failed.&lt;/P&gt;</description>
      <pubDate>Mon, 23 Jul 2018 13:32:36 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/8148583#M13966</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-07-23T13:32:36Z</dc:date>
    </item>
    <item>
      <title>Re: HELP w/FANUC Post</title>
      <link>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/8149069#M13967</link>
      <description>&lt;P&gt;The setup of the Fanuc post requires that tool length compensation be canceled prior to initiating smoothing and the post also requires that the tool be retracted prior to canceling the tool length compensation (this is a safety feature, since the tool can plunge into the part if the tool has not been retracted first).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Not all Fanuc controls require that tool length compensation be canceled prior to initiating the smoothing mode, either due to the control model or type of smoothing being used.&amp;nbsp; If your control/smoothing mode does not require that tool length compensation be canceled first, then you can modify the following code in the post to remove this requirement.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;function onSection() {
...
 if (insertToolCall || newWorkPlane) {&lt;BR /&gt;   // retract to safe plane&lt;BR /&gt;   writeRetract(Z); // retract&lt;BR /&gt;   forceXYZ();&lt;BR /&gt; }
 if ((insertToolCall &amp;amp;&amp;amp; !isFirstSection()) || forceSmoothing) {
   &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;if (insertToolCall &amp;amp;&amp;amp; !isFirstSection()) {&lt;/STRONG&gt; &lt;STRONG&gt;// add this line&lt;/STRONG&gt;&lt;/FONT&gt;
     disableLengthCompensation();
   &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;} // add this line&lt;/STRONG&gt;&lt;/FONT&gt;
   setSmoothing(false);
 }
...
...
function setSmoothing(mode) {
  if (mode == currentSmoothing) {
    return false;
  }

  // 1) Make sure G49 is called before the execution of G05.1 Q1 Rx
  // 2) G05.1 Q1 Rx must be engaged BEFORE G43-Tool Length Comp
  // 3) AICC and AIAPC need to be turned on and off for each tool
  // 4) AICC and AIAPC does not apply to canned drilling cycles
  &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;//&lt;/STRONG&gt;&lt;/FONT&gt; validate(!lengthCompensationActive, "Length compensation is active while trying to update smoothing."); &lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;// comment out this line&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/PRE&gt;
&lt;P&gt;It is not recommended that you disable the retract move if you are using tool length compensation for tool changes for the reason mentioned above, just in case you completely removed the retract move in your version of the post.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 23 Jul 2018 16:23:29 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/8149069#M13967</guid>
      <dc:creator>bob.schultz</dc:creator>
      <dc:date>2018-07-23T16:23:29Z</dc:date>
    </item>
    <item>
      <title>Re: HELP w/FANUC Post</title>
      <link>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/10702437#M13968</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/3704064"&gt;@bob.schultz&lt;/a&gt;&amp;nbsp; I have a similar issue and have followed your code but cant seem to figure it out. Would you be able to point me in the right direction?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 24 Oct 2021 15:13:42 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/10702437#M13968</guid>
      <dc:creator>DerekZCXVY</dc:creator>
      <dc:date>2021-10-24T15:13:42Z</dc:date>
    </item>
    <item>
      <title>Re: HELP w/FANUC Post</title>
      <link>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/10702558#M13969</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/11260622"&gt;@DerekZCXVY&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Your situation is a bit different, since you commented out or removed all calls to &lt;U&gt;writeRetract&lt;/U&gt;, which means that the tool will never be fully retracted; not at tool changes, not when the rotary axes position changes, not at the end of the program.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;First I will ask if you are sure that this is what you are expecting and is it safe on the machine?&lt;/P&gt;</description>
      <pubDate>Wed, 20 Oct 2021 22:29:36 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/10702558#M13969</guid>
      <dc:creator>bob.schultz</dc:creator>
      <dc:date>2021-10-20T22:29:36Z</dc:date>
    </item>
    <item>
      <title>Re: HELP w/FANUC Post</title>
      <link>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/10702675#M13970</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/3704064"&gt;@bob.schultz&lt;/a&gt;Thanks for the prompt reply. I believe so this came from the manufacture as is (outside of a couple minor tweaks such as programNameIsInteger made by me).&amp;nbsp;I know javascript quite well and have been reading up on the post processor training guide. I think I see what you mean, within onClose, writeRetract for all axis's are commented out as well as in defineWorkPlane. Why would one disable writeRetract ? I see in the properties section one can enable G28, do you know how that relation works? Apologies for all the questions I am fascinated with this topic and trying to learn. The manufacture has not been much help since they dont support fusion 360 it appears that they took the Fanuc post processor from the fusion 360 library and modified it to work with there machines as more of a favor.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Back to the original question, yes I believe it is safe to do so. Within the onOpen function the B axis is limited to -100/100 degrees. That is the axis that could do the most damage but it being limited limits the potential damage quite a bit.&amp;nbsp; What do you think ? Should I enable writeRetract at least for the Z axis ? Outside of that what should I configure to put this error to bed?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sorry for the long reply and thanks for looking into it ! Are there any other resources I can look into to learn more about post processor development ? I have been reading up on the post processor documentation and downloaded it as a .chm file as well as reading up on the PP training guide. Pretty cool stuff !&lt;/P&gt;</description>
      <pubDate>Wed, 20 Oct 2021 23:51:13 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/10702675#M13970</guid>
      <dc:creator>DerekZCXVY</dc:creator>
      <dc:date>2021-10-20T23:51:13Z</dc:date>
    </item>
    <item>
      <title>Re: HELP w/FANUC Post</title>
      <link>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/10707736#M13971</link>
      <description>&lt;P&gt;I would suggest that add the call to &lt;U&gt;writeRetract&lt;/U&gt; back at the start of &lt;U&gt;onSection&lt;/U&gt; at the very least.&lt;/P&gt;
&lt;LI-CODE lang="javascript"&gt;    if ((insertToolCall &amp;amp;&amp;amp; !isFirstSection()) || forceSmoothing) {
      writeRetract(Z); // &amp;lt;&amp;lt;&amp;lt; ADD THIS LINE
      disableLengthCompensation();
      setSmoothing(false);
    }&lt;/LI-CODE&gt;
&lt;P&gt;And also in the &lt;U&gt;onClose&lt;/U&gt; function.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you determine that that the tool does not have to be fully retracted to &lt;STRONG&gt;safely&lt;/STRONG&gt; disable length compensation (G49), then you can remove the check to verify that it is retracted in the &lt;U&gt;disableLengthCompensation&lt;/U&gt; function.&lt;/P&gt;
&lt;LI-CODE lang="javascript"&gt;/** Disables length compensation if currently active or if forced. */
function disableLengthCompensation(force) {
  if (lengthCompensationActive || force) {
    // validate(retracted, "Cannot cancel length compensation if the machine is not fully retracted."); // &amp;lt;&amp;lt;&amp;lt; COMMENT OUT THIS LINE
    writeBlock(gFormat.format(49));
    lengthCompensationActive = false;
  }
}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 22 Oct 2021 21:25:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/10707736#M13971</guid>
      <dc:creator>bob.schultz</dc:creator>
      <dc:date>2021-10-22T21:25:49Z</dc:date>
    </item>
    <item>
      <title>Re: HELP w/FANUC Post</title>
      <link>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/10710046#M13972</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/3704064"&gt;@bob.schultz&lt;/a&gt;Thanks for the feedback. Yeah I never realized that I could just comment out that validate function, I feel pretty foolish. Tomorrow Ill go ahead and do some testing and act accordingly. Thanks again for the insight!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;All the best,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;DMC&lt;/P&gt;</description>
      <pubDate>Sun, 24 Oct 2021 15:14:10 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/hsm-post-processor-forum/help-w-fanuc-post/m-p/10710046#M13972</guid>
      <dc:creator>DerekZCXVY</dc:creator>
      <dc:date>2021-10-24T15:14:10Z</dc:date>
    </item>
  </channel>
</rss>

