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:

Can D (tool dia) number be set by the post?


millman2002
 Share

Recommended Posts

Hi all:

I hope I can describe what I need so you can under stand it. I have to program the same parts to run on three different machines. Fadal, Mazak, Matsuura.

What I am want to do is make one MC9 file with the tool dia. offset and tool length offset set the same as the tool no. (under Job setup, Tool Offset Registers, Add checked, length and diameter set to 0). Then, when I run the post for Fadal and Mazak, it will out put T1 - D1 - H1.

Can I change the mpfan.pst so that I can use the same MC9 file (with tool dia. offset set same as tool number) but have the post output T1 - D41 - H1 ?

Basically take the tool dia. offset and add 40 to in the post..

I hope I haven’t confused everyone..

Thank

Gary

Link to comment
Share on other sites

It's pretty easy to add a statement in the post to add 40 to the offset.

 

I'd recommend creating a new variable (tloffno40), and then set this variable to the tloffno + 40, and output it in place of tloffno in the pccdia section.

 

You need to define the tloffno40 variable first:

 

fmt D 4 tloffno40

 

Just search for tloffno in the post, and you'll see the right format and what needs to be replaced.

 

You may want to enlist your dealer to help, but this should not be a difficult change.

Link to comment
Share on other sites

Thanks All:

The post is working with one problem. After a tool change the first D outputs OK. G41 D41 X0 y0. But the rest of the G41s have no D. G41 X0 Y0.

Sample code:

T19M6

G0G90G54X-10.0708Y-3.154A0.S2139M3

G43H19Z2.M8

Z.1

G1Z-.27F6.42

G41D59X-9.9626Y-3.2165(has 40 added to D. OK)

G3X-9.5876Y-3.R.25

X-10.6956R.554

G1G40X-9.6621Y-2.8202

G0Z2.

X-.0533Y-3.154

Z.1

G1Z-.27

G41X.055Y-3.2165 (Does not put D for each G41

G3X.43Y-3.R.25

 

Here’s what I changed

# Toolchange / NC output Variable Formats

# --------------------------------------------------------------------------

fmt T 4 t #Tool Number

fmt T 4 first_tool #First Tool Used

fmt T 4 next_tool #Next Tool Used

fmt D 4 tloffno #Diameter Offset Number

fmt D 4 tloffno40 #Diameter Offset Number + 40 #added this line

fmt H 4 tlngno #Length Offset Number

 

 

pccdia #Cutter Compensation

#Force Dxx#

tloffno40 = tloffno + 40

if prv_cc_pos <> cc_pos & cc_pos,

prv_tloffno = c9k

sccomp

if cc_pos, tloffno40 #Changed from tloffno # Changed this line

 

Is there something I need to change?

 

Thanks again

Gary

Link to comment
Share on other sites

Original Code...

 

code:

 pccdia #Cutter Compensation

#Force Dxx#

tloffno40 = tloffno + 40

if prv_cc_pos <> cc_pos & cc_pos,

prv_tloffno = c9k

sccomp

if cc_pos, tloffno40 #Changed from tloffno #


Change "prv_tloffno = c9k"

to be "prv_tloffno40 = c9k"

 

Altered Code...

 

code:

 pccdia #Cutter Compensation

#Force Dxx#

tloffno40 = tloffno + 40

if prv_cc_pos <> cc_pos & cc_pos,

prv_tloffno40 = c9k

sccomp

if cc_pos, tloffno40 #Changed from tloffno #


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