Page 1 of 2 12 LastLast
Results 1 to 12 of 16

Thread: Repeating programs without repeated 'start' presses

  1. #1
    Registered
    Join Date
    Feb 2005
    Location
    USA
    Posts
    143
    Downloads
    0
    Uploads
    0

    Repeating programs without repeated 'start' presses

    Hey guys this will be my last question for a while ! Learning a lot and making some good progress.

    -4, 88 legacy control, running in mode 1.

    When I have a program with subroutines, it takes some extra presses of the cycle start to repeat the program.

    I press start once at the M0 at the end of the program when the fixtures have been reloaded, then it needs two more presses to get the program restarted.

    Is there a way to just automatically repeat the program without pausing for additional pushes of the start button ? 3 pushes is a little much.

    Sample code below for the sake of discussion.

    TIA!



    O1234
    L100
    (*subroutine*)
    M17 (end sub)
    L200
    (*subroutine*)
    M17 (end sub)
    M30 (end of all subs)
    (*main*)
    M6T14 (load tool)
    S5000M3 (spin on)
    E1D14H14X0Y0Z5. (approach part)
    L101 (call first sub)
    L201 (call second sub)
    E0H0Z0X0Y7.5 (homes spindle, moves table to load/unload)
    M0 (pause for load / unload)
    M2 (program end)


  2. #2
    gar
    gar is offline
    Registered
    Join Date
    Mar 2005
    Location
    USA
    Posts
    1,498
    Downloads
    0
    Uploads
    0
    060221-1646 EST USA

    Shizzlemah:

    Do you have a GOTO capability. If so, then after your M00 put
    GOTO 100 (meaning your line 100).

    .


  3. #3
    Registered
    Join Date
    Feb 2005
    Location
    USA
    Posts
    143
    Downloads
    0
    Uploads
    0
    Ah the forest for the trees.

    Thanks gar that will do the trick nicely I'll stay quiet for a while now !!


  4. #4
    Mfg Engineer Scott_bob's Avatar
    Join Date
    Nov 2003
    Location
    United States
    Posts
    458
    Downloads
    0
    Uploads
    0
    Shizz,

    Since Fadal requires N#'s on every line, If you don't put them there they are included during DNC...
    We use Format II and at the bottom of the program, instead of M2 or M30:
    m99p1
    (For goto N1)

    Have you tried Format II...?

    Works well,
    Scott_bob


  • #5
    Registered
    Join Date
    Feb 2005
    Location
    USA
    Posts
    143
    Downloads
    0
    Uploads
    0
    I just used #: labels and they worked fine.

    I dont think that I could use a 'goto' while running DNC, but it's
    easy enough to loop it on the PC side.


  • #6
    Registered
    Join Date
    Feb 2005
    Location
    USA
    Posts
    143
    Downloads
    0
    Uploads
    0
    Havent tried format2 yet - let me just say I am building confidence with g-code for dummies (fmt1).

    kicking some butt, probing pieces & setting coords. probing after machining to adjust tool offsets, macros up the ying.

    perhaps it's time that I should look at format 2 - but Ive probably got 100 programs in format 1 so far. Hate to go back and edit them.


  • #7
    Registered Neal's Avatar
    Join Date
    Mar 2003
    Location
    Chatsworth, Ca
    Posts
    900
    Downloads
    0
    Uploads
    0
    Using the M99 P?? to line jump back to the line that you wish to begin on again is the correct solution. This will allow only one buttom push from the M0 code to get rolling again.
    Scott mentioned DNC, remember that in DNC you can NOT use subroutines. DNC can not look backwards in the program stream.

    Neal


  • #8
    Mfg Engineer Scott_bob's Avatar
    Join Date
    Nov 2003
    Location
    United States
    Posts
    458
    Downloads
    0
    Uploads
    0
    I meant Distributed Numerical Control (DNC)
    not Direct Numerical Control (DNC)
    When using RS232 communications, line numbers are automatically added...
    Scott_bob


  • #9
    Registered Neal's Avatar
    Join Date
    Mar 2003
    Location
    Chatsworth, Ca
    Posts
    900
    Downloads
    0
    Uploads
    0
    Scott--
    There in lies the problem with the industry using the same syntax to mean varying concepts. Unfortunatley caution must be exercised when using this type of terminology so as not to mis=direct the desired meanings.

    Neal


  • #10
    Registered
    Join Date
    Feb 2005
    Location
    USA
    Posts
    143
    Downloads
    0
    Uploads
    0
    Neal,
    what makes M99 Pxx more suitable than a #GOTO :xx ?

    At least with the goto I can use a taget name and not be dependant on line numbers not changing. Let's just say there may be some on the fly editing on the console !


  • #11
    Registered
    Join Date
    Jan 2006
    Location
    Riverside,CA
    Posts
    64
    Downloads
    0
    Uploads
    0
    What makes Format 1 "G code for dummies"? Other than compatability with Fanuc style programs what does Format 2 do that Format 1 wont?

    Dave


  • #12
    Registered
    Join Date
    Oct 2003
    Location
    usa
    Posts
    102
    Downloads
    0
    Uploads
    0

    maybe i'm confused

    O1234
    L100
    (*subroutine*)
    M17 (end sub)
    L200
    (*subroutine*)
    M17 (end sub)
    M30 (end of all subs)
    (*main*)
    M6T14 (load tool)
    S5000M3 (spin on)
    E1D14H14X0Y0Z5. (approach part)
    L101 (call first sub)
    L201 (call second sub)
    E0H0Z0X0Y7.5 (homes spindle, moves table to load/unload)
    M0 (pause for load / unload)
    M2 (program end)


    maybe i'm missing something here but wouldn't it only require 1 push of the button if you took out the M0 at the end of the program?

    the m2 is program end/rewind and the E0 line will bring the table to you to change the parts.
    so the table cycles out, the program ends, you load the parts and press start 1 time to run the program.

    i think you are making the extra press starts by adding the M0 at the end.
    i think without the M0 it will still stop and come to you because it is the end of the program.


  • Page 1 of 2 12 LastLast

    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.