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:

extracting operation parameters from a specific operation


Tim Johnson
 Share

Recommended Posts

I need the plunge and retract feeds for an extra length coolant thru drill. The info is showing up correctly in the NCI file but it appears that the post is only doing the search at the beginning of the file, repeats through all the tools and is done. I need to know how to pull the info during the current operation. I tried the drillcyc$ = 10 but either it doesn't work or I'm not doing it correctly.

 

With one tool;

code:

 (NO.21 EXTRA LENGTH 30XD COOLANT THRU CARBIDE DRILL RIGHT SIDE)

N0010 G00 G90 X.68 Y-2.18 (B270.) G59

N0020 G43 H[#940+11] Z.2 S1562 M[#933]

N0030 Z.05

N0040 G01 Z-.527F18.74 <<<<<<<<<

N0050 S9610 M[#933]

N0060 G04 P2000

N0070 G01 Z-4.82F57.66

N0080 G04 P250

N0090 G01 Z-5.3289

N0100 S1562 M[#933]

N0110 G01 Z.05 F28.12 <<<<<<<<

N0120 G00 X.99 Y-.75

N0130 Z-.145

N0140 G01 Z-.722F18.74 <<<<<<<

N0150 S9610 M[#933]

N0160 G04 P2000

N0170 G01 Z-5.015F57.66

N0180 G04 P250

N0190 G01 Z-5.7139

N0200 S1562 M[#933]

N0210 G01 Z-.145 F28.12 <<<<<<<

N0220 G00 Z6.625

With the file;

code:

 (NO.21 EXTRA LENGTH 30XD COOLANT THRU CARBIDE DRILL RIGHT SIDE)

N6600 G00 G90 X.68 Y-2.18 (B270.) G59

N6610 G43 H[#940+11] Z.2 S1562 M[#933]

N6620 Z.05

N6630 G01 Z-.527F100. <<<<<<<<<

N6640 S9610 M[#933]

N6650 G04 P2000

N6660 G01 Z-4.82F57.66

N6670 G04 P250

N6680 G01 Z-5.3289

N6690 S1562 M[#933]

N6700 G01 Z.05 F250. <<<<<<<<<<<

N6710 G00 X.99 Y-.75

N6720 Z-.145

N6730 G01 Z-.722F100. <<<<<<<<<

N6740 S9610 M[#933]

N6750 G04 P2000

N6760 G01 Z-5.015F57.66

N6770 G04 P250

N6780 G01 Z-5.7139

N6790 S1562 M[#933]

N6800 G01 Z-.145 F250. <<<<<<<<<<<

N6810 G00 Z6.625

The incorrect feedrates are from my last tool.

Link to comment
Share on other sites

I added the drillcyc$ = 10 into pparameter$ and added the call in my drill cycle;

code:

pparameter$ # Run parameter table

if opcode$=13 | opcode$=14, result = fprm (opcode$)

if prmcode$ = 10000, stoper = ucase(sparameter$)

if prmcode$ = 10055, spostname = ucase(sparameter$)

if stoper=snull, stoper = snullop

 

if drillcyc$ = 10,

[

if prmcode$ = 10031, plunge = rpar(sparameter$, 1)

if prmcode$ = 15140, retract = rpar(sparameter$, 1)

]

and got;

code:

 (NO.21 EXTRA LENGTH 30XD COOLANT THRU CARBIDE DRILL RIGHT SIDE)

N6600 G00 G90 X.68 Y-2.18 (B270.) G59

N6610 G43 H[#940+11] Z.2 S1562 M[#933]

N6620 Z.05

N6630 G01 Z-.527F100.

N6640 S9610 M[#933]

N6650 G04 P2000

N6660 G01 Z-4.82F57.66

N6670 G04 P250

N6680 G01 Z-5.3289

N6690 S1562 M[#933]

N6700 G01 Z.05 F250.

N6710 G00 X.99 Y-.75

N6720 Z-.145

N6730 G01 Z-.722F57.66

N6740 S9610 M[#933]

N6750 G04 P2000

N6760 G01 Z-5.015F57.66

N6770 G04 P250

N6780 G01 Z-5.7139

N6790 S1562 M[#933]

N6800 G01 Z-.145 F57.66

N6810 G00 Z6.625

The first hole didn't change but the second hole changed to the standard feerate. confused.gif

 

code:

pdrlcst_2$       #Custom drill cycles 8 - 19, additional points (user option)

#Use this postblock to customize drilling cycles 8 - 19

pdrlcommonb

#if drillcyc = 8, pcan1, pbld, n, pdrlxy, pzout, pcout, prdrlout, dwell,

# feed, strcantext, e

if drillcyc$ = 8, # Subprogram Call cycle

[

sub_prg_call = peck1$

pcan1, pbld, n$, *sg00, *sgabsinc, pfxout, pfyout, strcantext, e$

pbld, n$, "M98", *sub_prg_call, e$

]

if drillcyc$ = 9, # Gun Drill -- Standard cycle

[

pdrlcst$

]

if drillcyc$ = 10, # extra length coolant thru drill cycle

[

pdrlcst$

]

Link to comment
Share on other sites

I've just tried copying the cycle into pdrlcst_2$ with no change. It would be nice if there are variables for the plunge/retract feed fields during a drill cycle, but I can't find any info on them. I did find parameters 10031 and 15140 but even with the limited success with them, they appear to copy 10030 (feed). So it still boils down to me having to get the info from parameter 20004.

Link to comment
Share on other sites

Ok, I finaly got it to work smile.gif

 

code:

pparameter$ # Run parameter table

if opcode$=13 | opcode$=14, result = fprm (opcode$)

if prmcode$ = 10000, stoper = ucase(sparameter$)

if prmcode$ = 10055, spostname = ucase(sparameter$)

if stoper=snull, stoper = snullop

if prmcode$ = 20004, slot = rpar(sparameter$, 16) #<<<<<<<<<<<<<<<<<<<

 

# if drillcyc$ = 10,

# [

# if prmcode$ = 10031, plunge = rpar(sparameter$, 1)

# if prmcode$ = 15140, retract = rpar(sparameter$, 1)

# ]

I tried adding that line inside the if drillcyc$ = 10 brackets with no success but sticking it with the rest of the fellas did work.

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