Jump to content

Welcome to eMastercam

Register now to participate in the forums, access the download area, buy Mastercam training materials, post processors and more. This message will be removed once you have signed in.

Use your display name or email address to sign in:

order of subprograms


Recommended Posts

First, let me preface that I know just about nothing about post processor development. I was able to go into my post processor, and guess my way through some real easy stuff (e.g. switching M98 and O... to M97 and N...) but that's my limit. So you'll have to give me the 'for idiot's' version.

 

I was wondering if there was an easy way to get my Haas post processor to give me subprograms organized by both tool (which it does already) and offset.

 

E.g. Right now I get something like:

 

Tool 1:

 

G54

Sub program 1

 

G55

Sub program 1

 

G54

Sub program 2

 

G55

Sub program 2

 

 

 

 

Tool 2:

 

G54

Sub program 3

G55

Sub program 3

G54

Sub program 4

G55

Sub program 4

 

What I want is more like:

 

 

Tool 1:

 

G54

Sub program 1

G54

Sub program 2

G55

Sub program 1

G55

Sub program 2

 

Tool 2:

 

G54

Sub program 3

G54

Sub program 4

G55

Sub program 3

G55

Sub program 4

 

 

Hope that's clear, and thanks in advance.

Link to comment
Share on other sites

First, let me preface that I know just about nothing about post processor development. I was able to go into my post processor, and guess my way through some real easy stuff (e.g. switching M98 and O... to M97 and N...) but that's my limit. So you'll have to give me the 'for idiot's' version.

 

I was wondering if there was an easy way to get my Haas post processor to give me subprograms organized by both tool (which it does already) and offset.

 

E.g. Right now I get something like:......

 

 

Hope that's clear, and thanks in advance.

Looks like you want every tool to come out of its pocket once and run every sub it cuts in. Are these identical parts being machined at G54 and G55 or is it a second OP after a first. There are two ways to go at this but I need your answer !

Link to comment
Share on other sites

Is this the format you're looking for?

 

O0000 (WORK OFFSETS_SUB)

(PROGRAM - WORK OFFSETS_SUB.NC)

( NOV-28-2012 10:42 AM)

(T1 - 3/4 SPOTDRILL - H1 - D1 - D0.7500")

(T2 - 27/64 DRILL - H2 - D2 - D0.4219")

(T3 - 5/8 FLAT ENDMILL - H3 - D3 - D0.6250")

(T4 - 3/8 FLAT ENDMILL - H4 - D4 - D0.3750")

N5 G00 G17 G20 G40 G80 G90

N10 G91 G28 Z0.

N15 T1 M06 ( 3/4 SPOTDRILL)

N20 G00 G17 G90 G54 A0. X4. Y-1.25 S2037 M03

N25 G43 H1 Z.1 T2

N30 M98 P0001

N35 G90 G55 X4. Y-1.25 Z.1

N40 M98 P0001

N45 G90 G56 X4. Y-1.25 Z.1

N50 M98 P0001

N55 G90 G57 X4. Y-1.25 Z.1

N60 M98 P0001

N65 M05

N70 G91 G28 Z0.

N75 M01

N80 T2 M06 ( 27/64 DRILL)

N85 G00 G17 G90 G54 A0. X4. Y-1.25 S2037 M03

N90 G43 H2 Z.1 T3

N95 M98 P0002

N100 G90 G55 X4. Y-1.25 Z.1

N105 M98 P0002

N110 G90 G56 X4. Y-1.25 Z.1

N115 M98 P0002

N120 G90 G57 X4. Y-1.25 Z.1

N125 M98 P0002

N130 M05

N135 G91 G28 Z0.

N140 M01

N145 T3 M06 ( 5/8 FLAT ENDMILL)

N150 G00 G17 G90 G54 A0. X1.6875 Y1.0313 S1069 M03

N155 G43 H3 Z.125 T4

N160 M98 P0003

N165 G90 G55 X1.6875 Y1.0313 Z.125

N170 M98 P0003

N175 G90 G56 X1.6875 Y1.0313 Z.125

N180 M98 P0003

N185 G90 G57 X1.6875 Y1.0313 Z.125

N190 M98 P0003

N300 M05

N305 G91 G28 Z0.

N310 G28 Y0. A0.

N315 G90

N320 M30

 

O0001

N5 G91

N10 G94

N15 G99 G81 Z-.413 R0. F32.6

N20 G80

N25 M99

 

O0002

N5 G91

N10 G94

N15 G99 G81 Z-1.2867 R0. F32.6

N20 G80

N25 M99

 

O0003

N5 G91

N10 G94 G01 Z-.337 F6.42

N15 Y-.3438

N20 G03 X.3125 Y-.3125 I.3125 J0.

N25 G01 X2.

N30 G02 Y-3.25 I0. J-1.625

N35 G01 X-4.

N40 G02 X-.375 Y.375 I0. J.375

N45 G01 Y2.5

N450 G02 X.3125 Y.3125 I.3125 J0.

N455 G01 X2.

N460 G03 X.3125 Y.3125 I0. J.3125

N465 G01 Y.3438

N470 Z.125

N475 G00 Z1.06

N480 M99

 

I'm using the MpMaster post to output this code in McamX6, you can do this with one transform op and you'll need to set the parameters like the attached jpegs.

Link to comment
Share on other sites

Looks like you want every tool to come out of its pocket once and run every sub it cuts in. Are these identical parts being machined at G54 and G55 or is it a second OP after a first. There are two ways to go at this but I need your answer !

 

In my example, it was two identical parts in different offsets. This is what I normally do, day to day, so is most relevant for me.

Link to comment
Share on other sites

Is this the format you're looking for?

 

O0000 (WORK OFFSETS_SUB)

(PROGRAM - WORK OFFSETS_SUB.NC)

( NOV-28-2012 10:42 AM)

(T1 - 3/4 SPOTDRILL - H1 - D1 - D0.7500")

(T2 - 27/64 DRILL - H2 - D2 - D0.4219")

(T3 - 5/8 FLAT ENDMILL - H3 - D3 - D0.6250")

(T4 - 3/8 FLAT ENDMILL - H4 - D4 - D0.3750")

N5 G00 G17 G20 G40 G80 G90

N10 G91 G28 Z0.

N15 T1 M06 ( 3/4 SPOTDRILL)

N20 G00 G17 G90 G54 A0. X4. Y-1.25 S2037 M03

N25 G43 H1 Z.1 T2

N30 M98 P0001

N35 G90 G55 X4. Y-1.25 Z.1

N40 M98 P0001

N45 G90 G56 X4. Y-1.25 Z.1

N50 M98 P0001

N55 G90 G57 X4. Y-1.25 Z.1

N60 M98 P0001

N65 M05

N70 G91 G28 Z0.

N75 M01

N80 T2 M06 ( 27/64 DRILL)

N85 G00 G17 G90 G54 A0. X4. Y-1.25 S2037 M03

N90 G43 H2 Z.1 T3

N95 M98 P0002

N100 G90 G55 X4. Y-1.25 Z.1

N105 M98 P0002

N110 G90 G56 X4. Y-1.25 Z.1

N115 M98 P0002

N120 G90 G57 X4. Y-1.25 Z.1

N125 M98 P0002

N130 M05

N135 G91 G28 Z0.

N140 M01

N145 T3 M06 ( 5/8 FLAT ENDMILL)

N150 G00 G17 G90 G54 A0. X1.6875 Y1.0313 S1069 M03

N155 G43 H3 Z.125 T4

N160 M98 P0003

N165 G90 G55 X1.6875 Y1.0313 Z.125

N170 M98 P0003

N175 G90 G56 X1.6875 Y1.0313 Z.125

N180 M98 P0003

N185 G90 G57 X1.6875 Y1.0313 Z.125

N190 M98 P0003

N300 M05

N305 G91 G28 Z0.

N310 G28 Y0. A0.

N315 G90

N320 M30

 

O0001

N5 G91

N10 G94

N15 G99 G81 Z-.413 R0. F32.6

N20 G80

N25 M99

 

O0002

N5 G91

N10 G94

N15 G99 G81 Z-1.2867 R0. F32.6

N20 G80

N25 M99

 

O0003

N5 G91

N10 G94 G01 Z-.337 F6.42

N15 Y-.3438

N20 G03 X.3125 Y-.3125 I.3125 J0.

N25 G01 X2.

N30 G02 Y-3.25 I0. J-1.625

N35 G01 X-4.

N40 G02 X-.375 Y.375 I0. J.375

N45 G01 Y2.5

N450 G02 X.3125 Y.3125 I.3125 J0.

N455 G01 X2.

N460 G03 X.3125 Y.3125 I0. J.3125

N465 G01 Y.3438

N470 Z.125

N475 G00 Z1.06

N480 M99

 

I'm using the MpMaster post to output this code in McamX6, you can do this with one transform op and you'll need to set the parameters like the attached jpegs.

 

No, not quite, because in your example, each tool only has one sub for each offset. This, I have no problem with.

 

My issue arises when I have multiple subs for one tool for each offset. The order goes by sub, alternating offsets. I want it to go by offset, run through all subs for the tool, and then move to the next offset for that tool. When the tool is done, it moves to the next tool, and goes through all it's subs in the same way.

Link to comment
Share on other sites

I was just going to respond that it didn't work, when I tried grouping NCI output by Operation Order and ticking 'unique subprograms'.

 

Functionally, I believe it's giving me what I want. The only difference being that it creates a new (identical) subprogram for each offset if there's only one subprogram for the tool per offset.

 

Thanks.

Link to comment
Share on other sites

%
O0001(TEMP_OPS)
(DATE=DD-MM-YY - 28-11-12 TIME=HH:MM - 13:47)
(MCX FILE - T)
(NC FILE - I:\TEMP_OPS.NC)
(MATERIAL - ALUMINUM INCH - 2024)
( T1 | 1/4 SPOTDRILL | H1 )
( T8 | 1/4 DRILL | H8 )
G20
G0 G17 G40 G49 G80 G90
G0 G90 G54 X-1. Y1. Z.1 A0.
M98 P0001
M5
G91 G28 Z0.
A0.
M01
G0 G90 G55 X-1. Y1. Z.1 A0.
M98 P0001
M5
G91 G28 Z0.
G28 X0. Y0. A0.
M30

O0001
G91
( .25DR X4 )
T1 M6
G0 G90 X-1. Y1. A0. S1000 M3
G43 H1 Z.1
G99 G81 Z-.1 R.1 F6.
Y-1.
X1.
Y1.
G80
( .25DR X4 )
X-1.
G99 G81 Z-.1 R.1 F6.
Y-1.
X1.
Y1.
G80
M5
G91 G28 Z0.
A0.
M01
( .25DR X4 )
T8 M6
G0 G90 X-1. Y1. A0. S809 M3
G43 H8 Z.1
G99 G81 Z-.25 R.1 F3.
Y-1.
X1.
Y1.
G80
( .25DR X4 )
X-1.
G99 G81 Z-.25 R.1 F3.
Y-1.
X1.
Y1.
G80
M99
%

This does what you want, first SUB runs the first tool completely before moving to the second offset to run the same tool in its entirety. However this posses a problem if you want to run the second run of Tool #1 on G54 because that selection is within the SUB P0001. This might take a Guru to modify a post, we have to get the POST to look at the SUB and determine if its the SAME SUB so that a new P#### is not generated, then it has to sort the output by Tool Plane/Operation Order and not Operation Type.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.

Join us!

eMastercam - your online source for all things Mastercam.

Together, we are the strongest Mastercam community on the web with over 56,000 members, and our online store offers a wide selection of training materials for all applications and skill levels.

Follow us

×
×
  • Create New...