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:

Toolpath Transform Mirror G-Code Output


Rob_V
 Share

Recommended Posts

Hi all,

I'm having an issue getting my G-code output to be what I want when using the mirror toolpath transform function. We do a lot of setups using double vises, where I need my WCS set the fixed jaw for both the front and back station. Trouble is, the fixed jaw is the back jaw in the front station, and the front jaw on the back station, so I need to mirror my toolpaths across the centerline of the vise. 

image.thumb.png.524023715cf31c75868c5d39b7595565.png

My mastercam file displays exactly what I want to do perfectly, but when I post my code out, I am getting the wrong coordinates for the mirrored toolpath. Basically, my G54 drilling points should be X.625 Y-.625 and X5.125 Y-.625, and my G55 points should have the Y flipped to be positive, so X.625 Y.625 and X5.125 Y.625. However, when I post the code, the G55 Y coordinate is 3.315, which is what it would be relative to my G54 origin point. The same is happening when I translate these toolpaths to a second vise.

image.thumb.png.dc07786f932a816fb9913ad775d4da9c.png

Now, I know I could just make separate toolpaths with distinct offsets for each station, but my goal is that if I have to change speeds/feeds etc. for an op I would like to only have to do it once instead of four times. I've been trying for hours to figure this out and it is driving me nuts..any help would be greatly appreciated.

 

PS this is my first time posting here so I hope all my formatting and whatnot is correct 🤞

double_vise_sample.zip

Link to comment
Share on other sites

Ok so I tried this, and it worked for the translate toolpath, but for the mirroring it flipped the X-coordinates instead of Y. Not sure why it would have done that, I'm wondering if it has something to do with this Mirror - G54 plane that it auto-created.

image.png.7080e79e8923c3ec779e38fd9bc74801.png

image.png.3a972cec023d661bb23ea86054c4093b.png

Link to comment
Share on other sites

I don't think that you're going to be able to get it to do what you're looking for that way.  You're other planes are just a visual aid at this point and not used for anything. When you mirror your path, it's using that original tool path plane which is why you're getting the wonky Y values.  If you're doing something this simple I would just program each part individually using the planes.

If you were doing something more complicated you could translate the toolpath up to the opposite side of the G55 part, then mirror that, and it should give you the correct numbers. 

I could be out in left field here but my head tells me that this isn't going to work.

Link to comment
Share on other sites

In the mastercam file when mirroring in also creates a new plane which is rotated around the Z-axis. This gives the mirrored values of the X and Y axis.

The only way I can come up with is:

1) Mirror operation around Y0 of operation

2) Ghost this operation before posting

3) Translate the mirrored operation the distance between the fixed faces in your example 2.69

4) Translate operation and last translate for G56 and G57

See also attached solution

Output code:

%
O0001(A-22863-2)
(DATE=DD-MM-YY - 29-06-23 TIME=HH:MM - 21:23)
(MCAM FILE - C:\USERS\JHM\DESKTOP\DOUBLE_VISE_SAMPLE.MCAM)
(NC FILE - C:\USERS\JHM\DOCUMENTS\MY MASTERCAM 2022\MASTERCAM\MILL\NC\A-22863-2.NC)
(MATERIAL - STEEL INCH - 1010 - 200 BHN)
( T1 | 3/4 X 90 CARBIDE SPOT DRILL | H1 )
G20
G0 G17 G40 G49 G80 G90
( SPOT DRILL )
T1 M6
G0 G90 G54 X.625 Y-.625 A0. S1300 M3
G43 H1 Z1.
Z.1
G99 G81 Z-.265 R.1 F20.
X5.125
G80
Z1.
( TRANSLATE FIXED DISTANCE OF JAWS )
( SPOT DRILL )
( MIRROR COöRDINATES )
G55 X.625 Y.625 Z1. A0.
Z.1
G99 G81 Z-.265 R.1 F20.
X5.125
G80
Z1.
( TRANSLATE FOR G56 AND G57 )
( SPOT DRILL )
G56 X.625 Y-.625 Z1. A0.
Z.1
G99 G81 Z-.265 R.1 F20.
X5.125
G80
Z1.
( SPOT DRILL )
( MIRROR COöRDINATES )
( TRANSLATE FIXED DISTANCE OF JAWS )
G57 X.625 Y.625 Z1. A0.
Z.1
G99 G81 Z-.265 R.1 F20.
X5.125
G80
Z1.
M5
G91 G28 Z0.
G28 X0. Y0. A0.
M30
%

 

double_vise_sample.mcam

Link to comment
Share on other sites

Ahh nice idea @Werktuigbouwer. I think this is essentially the same idea as what @neurosis said, using a combination of a mirror and a translation. Kind of a pain but seems to be the only way to do it.

I agree that on something this simple it would probably just be better to program them separately, but on a more complicated part with many toolpaths this is definitely something helpful for me. Sometimes we have 3 double vises running in a single setup for a total of 6 workstations, and the time can quickly add up when trying to tinker with parameters for 6 of the same toolpath.

Was hoping there would be a more "seamless" solution out there, but this is better than nothing. Appreciate the advice friends, I'm still fairly new to all this.

Link to comment
Share on other sites

Based on the help file it seems like it should be possible to do transform-translate, move the points where you want and have those points correspond to a WCS of your choosing. It doesn't want to seem to go though.

Rob, there's also another trick you could use in your situation. If you were to program that setup with 4 separate, but the same, toolpaths, you could highlight them all, right click, then go to edit selected operations menu and click edit common parameters. From there you can change a lot of the information in the parameters of all the operations provided you want all of those operations the same.

  • Thanks 1
  • Like 1
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...