Jump to content

Welcome to eMastercam

Register now to participate in the forums, access the download area, buy Mastercam training materials, post processors and more. This message will be removed once you have signed in.

Use your display name or email address to sign in:

Advise on cabs update issue


Recommended Posts

I put together a post that will let me use the dynamic rotation on my HMC but I am stumped on something. At the start of the tool path I have a pfcabs that will force out the B move based on a bit of logic. That part works fine but when it hits the pcabs (as well as the x y and z for that matter) it posts out the abs again even though I have a !cabs in my pfcabs. All of this is based on the mpmaster post from IHS. I did run the debug and stick a watch on my cabs. cabs and prv_cabs match as the post enters the pcabs block.  Here is a look at my code.

 

ptlchg_com
  		  if g115, "G115", pfxout, pfyout, pfcout, e$ 
		  else, [if not(index), pwcs], pfxout, pfyout, pfcout, e$ 
  
ptlchg0$  
  	  	  if g115, "G115", *sgcode, pfxout, pfyout, pfcout, pspindleout, e$ 
		  else, [if not(index), pwcs], *sgcode, pfxout, pfyout, pfcout, pspindleout, e$ 	



pfcout          #Force C axis output 
      if index = zero & rot_on_x,
        [
        if use_rotmcode & (fmtrnd(cabs) <> fmtrnd(prv_cabs) | sof), *sindx_mc
      if g115 & ((wcstype > one & workofs$ <> prv_workofs$) | (tlplnno$ <> last_tlplnno) | retractflg), [cpc=cabs, *cpc, !cabs, !cinc ]
	        else,
		    [
            if absinc$ = zero, *cabs, !cinc, !cout_i
            else, *cout_i, !cinc, !cabs
			]
        ]

pcout           #C axis output
      if index = zero & rot_on_x,
        [
        if use_rotmcode & fmtrnd(cabs) <> fmtrnd(prv_cabs), *sindx_mc
        if absinc$ = zero, cabs, !cinc, !cout_i
        else, cout_i, !cinc, !cabs
        ]

 Thanks in advance guys.

Link to comment
Share on other sites

I figured out the issue. Added a check to fix

pcout           #C axis output
      if index = zero & rot_on_x,
        [
        if use_rotmcode & fmtrnd(cabs) <> fmtrnd(prv_cabs), *sindx_mc
		if fmtrnd(cabs) <> fmtrnd(prv_cabs),
		  [
            if absinc$=0, cabs, !cinc, !cout_i
            else, cout_i, !cinc, !cabs
		  ]
        ]
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.

Join us!

eMastercam - your online source for all things Mastercam.

Together, we are the strongest Mastercam community on the web with over 56,000 members, and our online store offers a wide selection of training materials for all applications and skill levels.

Follow us

×
×
  • Create New...