584,865 active members*
5,058 visitors online*
Register for free
Login
IndustryArena Forum > Machine Controllers Software and Solutions > Fagor Automation > Fagor CNC 8040-T Subroutine P9998 Missing
Results 1 to 7 of 7
  1. #1
    Join Date
    Apr 2013
    Posts
    34

    Fagor CNC 8040-T Subroutine P9998 Missing

    Dear Boss,
    We are using a CNC machine. I am getting the alarm: 1057 undefined subroutine and Home search not done.

    As far I know one of our employee accidentally delete a sub routine program. From then these problem happen.

    All program in our machine start with a command P Call 9998 and end with P9999. But In Subroutine directory subroutine P9998 and P9999 is not available. So, the alarm displaying. Please see the photo.

    I got some other files in CARD A.

    Is it possible to restore the subroutine P9998 from Card A. Please see the photo of CARD A files.

    Or I am thinking in subroutine P9998 There may be a program of reference to home position. Like: G00 X0 Z0

    If I write the above program will it work?

    Or if you have a similar machine can you please give me code for P9998 and P9999?


    Attachment 245542

    Attachment 245544

    Attachment 245546

  2. #2
    9998 is a start subroutine for any conversational program and 9999 is the end subroutine.
    Write a program with following contents:

    (SUB 9998)
    (RET)
    (SUB 9999)
    M30
    (RET)

    these two subroutines are usually defined in program 999999.PIT. you may have the backup of this program in your CARD-A

  3. #3
    Join Date
    Apr 2013
    Posts
    34

    Re: Fagor CNC 8040-T Subroutine P9998 Missing

    Quote Originally Posted by FAMATechnology View Post
    9998 is a start subroutine for any conversational program and 9999 is the end subroutine.
    Write a program with following contents:

    (SUB 9998)
    (RET)
    (SUB 9999)
    M30
    (RET)

    these two subroutines are usually defined in program 999999.PIT. you may have the backup of this program in your CARD-A
    So, I will write this for subroutine program like below:

    subroutine 9998

    (SUB 9998)
    (RET)

    Subroutine 9999

    (SUB 9999)
    M30
    (RET)


    But how can I create a new subroutine from machine? Or I need to connect with WinDNC to create new subroutine.
    Thanks in advance.

  4. #4
    Edit a new program with any name and type these lines in.

  5. #5
    Join Date
    Apr 2013
    Posts
    34

    Re: Fagor CNC 8040-T Subroutine P9998 Missing

    Quote Originally Posted by FAMATechnology View Post
    Edit a new program with any name and type these lines in.
    Boss,
    Thanks a lot for your continuous help.

    I have changes a normal program and Written this line in a same program:
    (SUB 9998)
    (RET)
    (SUB 9999)
    M30
    (RET)

    So, I got 9998 and 9999 in subroutine directory. These newly created subroutine showing: P00005.
    But others subroutine showing: P????????

    See the image:
    Attachment 246006

    But when I try to reference the machine with Home search button same error display.
    CNC: 1057 Subroutine not defined. see the image

    Attachment 246008

    How can I restore the subroutine from Card A?
    I have a program P899999 in my CARD A directory saying OEM Subroutine.
    see the image: Attachment 245546

    I have tried to connect WinDNC with machine. But I didn't get the machine Model 8040-T in the software.


    Other than, I have a same machine in another place. So, how can I check the program inside subroutine from that machine. That machine is running.

  6. #6
    Join Date
    Apr 2013
    Posts
    34

    Re: Fagor CNC 8040-T Subroutine P9998 Missing

    Boss,
    I have solved the problem. I have restore the OEM subroutine program from CARD A.

    Now home search reference is OK.
    But when I try to run the machine on Automatic Mode then i am getting a new alarm: 40. please change gear to L

    I am not get anything information about this alarm. How can I solve the problem?

  7. #7
    Join Date
    Oct 2019
    Posts
    1
    Quote Originally Posted by kmarsus View Post
    Boss,
    I have solved the problem. I have restore the OEM subroutine program from CARD A.

    Now home search reference is OK.
    But when I try to run the machine on Automatic Mode then i am getting a new alarm: 40. please change gear to L

    I am not get anything information about this alarm. How can I solve the problem?

    I have a 8035t on the lathe I just bought and it's also missing the subroutines for the home search and tool changer, 1057 and 1079 subroutine not defined. I haven't been able to figure out home to restore these off of card A, could you possibly send a pick of these subprograms or what is in them, I've been struggling to find any info on how they are written, at a loss on what to do

Similar Threads

  1. Fagor 8040 Error DNC
    By Xavior in forum Fagor Automation
    Replies: 5
    Last Post: 07-20-2014, 07:34 PM
  2. Fagor 8040 Error DNC
    By Xavior in forum Fagor Automation
    Replies: 3
    Last Post: 03-19-2013, 09:27 PM
  3. Fagor 8040 Controller
    By cjels in forum Want To Buy...Need help!
    Replies: 3
    Last Post: 02-20-2009, 07:34 AM
  4. Fagor 8040 control
    By cjels in forum MetalWork Discussion
    Replies: 5
    Last Post: 07-15-2008, 12:46 PM
  5. Fagor 8040 Dxf Problem
    By Mert-G in forum CNC (Mill / Lathe) Control Software (NC)
    Replies: 4
    Last Post: 09-29-2007, 10:51 PM

Tags for this Thread

Posting Permissions

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