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:

Please help!! Post issue with arc interpolation


Skyline
 Share

Recommended Posts

Hi

 

I'm trying to find where in the generic post MPFLAN.pst can I force out the R modifier or I,K for cir interoplation to 10^-7 places in Metric.

 

The issue I'm having is that the controller faults on lines of code not outputting R modifiers on cir interpolation moves to the 10^-7 decimal place. So my assumption is that MasterCAM is somehow rounding off the code and it's not exactly intersecting the endpoint of the arc, so the fix "I'm assuming" is forcing MasterCAM to output to the 10^-7 place on all R modifiers. My thought unless someone can please suggest anything different.

 

And yes the machine does hold displacement to that decimal value.

 

Thanks

Link to comment
Share on other sites

Gcode, yes I've tried I K and the same issue exists. I'm fairly confident MasterCAM is rounding off the numbers which is why it's giving me faults on some arc motions while not others and the difference I see between them is the decimal place. I could be wrong.

 

Also if anyone knows how I can force output of K modifiers when it's 0 might help.

 

Thanks.

Link to comment
Share on other sites

quote:

I'm fairly confident MasterCAM is rounding off the numbers

Of course it is, we are dealing with math here. wink.gif

Whenever you "shorten" the numeric representation of a value - rounding happens.

 

---------------

 

- Changing the output format -

 

The 'format' of a value is set using fs2 statements

and the application of the format statement is done with an fmt.

Note:

This 'application' can be altered elsewhere in a PST by using the 'newfs' command,

Which the MPLFAN.PST does in the parc postblock.

 

 

*** Always make a backup copy of nay PST that you are going to edit !!! ***

*** Always check the NC output "carefully" after making any change to a PST !!! ***

 

In the MPLFAN.PST the parc #Select the arc output

poostblock selects the format to be used (#2 or #3) based on several conditions.

 

We can see in this code snippet that format #3 & #3 is used for multiple items,

means if we change one it affects more than just the arc (center) output.

 

code:

fs2 2   0.4 0.3     #Decimal, absolute, 4/3 place

fs2 3 0.4 0.3d #Decimal, delta, 4/3 place

 

fmt X 2 xabs #X position output

fmt Y 2 yabs #Y position output

fmt Z 2 zabs #Z position output

 

fmt U 3 xinc #X position output

fmt V 3 yinc #Y position output

fmt W 3 zinc #Z position output

 

 

fmt I 3 iout #Arc center description in X

fmt J 3 jout #Arc center description in Y

fmt K 3 kout #Arc center description in Z

 

fmt R 2 arcrad$ #Arc Radius

So that you only affect the arc (center) outputs I would suggest this...

 

1> Create new fs2 for these letter addresses.

Find the section in the PST where the fs2 statements are declared and add (2) new ones

 

 

fs2 25 0.7 0.7 #Decimal, absolute, 7/7 place

fs2 26 0.7 0.7d #Decimal, delta, 7/7 place

 

2> Now you need to apply these.

Since we know the this PST overrides the 'fmt' statement for these arc outputs in parc,

we need to make our "apply this format" changes there.

 

 

3> Find the parc postblock

Alter these lines ->

 

 

*Original*

code:

        [

result = newfs(two, i$)

result = newfs(two, j$)

result = newfs(two, k$)

result = newfs(two, iout)

result = newfs(two, jout)

result = newfs(two, kout)

]

else,

[

result = newfs(three, i$)

result = newfs(three, j$)

result = newfs(three, k$)

result = newfs(three, iout)

result = newfs(three, jout)

result = newfs(three, kout)

]

*Altered*

 

In addition to the # changes, note the addition of the entries for -> arcrad$

which is output for the 'R'adius format type

and that in BOTH instances the # should be 25 !

 

code:

        [

result = newfs(25, arcrad$)

result = newfs(25, i$)

result = newfs(25, j$)

result = newfs(25, k$)

result = newfs(25, iout)

result = newfs(25, jout)

result = newfs(25, kout)

]

else,

[

result = newfs(25, arcrad$)

result = newfs(26, i$)

result = newfs(26, j$)

result = newfs(26, k$)

result = newfs(26, iout)

result = newfs(26, jout)

result = newfs(26, kout)

]

- Forcing I & K to always be output -

 

In the parc postblock, find this section of code ->

 

code:

   iout, kout, jout

!i$, !j$, !k$

Change it to (adding '*' in 2 places) ->

 

code:

   *iout, *kout, jout

!i$, !j$, !k$

!!! NOTE !!!

 

This last change is will cause "issues" if you are doing anything other than turning paths in the XZ axes.

 

There are (of course) other ways to force out these (2) letter addresses.

I've just given you the "quick and dirty" way so that you can see if any of this actually makes a difference out on the machine.

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...