Safety Issue in Hurco Post Processor with M140 Enabled (Autodesk Fusion Library)

Safety Issue in Hurco Post Processor with M140 Enabled (Autodesk Fusion Library)

laromosrl
Advocate Advocate
229 Views
1 Reply
Message 1 of 2

Safety Issue in Hurco Post Processor with M140 Enabled (Autodesk Fusion Library)

laromosrl
Advocate
Advocate

Hi,

 

I would like to report a malfunction in the Hurco post processor, version 44180, without any customization.

The issue occurs when the M140 command is enabled. Specifically, when the following line is generated:

 

G0 M140

the post does not output the safety command G53 Z0 before executing:

G0 B0. C-180

This omission can lead to a collision, if the head is tilted at B-90 and positioned close to the table, since the Z-axis retraction is not performed beforehand.

Additionally, I noticed that in the onClose() function, the G69 command is issued before the G0 M140, which is not correct for safe tool retraction on swivel-head machines.

I am attaching the correct code below to ensure safe machining operations.

 


How can I modify the post processor so that it:

Always inserts G53 Z0 before critical movements like G0 B0. C-180 when M140 is present.

Outputs G0 M140 before G69, maintaining the correct order?

Thank you in advance for your support.

Best regards.

https://a360.co/4ktT9fn  (for test)

 

N62 G0 B-90. C-180.
N63 G68.2 X0. Y0. Z0. B-90. C-180.
N64 G8.2 X-40. Y0. Z264.05 B-90. C-180.

...

N70 G81 X-40. Y0. Z30. R45. F200.
N71 G80
N72 Z264.05
N73 M5
N74 G0 M140
N75 G69

G53 Z0 (Z Home Command)  <-- NEED

N76 M35
N77 M13
N78 G0 B0. C-180.

 

... (onClose)
N100 G0 Z57.213
N101 M9
N102 G69
N103 G0 M140 (Retract Along Tool Vector)      Invert the order

G53 Z0 <-- ADD
N104 M31
N105 M35
N106 M13
N107 G0 B0. C0.
N108 M127
N109 G53 G0 X0. Y0.
N110 M61
N111 M2
E

0 Likes
Accepted solutions (1)
230 Views
1 Reply
Reply (1)
Message 2 of 2

boopathi.sivakumar
Autodesk
Autodesk
Accepted solution

I do agree its quite dangerous to use just only M140 for retract in the head configuration machines. 
thanks for brining this to our attention

 

I will make a ticket to resolve the issue 


mean while if you find the code here 

      case "G53":
        forceModals(gMotionModal);
        if (retract.retractAxes[2] && getProperty("useM140")) {
          writeBlock(gFormat.format(0), mFormat.format(140));
        } else {
          writeBlock(gAbsIncModal.format(90), gFormat.format(53), gMotionModal.format(0), words);
        }

You can modify this to 

      case "G53":
        forceModals(gMotionModal);
        if (retract.retractAxes[2] && getProperty("useM140")) {
          writeBlock(gFormat.format(0), mFormat.format(140));
          cancelWorkPlane();   // cancel workplane G53 is not allowed when 68.2 is active
          writeBlock(gAbsIncModal.format(90), gFormat.format(53), gMotionModal.format(0), words); // <<<<< Add this line
        } else {
          writeBlock(gAbsIncModal.format(90), gFormat.format(53), gMotionModal.format(0), words);
        }

It will force the G53 codes as well right after the M140

for the changing the order you can find the code in onClose function around 1520

  cancelWorkPlane();
  writeRetract(Z);

you need to just swap the order

 


Boopathi Sivakumar
Senior Technology Consultant

0 Likes