588,231 active members*
4,225 visitors online*
Register for free
Login

Thread: Sub Looping

Results 1 to 9 of 9
  1. #1
    Join Date
    May 2006
    Posts
    7

    Sub Looping

    I Have a 97 puma 200 w/18t control. Doing a series fins (60) and I cant get the sub call to loop w/L count. It's been a while since I've been on a fanuc control. Only other lathe I have is a ML22 Milltronics. (Real Friendly) Now , I'm doing it the hard way with 60 sub calls useing a G50 Z0. at the begining of each Fin. Another problem is that I have to give it a G50 w/my final Z dim. when I'm done. Can't I use a secondary Ref. return when I pull out of my last sub call to true my Position back to true?
    Thanks, Murphy

  2. #2
    Join Date
    Jan 2006
    Posts
    40
    You should be able to use the G30 command but you will have to set parameter 1241 either manually in M.D.I. or in program if you have the G10/G11 option.
    Alan B

  3. #3
    Join Date
    Mar 2003
    Posts
    2932
    You might try M98 P1234567 where 123 is the number of repetitions, and 4567 is the subprogram number, i.e.:

    M98 P0502001

    Should run subprogram O2001 50 times.

    Dave

  4. #4
    Join Date
    Sep 2006
    Posts
    222
    Hmmmm..
    or is it
    M98P105020
    Calls program 1050 20 times?

  5. #5
    Join Date
    Jan 2006
    Posts
    10
    try CALL 1050 L20
    or M98 P1050 L20
    to call program 1050 20 times

  6. #6
    Join Date
    Feb 2004
    Posts
    45
    why not M97 P8000L59
    N8000 G10L2P1W-????

  7. #7
    Join Date
    Jun 2005
    Posts
    18

    Post offsets

    listen to metalmuncher.(nuts)

  8. #8
    Join Date
    Mar 2003
    Posts
    2932
    mtlmuncher: What's M97? I've used M97 on a Haas to call an internal sub, but I've never seen or used one on a Fanuc. The Daewoo M-code lists I've seen don't show M97 as having a function. Please enlighten me. Also, the standard format for the M98 sub call is Pnnnooooo (nnn=number of repetitions, ooooo=sub program number.) If murphyspost has his control configured for FS15 tape format (parameter #1 bit 1 = 1), then he can use the M98 Poooo Lnnnn to call sub "P" "L" times.

  9. #9
    Join Date
    Feb 2004
    Posts
    45

    M97

    M97 is an internal subroutine, and As it turns out it is not a standard option. It is on 0Tm but not 0Ti My bad I should have checked the standards for the control. However, the G10 is still workable with the M98 Subroutine. Another alternative, However, depending on the skill of the operator of the machine. Is to run G50 local coordinates for this job. The problem is, if you were not trained originally back in the dark ages like I was, the concept can be very scary. I would be happy to show you how, but It is not something that I think should be posted on this site. There are many concerns with this style of operation with lack of training.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •