Results 1 to 7 of 7

Thread: Editing FANUC GPP File

  1. #1
    Registered
    Join Date
    May 2008
    Location
    England
    Posts
    26
    Downloads
    0
    Uploads
    0

    Editing FANUC GPP File

    Can anyone help with editing the std Fanuc gpp file. I notice that the tool change does not pre-select the next tool. There are parameters for
    Next_Tool_Type but what format do you need to have this in to make it work?


  2. #2
    Registered
    Join Date
    Oct 2007
    Location
    United Kingdom
    Posts
    442
    Downloads
    0
    Uploads
    0
    Quote Originally Posted by almo0797 View Post
    Can anyone help with editing the std Fanuc gpp file. I notice that the tool change does not pre-select the next tool. There are parameters for
    Next_Tool_Type but what format do you need to have this in to make it work?
    It all depends where you want the next tool call to appear. For instance, if you want the tool call to be in the same line as the first rapid move then you have to add {"T"next_tool"} to the code in @rapid. However, if you do that as it stands you will get the call on every rapid line - not what you want I imagine. So you have to make it conditional asnd that involves setting up some global variables, setting them at tool change and clearing them after the first rapid move.

    Download the GPP users manual from the SolidCAM website, you will find it invaluable.

    Happy Christmas

    Bob


  3. #3
    Registered
    Join Date
    May 2008
    Location
    England
    Posts
    26
    Downloads
    0
    Uploads
    0

    Fanuc PP

    Bob

    Thanks for the reply and a happy New Year to you. The example of a global variable is not very clear to me in the help files. Is it stated at the top of the file? And if so what is the correct format.


  4. #4
    Registered
    Join Date
    Oct 2007
    Location
    United Kingdom
    Posts
    442
    Downloads
    0
    Uploads
    0
    Quote Originally Posted by almo0797 View Post
    Bob

    Thanks for the reply and a happy New Year to you. The example of a global variable is not very clear to me in the help files. Is it stated at the top of the file? And if so what is the correct format.
    And a Happy new year to you too. Right, global variables are declared at the top of the GPP file like so

    @init_post
    ;Declare variables
    global logical first_rapid
    global .....

    The manual covers it in the Variables chapter.

    From memory, what you want is to (a) create a global logical (boolean) variable called "first_rapid" or some such. (b) set this variable to true at the end of @change_tool (c) add to @rapid_move the calls that you want with

    if first_rapid eq true
    {"T" next_tool}
    endif

    Then (d) at the end of @rapid_move set first_rapid to false.

    The above should then add a tool call to the first rapid move after tool change. You might find that some of this is already there if your post calls an M3 in the first rapid move.

    All the best


  • #5
    Registered
    Join Date
    May 2008
    Location
    England
    Posts
    26
    Downloads
    0
    Uploads
    0

    Next Tool Call

    Bob

    I've come up with a solution for next tool call. After the line
    {nb, 'M6 T'tool_number} add {nb, 'T'next_tool_number} this seems to work okay except for programs with only 1 tool as it calls the the selected tool as the next tool.
    ie:
    M6 T1
    T1
    Is it possible to use logic in this line such as if 'T'next_tool_number does not equal T'tool_number 'T'next_tool_number. I can see you can use the symbol =
    but I cannot see a method of stating not equal


  • #6
    Registered
    Join Date
    Oct 2007
    Location
    United Kingdom
    Posts
    442
    Downloads
    0
    Uploads
    0
    Quote Originally Posted by almo0797 View Post
    Bob

    I've come up with a solution for next tool call. After the line
    {nb, 'M6 T'tool_number} add {nb, 'T'next_tool_number} this seems to work okay except for programs with only 1 tool as it calls the the selected tool as the next tool.
    ie:
    M6 T1
    T1
    Is it possible to use logic in this line such as if 'T'next_tool_number does not equal T'tool_number 'T'next_tool_number. I can see you can use the symbol =
    but I cannot see a method of stating not equal
    That looks good. I must confess my Fanuc post processors date back to SolidCAM R10 and some of the variables now present in the CAM output weren't available then.

    "Not Equal" can be expressed in two ways either "ne" or the mathmatical "<>" as shown thus
    if next_tool_number ne tool_number
    or
    if next_tool_number <> tool_number

    There is also the NOT logical operator, but I haven't used that one very much and therefore I am not confident in its correct usage.


  • #7
    Registered
    Join Date
    Oct 2004
    Location
    NEW ZEALAND
    Posts
    39
    Downloads
    0
    Uploads
    0
    You are on the right track
    I have added the following to my post to get this working

    if tool_number ne next_tool_number then
    {nb,'T'next_tool_number,' ( Next Tool )'}
    endif

    Regards

    Jake T-B


  • Similar Threads

    1. Need Help!- Need file Fanuc 18Mc Nc-basic
      By Selimsalim in forum Fanuc
      Replies: 4
      Last Post: 02-25-2009, 12:00 AM
    2. Need Help!- EDITING WITH FANUC LADDER III
      By CHAD LAWSON in forum Fanuc
      Replies: 2
      Last Post: 01-30-2009, 07:36 AM
    3. Need Help!- SAVE FANUC 21i NC FILE TO CARD READER
      By Bigbill in forum Fanuc
      Replies: 3
      Last Post: 02-01-2008, 03:05 PM
    4. file retrieval on fanuc control
      By Bigbill in forum Daewoo/Doosan
      Replies: 5
      Last Post: 11-01-2006, 04:19 PM
    5. Fanuc ladder editing card
      By bob1371 in forum Fanuc
      Replies: 1
      Last Post: 04-10-2006, 11:50 AM

    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.