587,221 active members*
3,126 visitors online*
Register for free
Login
Results 1 to 11 of 11
  1. #1
    Join Date
    Apr 2004
    Posts
    28

    Question Circular pocket & cutter compensation

    Hard core software programmer (C++, Objective C), however I am new to CNC and G code.

    I am having problems using cutter compensation in a small circular pocket. My challenge is to mill an array of 0.25" circular pockets wilt a 0.188 end mill. I start by setting a radius for my cutter compensation of 0.1 for roughing, my smallest arc uses a radius of 0.1125 which I thought should work however the controller fails. If I set the radius to a small value 0.005" the controller runs with it (of course the pocket becomes too large).

    I am testing on a Fadal mill with what I believe to be a level 2 controller.

    I can do a workaround, however I would like to know WHY I am having this problem. Below I have a written a sample program which illustrates the issue (excuse the wasted motions at the start, originally I wrote this as a sub program, so this is an adaptation).

    %
    O5737
    N10 G0 G17 G20 G40 G49 G80 G90
    N20 G54
    N30 T3 M6
    N40 S3500 M3
    N50 G0 X-2.0 Y-1.0
    N60 G0 G43 Z1.0 H3
    N70 G1 Z0.1 F50
    N80 G0 X0 Y0
    N90 G0 X0 Y-0.001
    N100 G1 G41 X0 Y0 D3
    N110 G1 X0.1 Y0
    N120 G1 Z-0.05
    N130 G3 X-0.125 Y0 I-0.1125 J0
    N140 G3 X-0.125 Y0 I0.125 J0
    N150 G3 X0.1 Y0 I0.1125 J0
    N160 G1 Z0.1
    N170 G1 G40 X0 Y0.001
    N180 G0 Z1.0
    N190 M5
    N200 G0 X-2.0 Y-1.0
    N210 G0 G28 G49 G90 Z0
    N220 M30
    %

    Thanks,
    - George Lawrence Storm, Kenmore (Seattle), Washington
    George Lawrence Storm, Kenmore (Seattle), Washington
    Inventor, Machinist, Macintosh Applications Developer, Videographer

  2. #2
    keencoyote,

    Come to the Puget sound BBQ and I will show you in person:

    http://www.cnczone.com/forums/showth...808#post459808


  3. #3
    Join Date
    Mar 2003
    Posts
    4826
    N80 G0 X0 Y0
    N90 G0 X0 Y-0.001
    N100 G1 G41 X0 Y0 D3
    N110 G1 X0.1 Y0
    I think the problem may arise because your comp on move is too short. If you use a value equal to the tool radius for the G01 G41, then the machine will reckon the tool to be tangent to the path that follows, but no motion will actually occur. If you add an additional G01 move after turning comp on, then you will get motion.

    Here is an example with a .030" radius lead in/out, which should keep the tool safely inside the profile.
    S3500 M03
    G00 X0.0012 Y-0.03 Z0.25
    Z0.05
    G01 S3500 Z-0.05 F4.5
    G41 D3 Y-0.1237 F9.
    G03 X0.125 Y0. I0. J0.1238
    X-0.125 Y0. I-0.125 J0.
    X0.125 Y0. I0.125 J0.
    X0.0013 Y0.1238 I-0.1238 J0.
    G01 G40 Y0.03
    G00 Z0.25
    First you get good, then you get fast. Then grouchiness sets in.

    (Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)

  4. #4
    Join Date
    Jul 2005
    Posts
    12177
    Quote Originally Posted by keencoyote View Post
    .....My challenge is to mill an array of 0.25" circular pockets wilt a 0.188 end mill. I start by setting a radius for my cutter compensation of 0.1 for roughing, my smallest arc uses a radius of 0.1125 which I thought should work
    I do not follow your logic here.

    You are using a radius of 0.1 for cutter compensation, and this is larger than your tool radius by 0.006 so you leave a finish allowance.

    You are milling circular pockets 0.250" diameter so the radius is 0.125" but you use a circle radius of 0.1125.

    Surely if you are using an oversize tool radius you should be using the correct size circle radius, in other words 0.125?

    This is the way I do it; do a first cut using a cutter compenstaion entry that is larger than the tool radius. Then do a finish cut using the actual tool radius in the compensation.
    An open mind is a virtue...so long as all the common sense has not leaked out.

  5. #5
    Join Date
    Apr 2004
    Posts
    28

    Circular pocket & cutter compensation - Addendum

    I did a few experiments this morning, I found that setting the cutter compensation to .0555 worked, but setting it to .0556 failed.

    It appears to be a mathematical limit, however it is occurring before half of the smallest radius, 0.1125 (.05625), so it brings to question if this threshold is specific to the machine or to G code in general.

    The funny little jog is working as expected:

    N80 G0 X0 Y0
    N90 G0 X0 Y-0.001
    N100 G1 G41 X0 Y0 D3
    N110 G1 X0.1 Y0

    The failure is occurring on line:

    N130 G3 X-0.125 Y0 I-0.1125 J0

    This is occurring on a Fadal CNC88HS control.
    George Lawrence Storm, Kenmore (Seattle), Washington
    Inventor, Machinist, Macintosh Applications Developer, Videographer

  6. #6
    Join Date
    May 2007
    Posts
    781
    I would normally use a G13 for such stuff, if the control does not have that code I would use a sub like this and call it with a G65 or set it up so it is called be a G13.

    Note, that the line
    #3=[#[2000+#7]+#[2200+#7]](CUTT-COMP)
    will need to be changed to match the type and location of the offset table in the control. This example has the cutter radius at a base address of 2000 and the radius wear starting at 2200.

    Code:
    O1000(MAIN)
    G0Z0.1
    G0X5.0Y5.0
    G1Z-0.1F10.0
    G65 P9013 I[0.125-0.002] D2 F10.
    G65 P9013 I0.125 D2 F10.
    M30
    
    O9013(G13 TYPE MACRO)
    IF[#4EQ#0]GOTO810
    IF[#7EQ#0]GOTO820
    IF[#9EQ#0]GOTO830
    #1=#5041(X POS.)
    #2=#5042(Y POS.)
    #3=[#[2000+#7]+#[2200+#7]](CUTT-COMP)
    #5=#4-#3
    IF[#5LT0]GOTO840
    G3X[#1+#5]Y#2R[#5/2]F#9
    G3I-#5
    G3X#1Y#2R[#5/2]F[#9*1.5]
    GOTO900
    N810#3000=10(SPECIFY CIRCLE RADIUS)
    N820#3000=20(SPECIFY CUTTER COMP)
    N830#3000=30(SPECIFY FEED RATE)
    N840#3000=40(CUTTER LARGER THAN DIA)
    N900(END)
    M99

  7. #7
    Join Date
    Apr 2004
    Posts
    28

    Re: Circular pocket & cutter compensation

    Quote Originally Posted by Geof View Post
    I do not follow your logic here.

    You are milling circular pockets 0.250" diameter so the radius is 0.125" but you use a circle radius of 0.1125.
    The G3's with the 0.1125 radius are to for tangental entry and exit to the final radius cut which has a 0.125" radius.

    Quote Originally Posted by Andre' B View Post
    I would normally use a G13 for such stuff, if the control does not have that code I would use a sub like this and call it with a G65 or set it up so it is called be a G13.
    ...
    Unfortunatly this control does not support G13. I will try your macro.

    Thanks,
    - George
    George Lawrence Storm, Kenmore (Seattle), Washington
    Inventor, Machinist, Macintosh Applications Developer, Videographer

  8. #8
    Join Date
    Jul 2005
    Posts
    12177
    Quote Originally Posted by keencoyote View Post
    The G3's with the 0.1125 radius are to for tangental entry and exit to the final radius cut which has a 0.125" radius.
    Okay, thanks.
    An open mind is a virtue...so long as all the common sense has not leaked out.

  9. #9
    Join Date
    Aug 2007
    Posts
    95
    Fadal has a sub-routine for circular milling-

    L9401 R0+3. R1+.25

    The R0+ IS THE FEED THE R1+ IS THE DIAMETER OF THE HOLE

  10. #10
    Quote Originally Posted by dpark1 View Post
    Fadal has a sub-routine for circular milling-

    L9401 R0+3. R1+.25

    The R0+ IS THE FEED THE R1+ IS THE DIAMETER OF THE HOLE
    Brilliant.

  11. #11
    Join Date
    Jul 2003
    Posts
    1220
    Quote Originally Posted by keencoyote View Post
    .........I can do a workaround, however I would like to know WHY I am having this problem.......
    Quote Originally Posted by keencoyote View Post
    I did a few experiments this morning, I found that setting the cutter compensation to .0555 worked, but setting it to .0556 failed..........
    ..............The failure is occurring on line:
    N130 G3 X-0.125 Y0 I-0.1125 J0
    I believe the tool path gets crossed (change direction) because of the cutter radius length, the angles and the lengths of the arc increments.
    Picture not to scale but shows the ends of the cutter radius not following a path offset to the profile.
    Attached Thumbnails Attached Thumbnails keencoyote.JPG  

Similar Threads

  1. G12/G13 Circular pocket help needed
    By NeoMoses in forum G-Code Programing
    Replies: 9
    Last Post: 07-02-2012, 07:43 PM
  2. G77 Circular Pocket
    By Big John T in forum BobCad-Cam
    Replies: 3
    Last Post: 02-27-2007, 05:33 PM
  3. Cutter Compensation?
    By Joe Petro in forum Autodesk
    Replies: 6
    Last Post: 03-08-2006, 07:04 AM
  4. Cutter compensation?
    By Tonenc in forum G-Code Programing
    Replies: 4
    Last Post: 11-03-2005, 06:53 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •