Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.

Move M01 to end of operation

chris8YCHC
Explorer

Move M01 to end of operation

chris8YCHC
Explorer
Explorer

Hello,

   I am currently using generic turning Fanuc post. I would like to change it so when it does a M01 optional stop it does it at the end of the operation after the G28 U0 W0, not at the beginning (like below). I have tried changing location of M01, but I can only make it stop posting the M01 when I comment it out the

if (!isFirstSection() && properties.optionalStop) {
      onCommand(COMMAND_OPTIONAL_STOP);

 

So how can I go about doing this?

 

 
 

 

How it is currently posting:

N1
(TURNING FACE)
T0101
G54
M8
G98
G97 S4000 M3
G0 X3.1496 Z0.
G0 Z0.0557
Z0.
M9
G28 U0. W0.

N2
(TURNING SINGLE GROOVE)
M1
T0202
G54
M8
G98
G97 S2000 M3
G0 X3.1496 Z0.
X3.1496
G0 Z0.

M9
G28 U0. W0.
M30
%
What I want it to look like:

N1
(TURNING FACE)
T0101
G54
M8
G98
G97 S4000 M3
G0 X3.1496 Z0.
G0 Z0.0557
Z0.
M9
G28 U0. W0.
M01

N2
(TURNING SINGLE GROOVE)
T0202
G54
M8
G98
G97 S2000 M3
G0 X3.1496 Z0.
X3.1496
G0 Z0.

M9
G28 U0. W0.
M30
%

 

0 Likes
Reply
Accepted solutions (1)
659 Views
7 Replies
Replies (7)

seth.madore
Community Manager
Community Manager

Do you have "Optional Stop" turned on at the post dialog?

2020-12-04_14h28_07.png

 

This is the code I get from that:

(DRILL3)
N16 T0909
N17 G54
N18 M88
N19 G98
N20 G97 S900 M3
N21 G0 X0. Z1.
N22 G0 Z0.125
N23 G83 X0. Z-2.3825 R0.125 Q0.8 F1.8
N24 G80
N25 Z1.
N26 M89
N27 G28 W0.
N28 G28 U0.

(PROFILE ROUGHING4 2)
N29 M1

Seth Madore
Customer Advocacy Manager - Manufacturing
0 Likes

chris8YCHC
Explorer
Explorer

Yes I have it turned on but I want it at the very end of each operation instead of the beginning of a operation before a tool change.

0 Likes

Laurens-3DTechDraw
Mentor
Mentor

We can agree that this is purely cosmetic right?

But see the attached post. Does that work like you want?

Laurens Wijnschenk
3DTechDraw

AutoDesk CAM user & Post editor.
René for Legend.


1 Like

seth.madore
Community Manager
Community Manager
Accepted solution

Not gonna lie, I had to read that a few times... The end of an operation IS the beginning of the next 😉

It's a quick and simple fix. Do you have Visual Studio Code? Autodesk made an add-in that works slick as.....well, it's slick.

Sorry Laurens, I made a ScreenCast and I didn't want my time wasted 😄

Seth Madore
Customer Advocacy Manager - Manufacturing
0 Likes

Laurens-3DTechDraw
Mentor
Mentor

No problem @seth.madore you did the better explanation. I did the better post-editing.

#Dreamteam?

Laurens Wijnschenk
3DTechDraw

AutoDesk CAM user & Post editor.
René for Legend.


1 Like

seth.madore
Community Manager
Community Manager

I don't doubt for a bit! My post edits are more....hack and slash and a bit of "eh, it works"


Seth Madore
Customer Advocacy Manager - Manufacturing
0 Likes

chris8YCHC
Explorer
Explorer

This worked just fine. Thanks for all the help.

0 Likes