Page 1 of 3 123 LastLast
Results 1 to 12 of 31

Thread: Help stop mastercam returning to home at 0 at end of job.

  1. #1
    Registered
    Join Date
    Sep 2010
    Location
    Australia
    Posts
    10
    Downloads
    0
    Uploads
    0

    Unhappy Help stop mastercam returning to home at 0 at end of job.

    Hello People,

    Could someone tell me how to get mastercam to stop adding gcode to the end of my job that sends the tool to the reference point at 0 and marking my work.

    Mastercam x3
    CNC mill

    Cheers

    Matt


  2. #2
    Registered Superman's Avatar
    Join Date
    Dec 2008
    Location
    Krypton
    Posts
    1,769
    Downloads
    0
    Uploads
    0
    Matt,
    More info is needed
    What generic post ?
    for what machine and control ?

    There can be multiple solutions for what you put up
    but, try looking at the settings in Misc Intergers before any post editing
    at the G30/G28 behaviour and the settings you have for Misc Interger#1


  3. #3
    Registered
    Join Date
    Sep 2010
    Location
    Australia
    Posts
    10
    Downloads
    0
    Uploads
    0
    Sure sorry about that making a few assumptions that people know whats going on around me.

    I have a generic mill (half chinese half home made) using mach3 and a Geckodrive G540.
    I have modified the default generic fanuc 3x mill. So I am using the Generic Fanuc 3X mill.pst

    Thanks for your time.

    Matt.


  4. #4
    Registered Superman's Avatar
    Join Date
    Dec 2008
    Location
    Krypton
    Posts
    1,769
    Downloads
    0
    Uploads
    0
    I suggest that you open your post with any text editor, NOTEPAD or CIMCO

    And read the top "Notes" section in regards to "Work offsets:" and the number you put in at MI#1 AND the number you put in as the work offset # in the "view manager"
    If you want to use G54,G55 etc ---then MI#1 should be =2
    and the number you set in the view manager would be 0 for G54, 1 for G55 and so on.

    when you have this area sorted, then mod the post if required

    The area you want, is marked in RED
    or comment the bad one out and hard code what you need in it's place. ie n$, "G0 Z100.", e$
    Code:
    peof$            #End of file for non-zero tool           
          pretract
          if lock_codes = one & rot_on_x, pbld, n$, *sunlock, sunlockcomm, e$
          rotretflg = 1
        #  pbld, n$, *sg28, "X0.", "Y0.", protretinc, e$
      pbld, n$, *sg28, "Y0.", protretinc, e$
          rotretflg = 0
          if lock_codes = one & rot_on_x, pbld, n$, *slock, slockcomm, e$
          comment$
          if not(index), n$, *sg90, e$
          n$, "M30", e$
          mergesub$
          clearsub$
          mergeaux$
          clearaux$
          "%", e$


  • #5
    Registered
    Join Date
    Sep 2010
    Location
    Australia
    Posts
    10
    Downloads
    0
    Uploads
    0
    Cheers Ill give it a go.

    Matt


  • #6
    Registered
    Join Date
    May 2007
    Location
    canada
    Posts
    71
    Downloads
    0
    Uploads
    0
    thanks


  • #7
    Registered
    Join Date
    Aug 2010
    Location
    USA
    Posts
    97
    Downloads
    0
    Uploads
    0
    I'm having the same issue. I've gotten in the habit of adding a "move to point" toolpath at the end of my programs, then deleting the extra lines of code that send the part to the back of the machine. We're using the generic fanuc 3x mill post on a Hurco VM1.

    I have a little experience with coding, but I'm not catching your drift on what needs to be changed to keep it from going to the machine's home position at the end of a program (I'd still like it to go to the machine's home position during tool changes though, but I think that's a setting we've adjusted in the mill itself right now).

    On a side note, I've been playing around with the posts, so I saved a copy of the generic post and re-named it so I'd still have the original to revert back to. When I run a program through that re-named post, the code comes out without spacing. With the original there's spacing and it's easy to read. What happened? I didn't change anything in the post, just re-named a copy of it. Looks like the line numbering is different too.

    Here's an example of what the output looks like from the re-named one:
    N140G43H8Z.35
    N150Z.1
    N160G1Z.0187F6.42
    N170Y-2.3037Z-.0813F30.

    And the same line from the original:
    N108 G43 H8 Z.35
    N110 Z.1
    N112 G1 Z.0187 F6.42
    N114 Y-2.3037 Z-.0813 F30.

    Thanks for any help


  • #8
    Registered
    Join Date
    Oct 2010
    Location
    Usa
    Posts
    38
    Downloads
    0
    Uploads
    0
    Look for "end of file non tool zero". If it has a g28 in a line put a # in front of the line. Only do this in the section between end of file non tool zero & m30. Nowhere else in the post. Then in the next line after you put the #, & put in the code that you want to be there like superman showed you. Like. n$, "GO Z25.", e$ or what ever you want that number to be. Then you could do the same with X & Y.

    As far as the spacing goes are you using the same md & cd that you were using before? I know that there's some switches in there that can control your line # & spacing output. If that's not it then I'm not sure offhand. I don't have a post in front of me right now. Hth


  • #9
    Registered Superman's Avatar
    Join Date
    Dec 2008
    Location
    Krypton
    Posts
    1,769
    Downloads
    0
    Uploads
    0
    For the change in the spaces,
    open the original file and the modified one using Cimco, then do a file compare
    This will highlight any differences. If you can't find the problem, start again from the original post

    You should be looking for a missing $ or a , (comma) or a character that may have been deleted

    To understand how a post works, the general order it "thinks" is:
    upper area defines your machine, creates a place to place info ( strings) and sets a default value in these strings, then it runs thru in this general order
    1-header
    2-SOF ( start of file )
    3-toolchange ( or ptlchg_com )
    4-1st op
    5- next op --> if new tool ( do #3)--> if same tool ( do ptlchg0$ )
    6- EOF ( end of file )

    every step is a branch point away to do an item, then return to the main body and do the next step
    ie pwcs in the main stream is calling a "macro" to look at your settings and how you define your work origin, and then apply the correct code sequence when you post.


  • #10
    Registered
    Join Date
    Aug 2010
    Location
    USA
    Posts
    97
    Downloads
    0
    Uploads
    0
    Quote Originally Posted by Superman View Post
    For the change in the spaces,
    open the original file and the modified one using Cimco, then do a file compare
    This will highlight any differences. If you can't find the problem, start again from the original post

    You should be looking for a missing $ or a , (comma) or a character that may have been deleted

    To understand how a post works, the general order it "thinks" is:
    upper area defines your machine, creates a place to place info ( strings) and sets a default value in these strings, then it runs thru in this general order
    1-header
    2-SOF ( start of file )
    3-toolchange ( or ptlchg_com )
    4-1st op
    5- next op --> if new tool ( do #3)--> if same tool ( do ptlchg0$ )
    6- EOF ( end of file )

    every step is a branch point away to do an item, then return to the main body and do the next step
    ie pwcs in the main stream is calling a "macro" to look at your settings and how you define your work origin, and then apply the correct code sequence when you post.
    something must have gotten deleted yesterday, but I'm not sure how considering I had just done a "save as" from the original post, and renamed it. Looks like the spaces are gone now.

    Hopefully I'll get some time to look into the post and find the move to zero part


  • #11
    Registered
    Join Date
    Aug 2010
    Location
    USA
    Posts
    97
    Downloads
    0
    Uploads
    0
    Quote Originally Posted by Superman View Post
    For the change in the spaces,
    open the original file and the modified one using Cimco, then do a file compare
    This will highlight any differences. If you can't find the problem, start again from the original post

    You should be looking for a missing $ or a , (comma) or a character that may have been deleted

    To understand how a post works, the general order it "thinks" is:
    upper area defines your machine, creates a place to place info ( strings) and sets a default value in these strings, then it runs thru in this general order
    1-header
    2-SOF ( start of file )
    3-toolchange ( or ptlchg_com )
    4-1st op
    5- next op --> if new tool ( do #3)--> if same tool ( do ptlchg0$ )
    6- EOF ( end of file )

    every step is a branch point away to do an item, then return to the main body and do the next step
    ie pwcs in the main stream is calling a "macro" to look at your settings and how you define your work origin, and then apply the correct code sequence when you post.
    odd, I just tried it again. There's no difference between the posts when comparing, and yet the re-named one comes out with no spaces. Is it something to do with the control file? I really am lost here, doesn't help that it's Friday :P

    EDIT: Found the issue with the spacing. A setting in the control definition in mastercam, under NC Output, it had changed the spaces between NC addresses to 0, when it should have been 1, so that's fixed.

    And I'm still unable to find the point where it tells it to go to the home position. The part you posted earlier is completely different from what I have, so I'm not sure what to change.

    peof0$ #End of file for tool zero
    peof$

    peof$ #End of file for non-zero tool
    pretract
    comment$
    if stagetool = 1 & stagetltype = 2, pbld, n$, *first_tool$, e$
    n$, "M30", e$
    mergesub$
    clearsub$
    mergeaux$
    clearaux$
    "%", e$
    Last edited by mafitch7479; 10-08-2010 at 12:11 PM.


  • #12
    Registered Superman's Avatar
    Join Date
    Dec 2008
    Location
    Krypton
    Posts
    1,769
    Downloads
    0
    Uploads
    0
    Quote Originally Posted by mafitch7479 View Post
    And I'm still unable to find the point where it tells it to go to the home position. The part you posted earlier is completely different from what I have, so I'm not sure what to change.
    The blue lines you need are missing, this example is called hard coding ( what is in quotes is posted into the NC file, ad-hoc. )
    Code:
    peof$ #End of file for non-zero tool 
         pretract
         comment$
         n$, "G0 Z10.", e$       # retract to Z home
         n$, "G0 X-10. Y10.", e$   # move spindle to rear
         if stagetool = 1 & stagetltype = 2, pbld, n$, *first_tool$, e$
         n$, "M30", e$
         mergesub$
         clearsub$
         mergeaux$
         clearaux$
         "%", e$
    some machines use a G28, so the blue lines could be replaced with
    n$, *sg28, "Z0.", e$
    n$, *sg28, "X0. Y0.", protretinc, e$

    Protretinc is a post-block that should make the 4th axis return to zero ---if turned ON and used.
    Using a machine code is better as it uses the machines' co-ord system for the values and it doesn't rely on the part's origin.
    Last edited by Superman; 10-08-2010 at 09:49 PM. Reason: forgot the seq #'s


  • Page 1 of 3 123 LastLast

    Similar Threads

    1. Mach3 axis not returning to home
      By saltybugger in forum Machines running Mach Software
      Replies: 20
      Last Post: 01-18-2010, 12:57 PM
    2. Stop Z from going home
      By DareBee in forum Fadal
      Replies: 17
      Last Post: 11-25-2009, 03:37 PM
    3. Replies: 0
      Last Post: 12-12-2007, 06:05 AM
    4. home, limit, e-stop
      By drafterman in forum General Waterjet
      Replies: 11
      Last Post: 04-12-2007, 06:46 AM
    5. Limit, Home and E Stop Switches
      By Mr.Chips in forum General Electronics Discussion
      Replies: 15
      Last Post: 01-17-2007, 10:02 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.