Page 2 of 4 FirstFirst 1234 LastLast
Results 13 to 24 of 37

Thread: Needing method for creating duplicate parts

  1. #13
    Registered dcoupar's Avatar
    Join Date
    Mar 2003
    Location
    USA
    Posts
    2,499
    Downloads
    0
    Uploads
    0
    You're assuming Brian's machine has the User Macro option installed?


  2. #14
    Registered
    Join Date
    Feb 2007
    Location
    usa
    Posts
    118
    Downloads
    0
    Uploads
    0
    I was just working on a macro to do multiples with a g52 shift. It was gonna use IF statements and counters and would have been much longer. Dis stuff is sweet. A variation on gars in just one axis could be used on each tool instead of running the whole program and then shifting (Tim the tool man grunt here...).


  3. #15
    gar
    gar is offline
    Registered
    Join Date
    Mar 2005
    Location
    USA
    Posts
    1,498
    Downloads
    0
    Uploads
    0
    070825-1635 EST USA

    davek:

    In general I tend to use the IF THEN approach. There are some advantages for restart at an arbitrary point.

    If you have multiple tools in the program, which is the usual case, then you want to write the program with a subroutine for each tool. Let these subroutines be N1000, N1100, etc.

    Create a main program

    %
    O6666 (looping program for matrix of M by N)

    #510 = 1.25 (X increment between parts)
    #511 = 0.75 (Y increment between parts)

    #512 = 5 (number of parts in X direction)
    #513 = 10 (number of parts in Y direction)


    G54
    (other startup stuff )

    (first tool change stuff)
    #520 = 1000 (first machining subroutine)
    G97 P500 (call the looping program that in turn calls N1000)

    (second tool change stuff)
    #520 = 1100 (second machining subroutine)
    G97 P500 (call looping, and in turn it calls N1100)

    (and so on.)

    M30




    N500

    #500 = 0 (X location relative to G54, initialized to 0)
    #501 = 0 (Y location relative to G54, initialized to 0)

    WHILE [#501 LT #512] DO2
    G52 Y-#501

    WHILE [#500 LT #513] DO1
    G52 X#500
    G97 P#520 (Subroutine call to your BobCad program for one tool to keep clutter out of these loops)
    #500 = #500 + #510
    END1

    #500 = 0
    #501 = #501 + #511
    END2

    M99

    N1000
    ....
    M99

    N1100
    ....
    M99

    %

    There maybe times when you use the same subroutine but with different tools. For example --- roughing, finish, and chamfer.

    .


  4. #16
    Registered
    Join Date
    Jul 2005
    Location
    Canada
    Posts
    11,960
    Downloads
    0
    Uploads
    0
    Quote Originally Posted by gar View Post
    070825-1635 EST USA

    ......If you have multiple tools in the program, which is the usual case, then you want to write the program with a subroutine for each tool. Let these subroutines be N1000, N1100, etc.....
    Just a minor point but it can catch errors.

    Number the subroutine to match the tool; T1 - N1000, T2 - N2000, etc., and then if your subroutine has a subroutine it becomes N1100, N2100, etc.

    Also if you are using Tool Comp your 'D's match the first digit in the line numbers; N1000 - D01, etc.
    An open mind is a virtue...so long as all the common sense has not leaked out.


  • #17
    gar
    gar is offline
    Registered
    Join Date
    Mar 2005
    Location
    USA
    Posts
    1,498
    Downloads
    0
    Uploads
    0
    070825-1952 EST USA

    Geof:

    Good suggestion.

    .


  • #18
    Registered
    Join Date
    Feb 2007
    Location
    usa
    Posts
    118
    Downloads
    0
    Uploads
    0
    Can you use a GOTO (or an IFTHEN) to jump back into a DOWHILE, as in this?


    O0555
    #101 = 2. (CLEARANCE)
    #102 = 1. (REMOVAL)
    #103 = .03 (DEPTH OF CUT)
    #104 = .375 (CENTER OF PART
    #105 = 9. (LENGTH OF PART)
    #106 = 1500. (RPM)
    #107 = 30. (FEED)
    G90
    T84
    M6
    M03 S#106
    G55 G0 X-1.5 Y#104
    G55 G0 G90 Z#101 G43 H84
    WHILE[#102GT0]DO1
    N1G00 Z[#102+.4]
    G55 G0 X-1.5 Y#104
    G00 Z#102
    G01 X [#105+1.5] F#107
    IF[#102EQ0]GOTO2
    #102 = [#102-#103]
    END1
    #102=0
    GOTO1
    N2
    G28 G91 Z0
    M09
    M05
    G90 G53 X-15. Y0
    M30



    to face a part down the center with multiple passes. I'm assuming the DOWHILE checks the variable at the beginning of it.


    Youse guys are awesome.


  • #19
    Registered
    Join Date
    Aug 2005
    Location
    USA
    Posts
    1,622
    Downloads
    0
    Uploads
    0
    This thread is proving to show that while simple gets the job done, it does not add to your experience or efficiency where it pays to have other options and the knowledge to implement it.

    One note of precaution I have learned in parametric programming is when using IF/Then statements of GE, LE, EQ and finding floating decimal point errors combined with variables and math functions to calculate X,Y, Z moves. Your logic may not agree with the binary logic. This can lead to another loop through a program outside of the expected envelope with unintended results. Whole number integers will not have this problem.

    DC
    Learn cause and effect through experience. Mastering those relationships is the "Common Sense" ability within the art of any trade.


  • #20
    Registered
    Join Date
    Jul 2005
    Location
    Canada
    Posts
    11,960
    Downloads
    0
    Uploads
    0
    Quote Originally Posted by One of Many View Post
    This thread is proving to show that while simple gets the job done, it does not add to your experience or efficiency where it pays to have other options and the knowledge to implement it.....DC

    I think someone just took at dig at simple old me .
    An open mind is a virtue...so long as all the common sense has not leaked out.


  • #21
    Registered
    Join Date
    Aug 2005
    Location
    USA
    Posts
    1,622
    Downloads
    0
    Uploads
    0
    Quote Originally Posted by Geof View Post
    a dig at simple.
    Wow, I didn't see that coming....twasn't my intention, but don't you fret, you have regained the center of attention!

    DC
    Learn cause and effect through experience. Mastering those relationships is the "Common Sense" ability within the art of any trade.


  • #22
    Registered
    Join Date
    Jul 2005
    Location
    Canada
    Posts
    11,960
    Downloads
    0
    Uploads
    0
    Quote Originally Posted by One of Many View Post
    .... but don't you fret, you have regained the center of attention!

    DC
    You mean I briefly lost it . Horrors; I am mortified.
    An open mind is a virtue...so long as all the common sense has not leaked out.


  • #23
    Registered
    Join Date
    Jul 2005
    Location
    Canada
    Posts
    11,960
    Downloads
    0
    Uploads
    0
    Double post deleted
    Last edited by Geof; 08-26-2007 at 06:54 PM.
    An open mind is a virtue...so long as all the common sense has not leaked out.


  • #24
    Registered
    Join Date
    Aug 2005
    Location
    USA
    Posts
    1,622
    Downloads
    0
    Uploads
    0
    Quote Originally Posted by Geof View Post
    You mean I briefly lost it . Horrors; I am mortified.
    It was the hyper-sensative paranoia in your "Dig" response that indicated there might be a chance you felt the loss of it, real or imagined.

    I think I've heard it refered to as "It's all about me" syndrome!

    DC
    Learn cause and effect through experience. Mastering those relationships is the "Common Sense" ability within the art of any trade.


  • Page 2 of 4 FirstFirst 1234 LastLast

    Similar Threads

    1. MOST precise method of maching SMALL parts?
      By SRT Mike in forum General Metalwork Discussion
      Replies: 2
      Last Post: 12-02-2006, 10:58 PM
    2. need duplicate cylinder made
      By blasterboy1980 in forum Casting Metals
      Replies: 0
      Last Post: 10-29-2006, 09:21 PM

    Posting Permissions


     


    About CNCzone.com

      We are the largest and most active discussion forum from DIY CNC Machines to the Cad/Cam software to run them. The site is 100% free to join and use, so join today!

    Follow us on

    Facebook Dribbble RSS Feed


    Search Engine Friendly URLs by vBSEO ©2011, Crawlability, Inc.