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:

Custom Drill Cycle? Post Help


Paul McGarr
 Share

Recommended Posts

Hi,

 

I don't know if I need a custom drill cycle or what, but here's what I need...

 

I need to basically drill 24 holes in a part. At the bottom of the hole I need to have two (custom) lines of code in my program before the drill retracts from the hole. The two lines of code are predetermined and always the same so I can cram those into the post somewhere without much trouble.

 

Right now I program the holes with a peck cycle and post the program with canned cycles off in the post so I get long hand code. I then edit the program and paste the two lines of code in 24 places. This is no big deal, but everytime (several times a day) the hole pattern changes, it's another edit.

 

What would you guys do to make this easier? I'm running Mastercam 9 with MPMaster for 9.

 

Thanks,

 

Paul McGarr

Link to comment
Share on other sites

Well if it is all you use that particular drill cycle for, I would editing the post drill cycle would be OK. But if you use it for other things as well a Custom cycle is probably the way to.

 

What do you need you cycle to look like?

 

What post are you using?

Link to comment
Share on other sites

Agree custome drill cycle all the way. Here is one I did for a back spot facing.

 

 

pdrlcst		 #Custom drill cycles 8 - 19 (user option)

  #Use this postblock to customize drilling cycles 8 - 19

  pdrlcommonb

  #if drillcyc = 8, pcan1, pbld, n, *sgdrlref, *sgdrill, pdrlxy, pfzout, pcout, 

  #  prdrlout, dwell, *feed, strcantext, e

  if drillcyc = 8,

	[

	sub_prg_call = peck1

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

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

	]

  if drillcyc = 9,

	 [

	 pdrlcommonb

	 pcan1, pbld, n, pdrlxy, pfzout, pcout, *feed, strcantext, e

	 "M00", e

	 *drl_prm1, *drl_prm2, e

	 "G1", *drl_prm3 , *drl_prm4, e

	 *drl_prm5, e

	 "M00" , e 

	 *drl_prm6, e   

	 pcom_movea

	 ]   

  else, "CUSTOMIZABLE DRILL CYCLE ", pfxout, pfyout, pfzout, pfcout, e

  pcom_movea



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,

	[

	sub_prg_call = peck1

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

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

	]

  if drillcyc = 9,

	 [

	 pdrlcommonb

	 pcan1, pbld, n, pdrlxy, pcout, *feed, strcantext, e

	 pbld, n, pfzout, e

	 "M00", e

	 *drl_prm1, *drl_prm2, e

	 "G1", *drl_prm3, *drl_prm4, e

	 *drl_prm5, e

	 "M00" , e

	 *drl_prm6, e  

	 pcom_movea

	 ]		  

  else, "CUSTOMIZABLE DRILL CYCLE ", pfxout, pfyout, pfzout, pfcout, e

  pcom_movea


Then here is where they were defined:

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

fmt  Q  2   peck1	  #First peck increment (positive)

fmt	 2   peck2	  #Second or last peck (positive)

fmt	 2   peckclr	#Safety distance

fmt	 2   retr	   #Retract height

fmt  Q  2   shftdrl	#Fine bore tool shift

fmt  Z  2   zdrl	   #Depth of drill point

fmt  Z  2   tosz	   #Drilling top of stock

fmt  N  4   n_tap_thds #Number of threads per inch (tpi) / Pitch (mm)

fmt  F  2   pitch	   #Tap pitch (inches per thread)

fmt  R  2   refht_a	 #Reference height

fmt  R  2   refht_i	 #Reference height

fmt  S  4   drl_prm1	#Back Spot Facing Spinlde Speed

fmt  M  5   drl_prm2	#Back Spot Facing Spindle Direction

fmt  Z  2   drl_prm3	#Back Spot Facing Intinal Z depth to start Clearence postion

fmt  F  15  drl_prm4	#Back Spot Facing Feedrate

fmt  Z  2   drl_prm5	#Back Spot Facing Depth

fmt  Z  2   drl_prm6	#Back Spot Facing Retract Z place for moves between places

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

 

 

HTH

Link to comment
Share on other sites

Post is MPMaster for version 9

 

Code needs to be like this (very simple)

 

G0 X0. Y0.

G0 Z0.05

G1 Z-1. F20.

M91 OUT1 ;THIS IS CUSTOM LINE ONE

M90 OUT1 ;THIS IS CUSTOM LINE TWO

G0 Z0.05

 

This example would be without pecking just for clarity, and is obviously one hole only.

 

I'll take a look at doing a custom cycle tomorrow if everybody thinks that's the way to go.

 

Ron, is your example from a MPMaster post? Something pretty close anyway? I'm not a post wizard, but I can usually get most stuff done with a little time. I'll take a look.

 

Thanks,

 

Paul

Link to comment
Share on other sites
  • 17 years later...

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