Hello Guest it is April 17, 2024, 08:07:58 PM

Author Topic: G41 giving me weird offsets  (Read 4729 times)

0 Members and 1 Guest are viewing this topic.

G41 giving me weird offsets
« on: November 27, 2013, 07:52:14 PM »
I am running a simple program to cut a step.  since I am ganging parts in together in the vise I want to take the cut very lightly.  I also have an overall condition where I always have to make adjustments before or after a program to get things within .001".  So I can't just put in cutter comp and go all the way araound teh part and call it don.  I have to do the right check and then adjust and redo.  Then I do the left adjust and redo.  If I was to go around the right would be too big and the left too small of a step.  I know what is wrong right now, just don't have the moolah yet to get better components.  So In this case I will adjust after the cycle and give a light finish pass to bring everything within .001.  

here is the problem.   In this program instead of making a X move and then increasing my radial DOC with Y and then going back to the start X position and then  adjusting Radial DOC with Y again.  I am going in a Z like motion.  Moves are a combination of X and Y.  I am trying to use G41 so the cutter is compensated.  My problem is that during the first move which is a straight line (N60)without any Y movement, towarsd the end of that path, cutter comp sends the cutter to the other side of the path ( I wiped out 7 blanks like that).  Then N70-N100 does all kinds of weird compensating.  


(Tool 3/8” 3Fl Carbide)
N10   G20 G17 G90 G54 S6000    F32
N20   G0 Z0 X0 Y0
N30      Z-.325            M3  M8  
N40      X-.072 Y.1505
N50   G1 G41 X.305  Y-.2245 P.1875
N60      X5.195
N70      X.0835 Y-.2615
N80      X5.195 Y-.2985
N90      X.0336 Y-.335      
N100     X5.5            F28
N110  G40
N120  G0  Z0
N130      X0 Y0 M5 M9 M30
N100     X5.5            F28
N110  G40
N120  G0  Z0
N130      X0 Y0 M5 M9 M30
  
I Just want this thing to compensate for the cutter that is between the edge of the workpiece and the column.  I want this to work whether I am going in positive X direction or negative X direction.  I tried

N10   G20 G17 G90 G54 S6000    F32
N20   G0 Z0 X0 Y0
N30      Z-.325            M3  M8  
N40      X-.072 Y.1505
N50   G1 G41 X.305  Y-.2245 P.1875
N60      G42X5.195
N70      G41X.0835 Y-.2615
N80      G42X5.195 Y-.2985
N90      G41X.0336 Y-.335      
N100     G42X5.5            F28
N110  G40
N120  G0  Z0
N130      X0 Y0 M5 M9 M30

But what happened was that there was in effect no cutter comp as when running under single block I can see that my Y position DRO was the same as the G code block  commanded Y position ???

Anybody see what is wrong with my programming.  I have been away from the machine for a month and I am back to asking simple questions.    
« Last Edit: November 27, 2013, 07:57:15 PM by Mountainman »

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: G41 giving me weird offsets
« Reply #1 on: November 27, 2013, 09:16:33 PM »
"Then N70-N100 does all kinds of weird compensating.   "

(;-) I bet it does. You cannot just flip flop tool comp around like that, at the end of each comp move you have to lead out  to remove the comp then leadin to apply the next comp otherwise Mach3 will TRY to make the comp work but cannot and you get strange stuff as a toolpath.

(;-) TP
Re: G41 giving me weird offsets
« Reply #2 on: November 27, 2013, 09:47:05 PM »
"Then N70-N100 does all kinds of weird compensating.   "

(;-) I bet it does. You cannot just flip flop tool comp around like that, at the end of each comp move you have to lead out  to remove the comp then leadin to apply the next comp otherwise Mach3 will TRY to make the comp work but cannot and you get strange stuff as a toolpath.

(;-) TP

How about line N60.  when that is teh only line with G41 in it.  Half way to the end of that block the tool tries to compensate on teh other end of teh path and just moves .375" into the part? 

when I change direction that teh table moves I also have to change from G41 to G42? 

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: G41 giving me weird offsets
« Reply #3 on: November 28, 2013, 12:36:18 AM »
Well the P is not global so most use the tool # reference(Dxx) and in this case there is NONE so Mach3 uses the last known tool# in which in this case there is NONE so it uses NO COMP at all.

Looking at the code I have no idea what you are trying to do so I cannot be of much help to recode it correctly.

(;-)TP
Re: G41 giving me weird offsets
« Reply #4 on: November 28, 2013, 08:21:44 AM »
Basically what I want is when looking from the right side of the X axis for the cutter to be to the right of the line being commanded in the blocks.  At this point I am thinking of getting rid of cutter comp completely.  I have used P plenty of times to maintain an offset value.  I don't have a tool library.   

Offline ger21

*
  • *
  •  6,295 6,295
    • View Profile
    • The CNC Woodworker
Re: G41 giving me weird offsets
« Reply #5 on: November 28, 2013, 09:32:17 AM »
When you change direction, you need to turn of comp with G40 and have a leadout move. Then, do a lead in move and turn it back on. When you reverse again, you need to repeat this process.
Gerry

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

JointCAM Dovetail and Box Joint software
http://www.g-forcecnc.com/jointcam.html
Re: G41 giving me weird offsets
« Reply #6 on: November 28, 2013, 10:10:20 AM »
When you change direction, you need to turn of comp with G40 and have a leadout move. Then, do a lead in move and turn it back on. When you reverse again, you need to repeat this process.

OK, that makes sense 

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: G41 giving me weird offsets
« Reply #7 on: December 06, 2013, 10:20:35 PM »
Another thing to NOTE is a G41/42 call without the P or D word defaults to teh LAST know tool number loaded SO if you never called a tool Number it defaluts to ZERO.

THAT is a MACH3 feature

Just a thought, (;-) TP