Hello Guest it is May 24, 2019, 11:33:56 AM

Author Topic: Problem with G42 cutter radius compensation  (Read 16420 times)

0 Members and 1 Guest are viewing this topic.

Offline BR549

*
  •  6,865 6,865
    • View Profile
Re: Problem with G42 cutter radius compensation
« Reply #10 on: December 21, 2013, 10:33:48 AM »
Ray , Mach4 " may " get close but Mach3 can be miles away from matching Smids examples.

Just a thought, (;-) TP

Offline ger21

*
  • *
  •  6,233 6,233
    • View Profile
    • The CNC Woodworker
Re: Problem with G42 cutter radius compensation
« Reply #11 on: December 21, 2013, 10:38:42 AM »
Gerry testing HERE from the MDI and GCODE program

G90 G90.1  switches to Abs IJ

G90 G91.1 switches to Inc IJ

(;-) TP



Try this

G90 G90.1

G91 G91.1

And you'll end up in G90 G91.1. Not what you're expecting.
Gerry

2010 Screenset
http://www.thecncwoodworker.com/2010.html

JointCAM Dovetail and Box Joint software
http://www.g-forcecnc.com/jointcam.html

Offline BR549

*
  •  6,865 6,865
    • View Profile
Re: Problem with G42 cutter radius compensation
« Reply #12 on: December 21, 2013, 06:41:11 PM »
AH BUT if you do it this way it works fine here

G91.1 G91

G90.1 G90


I say BUG, (;-) TP

Offline ger21

*
  • *
  •  6,233 6,233
    • View Profile
    • The CNC Woodworker
Re: Problem with G42 cutter radius compensation
« Reply #13 on: December 21, 2013, 07:06:15 PM »
No, it doesn't.
Do this:
G91.1
G91
G90.1 G90

You'll end up in G91.1 and G90.
It's not a bug. They are all in the same modal group, and when more than one are on the same line, only the last one on the line is read.
Gerry

2010 Screenset
http://www.thecncwoodworker.com/2010.html

JointCAM Dovetail and Box Joint software
http://www.g-forcecnc.com/jointcam.html

Offline BR549

*
  •  6,865 6,865
    • View Profile
Re: Problem with G42 cutter radius compensation
« Reply #14 on: December 21, 2013, 07:35:38 PM »
AH I see what you mean I was just looking at the mode indicators which are not complete .

 BUT it is still a bug as it SHOULD error IF it cannot complete the instruction as programmed.

(;-) TP
Re: Problem with G42 cutter radius compensation
« Reply #15 on: January 09, 2014, 07:48:54 PM »
I think the G20/21 is the preferred one rather than the G70/71.
Or at least that is the way I read it
"See also G20/G21 which are synonymous and preferred"

Hood
You are right. I had it back to front.
Re: Problem with G42 cutter radius compensation
« Reply #16 on: January 09, 2014, 09:07:23 PM »
Comp in Mach3 has several bugs. Based on your code, it appears that it doesn't like G92 (or G52)

I've been carefully reading the maual to see if I can make sense of this problem and maybe it's contained in the first paragraph regarding G92 Offsets.

           10.7.27    G92 Offsets - G92, G92.1, G92.2, G92.3  
           See the chapter on coordinate systems for full details. You are strongly advised not to use  
           this legacy feature on any axis where there is another offset applied.

Is it that because I used G92 to reset the origin values, and then applied G42, which is another offset, that the system throws a wobbly? It sounds like it is as rad. comp worked fine with BR529's program without G92.
It also would explain why tool length comp works without a problem in my original program as the Z axis was not offset.

If the above is the case then it's  a pretty big bug indeed.

You mentioned G52 although I didn't use it. As far as I can work out, G52 seems to be similar to G92 but uses relative values instead of absolute.

Is this right or have I misunderstood this?

I'll have to experiment with it to see if it is compatible with G41/42 codes although it's less convenient than using absolute values as with G92.

Maybe G42 will work with fixture offsets? (G54 - G59) There is a warning in the manual not to call these while cutter compensation is active but is silent regarding the reverse situation.

I take on board your comments regarding the state of Mach3.
They don't exactly make me very enthusiastic to part with money for what is apparently a legacy program.


Offline RICH

*
  • *
  •  7,332 7,332
    • View Profile
Re: Problem with G42 cutter radius compensation
« Reply #17 on: January 10, 2014, 07:10:42 AM »
Quote
You are strongly advised not to use  this legacy feature on any axis where there is another offset applied

Smid says the same  and in his book talks about about it but one must read a number of pages.  He suggests use of of G52 which replaced
the lagacy / old command. The G52 provides a local coordinate system  associated with the active work offset ( G5x).
So not sure it's realy a bug but rather one can create problems if not used correctly.

FWIW ......by an unsharpened tack  :) on gcode,

RICH
Re: Problem with G42 cutter radius compensation
« Reply #18 on: January 13, 2014, 04:17:42 AM »
I think I have kind of sorted out the radius compensation problem and the following may help others.


To sum up what I have learned - or think I have learned.

Radius compensation (G41, G42) will not work with either G92 or G52 active.
Both give the same result and that is, the cutter path goes berserk with rad. comp active.
 
G92 allows the resetting of the current position to new coordinate values.
G52 does more or less the same in a slightly different way.

There is a warning in the G92 section about not using other offsets in conjunction with it but there is no such warning for G52.
However, the manual does say, “G52 and G92 use common mechanisms in Mach3 and may not be used together.”

From these two statements it seems logical that if you can’t use rad.comp. with G92 then you can’t use it with G52 either and this is what I found.


What does work is using Work Offsets ( G54, G55, G56, G57, G58, G59).
The use of these doesn’t seem to upset rad. comp. and all works as you would expect.
There is a caution not to call a Work Offset code while rad. comp. is active but that’s not hard to avoid.

By entering the offset values for your machining reference point (part zero) into the Work Offsets table and calling the relevant code, you can offset the coordinate system to part zero.

By leaving Fixture #1 (G54) with all its axis values at zero, it can then be used to reset the coord. system back to the machine values.
 
The program below seems to work with rad. comp. without a problem and leaves the machine at the home position with all DRO’s reading zero.

Fixture #2 has the “part zero” X and Y offset values entered into it.
Fixture #1 effectively cancels the offsets, restoring the coordinate system to machine values.
In this case the Z offset is handled by cutter length compensation (G44) but it could be handled by the Work Offset function.
 
 
N10 (PROFILE PROGRAM USING FIXTURE OFFSETS)
N20 G90 G91.1 G20  (ABS, IJ RELATIVE, INCH PROGRAMMING)
N40 G55  (SET OFFSET TO FIXTURE #2)
N50 T1 M06  (CALL AND SET TOOL 1)
N110 G0 X6.000 Y1.200  (GOTO POSITION TO START PROFILE)
N120 G44 Z.100  M3 (LOWER TOOL, START SPINDLE)
N130 G01 Z-.200 F6 (MILL TO DEPTH)
N140 G42 Y.850 F60 (CUT TO SIDE WITH RAD COMP)
N150 X-.550 (CUT 1ST SIDE)
N160 Y.675 (CUT TO START OF 1ST ARC)
N180 G3 Y-.225 I0 J-.425 (CUT ARC)
N190 G01Y-.400 (CUT TO 2ND SIDE ALIGNMENT)
N200 X5.750 (CUT 2ND SIDE)
N210 Y-.225 (CUT TO START OF 2ND ARC)
N220 G3 Y.675 I0 J.425 (CUT 2ND ARC)
N230 G01 Y1.200 (CUT OUT TO SAFE POSN)
N240 G00 Z.050 M5 (LIFT CUTTER, TURN OFF SPINDLE)
N250 G40 G49 (CANCEL RAD AND LENGTH COMP)
N260 G54 (SET OFFSET TO FIXTURE #1=X0 Y0 Z0)
N270 G00 X0 Y0 Z0 (MOVE TO MC ZERO POSN)
N280 M30 (END, REWIND)

Thanks to all that have contributed.
Re: Problem with G42 cutter radius compensation
« Reply #19 on: January 27, 2014, 04:09:38 AM »
Further to my last - or what I though twas my last - post, I have spent a lot of time tryig to get cutter radius compensation (G42/G41) working reliably. I though that I had it sorted and that radcomp would work with fixture offsets (G54 ... G59).
Radcomp worked sometimes, but not others with the identical setting in the offset tables. It appears that there is some problem with registers or parameters not resetting the way they are supposed to. This is what I have noticed in some of the comments, that radcomp works, "Most of the time." and it does

There is a rather cryptic comment in the Mach3 G Code Ref document under the Work Offset Coodinate System section which says,
" It is an error if: One of the these G-Codes is used while cutter radius compensation is on."

This is a bit ambiguous but it seems, in the light of what Ii have experienced, that it's pointing to the fact that radcomp is incompatible with fixture (or work) offsets.

After many hours of experimentation, I have come to the conclusion that radcomp will not work in conjunction with ANY of the Mach3 offset functions.

I have found that the only way to use radcomp with Mach3  is to manually reset the DRO's to the origin (zero) point that you want to use and then it works perfectly.