CAD CAM EDM DRO - Yahoo Group Archive

Re: [CAD_CAM_EDM_DRO] Subroutine help

Posted by Smoke
on 2001-03-29 16:45:10 UTC
I'd use a looping routine and use G91 for indexing...there'd be a whole lot
less lines of code that way.

Smoke



>Hi, I am in the early stages of learing CNC
>programming and am hoping that someone can help me
>with a simple problem. I think that I know what I
>want to do, but I don't really know how to write it.
>
>A bit of description to help visualize my project:
>I am drilling holes and cutting slots into 1/8" tubing
>that I have clamped in a v-groove. I am making units
>1.5" long... leaving space for the clamp, they repeat
>every 1.75". Each unit will have a small mark to
>indicate where to cut the start and finish, which I
>plan to make by tapping the surface with a center
>drill. Each will have a #59 hole drilled through, and
>a 1/16" slot milled .5" along the middle.
>
>Because of the repeating units, I think that I want to
>use subroutines to accomplish this. For example, each
>unit requires 3 center drilling actions. Here is some
>of the code that I have written:
>
>G90 ;Absolute coordinates
>M25 ;Move head up to clear main clamp
>G00 x2.5 y0.5 Z0.4 ;move to start of first unit
>
>M03 S100 ;spindle on
>
>:Center Drill
>
>G91 ; incremental
>G81 X0.0 Y0.0 Z-0.1001 R-.3 F3 ;kiss top to mark start
>G81 x1.1 z-.12 r-.3 f3 ;center drill for #59 hole
>G81 X0.1 Y0.0 Z-0.1001 R-.3 F3 ;kiss top to mark end
>
>Since I need to repeat this whole cycle every 1.75", I
>would like to put these 3 lines into a subroutine and
>call them as a unit. Then I just need to move over
>0.55" from where one ends, and call the routine again.
>
>
>My question is: how do I do this? Do I just use an
>M99 call and then put the 3 lines at the bottom of the
>program and call them by line number? I know this is
>probably simple, but I would appreciate any
>assistance.
>
>Thanks,
>mike
>
>__________________________________________________
>Do You Yahoo!?
>Get email at your own domain with Yahoo! Mail.
>http://personal.mail.yahoo.com/?.refer=text
>
>Welcome to CAD_CAM_EDM_DRO@...,an unmoderated list for the
discussion of shop built systems, for CAD, CAM, EDM, and DRO.
>
>Addresses:
>Post message: CAD_CAM_EDM_DRO@yahoogroups.com
>Subscribe: CAD_CAM_EDM_DRO-subscribe@yahoogroups.com
>Unsubscribe: CAD_CAM_EDM_DRO-unsubscribe@yahoogroups.com
>List owner: CAD_CAM_EDM_DRO-owner@yahoogroups.com, wanliker@...
>Moderator: jmelson@... timg@... [Moderator]
>URL to this page: http://groups.yahoo.com/group/CAD_CAM_EDM_DRO
>bill,
>List Manager
>
>FAQ: http://www.ktmarketing.com/faq.html
>
>Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>

Discussion Thread

m o 2001-03-29 15:56:29 UTC Subroutine help Smoke 2001-03-29 16:45:10 UTC Re: [CAD_CAM_EDM_DRO] Subroutine help m o 2001-03-29 17:15:13 UTC Re: [CAD_CAM_EDM_DRO] Subroutine help Smoke 2001-03-29 19:49:14 UTC Re: [CAD_CAM_EDM_DRO] Subroutine help Jon Elson 2001-03-29 21:56:12 UTC Re: [CAD_CAM_EDM_DRO] Subroutine help m o 2001-03-30 08:34:41 UTC Re: [CAD_CAM_EDM_DRO] Subroutine help Smoke 2001-03-30 09:24:41 UTC Re: [CAD_CAM_EDM_DRO] Subroutine help