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:

Tombstone transform ops help


YoDoug®
 Share

Recommended Posts

I have the following set-up

tombstone.jpg

 

2 identical parts on 4 sides of a tombstone. I want to use transform ops so the posted code uses the same subprogram for all 8 parts. I need separate work offsets for each part. I can transform translate, then transform rotate and I get close to what I want, 2 identical subs and the program rotates to do 1 part per face (extra not needed rotations)

 

uploaded file to ftp://www.ppcadcam.com/Mastercam_forum/MC...UT-TEST_ASM.Z2G

 

Thanks in advance

Link to comment
Share on other sites

This type of setup, First when I cut the pocket to hold the part, I will use same program for top jaws and the bottom jaws only with 2 diff workoffset. So I will cut the pocket at B0,B90,B180,B270. With using 2 work offset. When I will make the part program, eg T1 will come at B0G54P1--: B0 g55P1--- than B90 G54P1--:B90G55P1-- and so on. Very short program and very effective

Link to comment
Share on other sites

depends on what your after Doug. do you want each tool to run on every part before tool change? I've found its faster to index than tool change but thats based on the machine. is this a long run job? if so I'd write the subs as I want them and hand edit in the sub calls. the main prg is actually quite short.

BTW you guys busy?

Link to comment
Share on other sites

MayDay

 

We are not that busy in the Tulsa shop. The part in question is for our production shop. I am trying to get the post worked out to minimize length of program without having to do a lot of hand editing.

 

Some of our parts can see 10-20 parts per pallet, 3-4 different work holding positions and 40+ tools. The control memory problem starts to come into play.

 

I have some one off bail wire forming tools that I may have to outsource soon. If I need to, I'll give you a call. I have the first designs finished and I am awaiting approval from the wire bending vendor.

Link to comment
Share on other sites
Guest CNC Apps Guy 1

I've done some stuff with Custom MACRO B and my post concerning that. You basically control the number of parts through MACRO variables as well as the distance in X, Y and/or B.

 

code:

%

O1234 (TOOLPATH GROUP 1 )

(PROGRAM-VERSION=1)

(PROGRAMMER=CNC APPS GUY)

(RUN-TIME=00-00-00)

(CUTTING-TIME=00-00-00)

(AUX-TIME=00-00-04)

(SECURITY-CLASS=1)

(PROGRAM-TYPE=0)

(PROGRAM-CLASS=0)

(COMPANY - GEEK BOY PRODUCTS)

(PRINT - TOOLPATH GROUP 1 )

(PROGRAM - O1234 )

(POST - MULTI-INDEX-G52XY-HX-16I.PST )

 

(******************************)

( G54 )

(X-15.9453 IS THE CENTER LINE OF ROTATION)

(Z-24.8896 IS THE FACE OF A 4 SIDED TOWER)

(Z-21.4107 IS THE FACE OF AN EIGHT SIDED TOWER)

G90 G10 L2 P1 X-15.9453 Y0. Z-23.5896 B0.

(X ZERO IS )

(Y ZERO IS )

(Z ZERO IS )

(B ZERO IS )

(******************************)

 

#108=0 (RESET BROKEN TOOL FLAG)

#526=1 (NUMBER OF INDEX'S IN
B)

#527=90. (B INDEX AMOUNT)

#528=1 (NUMBER OF STEPS IN X)

#529=0. (X STEP AMOUNT)

#530= 1. (NUMBER OF STEPS IN Y)

#531= 0. (Y STEP AMOUNT)

 

(TIME - 09:29)

(DATE - 07-22-2005)

 

(T-START)

(T1011;;.500 SHARP ENDMILL - ALUMINUM )

(T-END)

 

G65P4(RESET COMMON WORK SHIFT)

 

G52 X0 Y0 Z0 B0

G91 G28 Z0

G91 G30 X0 Y0

G0 G90 G54

G40 G64 G80 G17 G49 M11

M01

 

(T1011;;.500 SHARP ENDMILL - ALUMINUM )

T1011 M6

(CHECK CURRENT TOOL OFFSET)

#108=0

#101=#[10000+#606]

WHILE[#101LE3.]DO1

GOTO99999

END1

T1011

M08

G52 X0 Y0 Z0 B0

G05.1 Q1

M11

G54 G0 G90 G43 H99 X0. Y0. Z9. B0. S13000 M03

G17

M10

#101=1

#104=0

WHILE[#101LE#530]DO2

#111=1

#114=0

WHILE[#111LE#528]DO3

N1G52 X#114Y#104B#124

M08

G0 G54 X0. Y0. S13000

M28

Z.01

G1 Z0. F120.0

G41 D99 X-.25

G3 Z-.0823 I.25 J0.

Z-.1646 I.25 J0.

Z-.247 I.25 J0.

Z-.3293 I.25 J0.

Z-.4116 I.25 J0.

Z-.4939 I.25 J0.

X-.2237 Y-.1117 Z-.5 I.25 J0.

X-.25 Y0. I.2237 J.1117

X-.1427 Y-.2053 I.25 J0.

G40 G1 X0. Y0.

Z-.49

G0 Z9.

#111=#111+1

#114=#114+#529

END3

#101=#101+1

#104=#104+#531

END2

M11

M9

G52 X0 Y0 Z0 B0

G05.1 Q0

M29

/G65 P9905 D#606 C2. E.01 F15. H#606 Q.005 U.25 V.25 Z0.

G91 G28 Z0 M219

G91 G30 X0 Y0

G49

IF[#108EQ1]GOTO99999

M1

M30

N99999

M1

M70

#1107=1

G4X3.

#1107=0

M30

%

This should give you some format to look at.

Link to comment
Share on other sites

I always program our horizontals from Part Zero and set up my WCS's 1 per part per orientation.

 

In the 2pc/side w/ 4 sides 1 orientation scenario

I would launch all my tools from the main program

 

Call the subs for cutting using the L word (# of reps) ie. G65P5221L4 (call macro 5221 4 times)

 

In 5221 I would set up a While loop which increments the WCS

ie.

#21=1

WHILE [#21 LE 2.] DO 1

G54P#21

|

cutting code

|

#21=[#21+1]

END 1

G65P9011B90(incremental B axis indexer macro)

M99

 

this shortened example uses the G54P extended offsets but one can use G54-G59 as well

 

to review:

the main calls the tools then their cutting sub

the # of times = # sides of Tstone

The loop in the sub repeats itself for the # of parts / face by incrementing the WCS

At the end of the sub we call an incremental indexing routine then exit back to the main which automatically decreases the L counter by 1 and (if not zero) calls the cutting sub again.

 

The code example I gave is really shortened, but in a nutshell, I only program the code for 1 part only and have repetitive calls and macro statements handle the multiple parts.

If I change one macro variable , the exact same code will produce a one-off for setup verification purposes.

 

If interested, shoot me an email and I'll go into more detail w/ code that actually works.

 

cp

Link to comment
Share on other sites

Thanks for the examples Charlie and James. I want to try to avoid using macros because this is for our production shop and the programmers there are not as skilled. I was hoping to find a simple solution in Mcx for this example. I like to have the Code 100% machine ready when posted, no editing. They have a tendency to hand edit code way too much, that's why I started trying to figure this out.

Link to comment
Share on other sites

quote:

I couldn't get the MPsubrep to do any B rotations or clearance moves to go with the B. It put out everything else you were looking for.


Aye, MPSUBREP does not support 4 axis...however, I got the impression that he was going to use his work offsets to get the rotations.

 

So in mastercam there would be no transform ops, but the post will spit out a main program that calls the fixture offsets, then a sub for each tool.

Link to comment
Share on other sites

I am off today so I don't have my work laptop up, so I can't access Mastercam. However after taking a brief look at the MPsubrep post it has a post switch for Horizontal/vertical rotary.

 

code:

machine    : 1     # 0 = No index moves, 1 = Horizontal, 2 = Vertical  

I will give it a try tomorrow when I am back in the office.

Link to comment
Share on other sites
Guest CNC Apps Guy 1

IMHO, MACRO B is the superior way to do this. You have the EXACT SAME CODE running multiples of times (same as Subprograms) BUT, you control the number of times and locations with variables. Boss says I only want 2... you put 2 in the variable. He wants 10 (and your foxture is set up for 10), you put 10 in the variable.

 

The key is putting all the necessary logic in your post so you don't have to edit anything. biggrin.gif

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...