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:

Post help IF statment ??


gcode
 Share

Recommended Posts

I'm trying to modifiy a Heidenhain post

to test for through tool coolant and

output the correct code

.

With regular coolant I need

 

;SPOT DRILL 1"-8 HOLES 4 PLCS*

N6 G247 Q339=3*

N8 G00 G40 G90 X+1.7236 Y-1.7236 B120 W+0*

N10 Z+26 M08*

 

With through coolant I need

 

;DRILL 1.50 DIA THRU 1 PLC*

N38 G247 Q339=3*

N40 G00 G40 G90 X+0 Y+0 B120 W+0*

N42 Z+60 M74*

N44 M08*

 

my coolant output table is working correctly

 

# Coolant M code selection

sm09 M09 #Coolant Off

sm08 M08 #Coolant Flood

sm08_1 M08 #Coolant Mist

sm08_2 M74 #Coolant Tool

scoolant #Target for string

 

fstrsel sm09 coolant$ scoolant 4 -1

 

what's got me stumped is the test

for sm08_2 and outputting the

second M08..

 

obviosly I need some kind of IF test

but I'm not having any luck

 

can anyone point me in the right direction

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