586,655 active members*
2,571 visitors online*
Register for free
Login
IndustryArena Forum > Machine Controllers Software and Solutions > G-Code Programing > Having trouble getting code to work for npt threadmilling
Results 1 to 11 of 11
  1. #1
    Join Date
    Aug 2005
    Posts
    88

    Having trouble getting code to work for npt threadmilling

    Im trying to threadmill a 3/4 14 npt hole. Im using a Okk witha a mitsubishi meldas 5000c controler. The tec guy for the company we bought the theardmill gave us this code

    -d
    %
    N1G28 X Y Z
    N2G90G92X309949 Y61959 Z0
    N198G90G40
    N199G90G43G00 X8750 Y-20000 Z5000H23
    N200G01 Z0 F220
    N201S2726M03
    N202M8
    N203G91 G01 Z-4989 F220
    N204G41 X1523 Y-1523 F76 H21
    N205G17 G03 X1523 Y1523 Z0089 I0 J1523 F30
    N206G03 X-3045 Y3051 Z0179 I-3051 J0 F43
    N207G03 X-3057 Y-3051 Z0179 I0 J-3057
    N208G03 X3057 Y-3062 Z0179 I3062 J0
    N209G03 X3068 Y3062 Z0179 I0 J3068
    N210G03 X-1534 Y1534 Z0089 I-1534 J0 F30
    N211G01 G40 X-1534 Y-1534 F220
    N212G00 Z4097
    N213G90 G00 Z5000
    N290G92Z0
    N291G28XY
    N292M9
    N293M30
    %

    We've tryed several things to make it work but we keep comming up with program errors. Any help would be great.

  2. #2
    Join Date
    Mar 2003
    Posts
    2932
    What errors? What block #?

  3. #3
    Join Date
    Jan 2007
    Posts
    355
    Ugh.

    I hate code that doesn't have spaces and decimal points...

    Give this a try.


    %
    N1 G28 X Y Z
    N2 G90 G92 X30.9949 Y6.1959 Z0
    N198 G90 G17 G40
    N199 G90 G43 G00 X.8750 Y-2.0000 Z.5000 H23
    N200 G01 Z0 F.0220
    N201 S2726 M03
    N202 M8
    N203 G91 G01 Z-.4989 F.0220
    N204 G41 X.1523 Y-.1523 F.0076 H21
    N205 G03 X.1523 Y.1523 Z.0089 I0 J.1523 F.0030
    N206 G03 X-.3046 Y.3052 Z.0179 I-.3052 J0 F.0043
    N207 G03 X-.3058 Y-.3052 Z.0179 I0 J-.3058
    N208 G03 X.3058 Y-.3064 Z.0179 I.3064 J0
    N209 G03 X.3070 Y.3064 Z.0179 I0 J.3070
    N210 G03 X-.1535 Y.1535 Z.0089 I-.1535 J0 F.0030
    N211 G01 G40 X-.1535 Y-.1535 F.0220
    N212 G00 Z.4095
    N213 G90 G00 Z.5000
    N290 G92 Z0
    N291 G28 X Y
    N292 M9
    N293 M30
    %
    Diplomacy is the art of saying "Nice doggie" until you can find a rock. - Will Rogers

  4. #4
    Join Date
    May 2009
    Posts
    10
    Yes, Please. What error.

    Below is the code I chunked out with a free thread mill code chunker-outer from Seco.

    http://www.secotools.com/wps/portal/corp/Epi_510

    May have to tweak the cutter-comp setting. It takes so little time with the Seco program, I have yet to put those beautiful thread-mill motion descriptions in the back of the Emuge threading books into machine macros.

    http://www.emuge.com/carbide_thread/

    Look for the PDF files.... Brings a tear to my eye they are so pretty.

    Just watch out for the way calculators or CAD/CAM packages ask for the depth and use it. Some take a 0.5 inch depth and arc up from there. No sparks when they rapid in. Some take a 0.5 inch depth and start a quarter or so pitch deeper to give what they asked for - how deep do you want the thread.

    Watch your fingers :cheers:

    %
    O0110
    (This part-program was generated by the Thread Milling Wizard)
    (Material: Seco Group 20. Ni-. Co-. ferrous super-alloys. <30HRc.)
    (Thread milling: Right-hand internal 3/4 NPT x 14TPI - 0.4989 in deep.)
    (Component starting diameter: 0.9055 in x minimum depth of 0.522 in.)
    (Thread milling cutter: R396.19-2517.3S-4003-2A. Insert: 2 x R396.19-4003.0X14NPT F30M.)
    G20 G00 G90 G94 G40
    G28 G91 Z0.0
    G90
    T23 M06
    G54
    S1226 M03
    G00 X0.875 Y-2.0
    G43 Z0.5 H23 M08
    G00 Z-0.522
    G01 G91 G41 X-0.1401 Y0.0002 D21 F2.8
    G03 X0.3353 Y0.0 Z0.0214 I0.1677 J0.0
    G03 X-0.0572 Y0.1381 Z0.0089 I-0.1953 J0.0
    G03 X-0.1383 Y0.0573 Z0.0089 I-0.1383 J-0.1383
    G03 X-0.1385 Y-0.0574 Z0.0089 I0.0 J-0.1959
    G03 X-0.0575 Y-0.1387 Z0.0089 I0.1387 J-0.1387
    G03 X0.0575 Y-0.1389 Z0.0089 I0.1964 J0.0
    G03 X0.1391 Y-0.0576 Z0.0089 I0.1391 J0.1391
    G03 X0.1393 Y0.0577 Z0.0089 I0.0 J0.197
    G03 X0.0578 Y0.1395 Z0.0089 I-0.1395 J0.1395
    G03 X-0.3353 Y0.0 Z0.0214 I-0.1677 J0.0
    G01 G40 X0.1379 Y-0.0002
    G00 G90 X0.875 Y-2.0 Z-0.522
    G01 G91 G41 X-0.1401 Y0.0002 F2.8
    G03 X0.3373 Y0.0 Z0.0214 I0.1687 J0.0
    G03 X-0.0578 Y0.1395 Z0.0089 I-0.1973 J0.0
    G03 X-0.1397 Y0.0579 Z0.0089 I-0.1397 J-0.1397
    G03 X-0.1399 Y-0.058 Z0.0089 I0.0 J-0.1979
    G03 X-0.0581 Y-0.1401 Z0.0089 I0.1401 J-0.1401
    G03 X0.0581 Y-0.1403 Z0.0089 I0.1984 J0.0
    G03 X0.1405 Y-0.0582 Z0.0089 I0.1405 J0.1405
    G03 X0.1407 Y0.0583 Z0.0089 I0.0 J0.199
    G03 X0.0584 Y0.1409 Z0.0089 I-0.1409 J0.1409
    G03 X-0.3373 Y0.0 Z0.0214 I-0.1687 J0.0
    G01 G40 X0.1379 Y-0.0002
    G00 G90 X0.875 Y-2.0 Z0.5 M09
    G28 G91 Z0.0 M19
    G28 Y0.0
    M30
    %

  5. #5
    Join Date
    Aug 2005
    Posts
    88

    Thread Milling

    Thank you fellas for your reply's we are trying the suggestions now. My machine will not accept code with decimals. I hate it as well, but like mom used to say poor people have poor means.

    The alarm Codes I recieved are
    #11 (Arc Radius is zero in arc command)
    #15 (H number is programmed wrongly) I think that is fixed
    #50 ( Spiral Pitch is Zero in linear-circular)

    I hope this helps.

  6. #6
    Join Date
    Mar 2003
    Posts
    2932
    From what I can gather from the programming manual alarm #50 is because you don't have a K in each spiral block. It should be the spiral pitch amount, which I believe should be the same as the Z amount. Not sure why you're getting the alarm #11.

    N203G91 G01 Z-4989 F220
    N204G41 X1523 Y-1523 F76 H21
    N205G17 G03 X1523 Y1523 Z0089 I0 J1523 K0089 F30
    N206G03 X-3045 Y3051 Z0179 I-3051 J0 K0179 F43
    N207G03 X-3057 Y-3051 Z0179 I0 J-3057 K0179

  7. #7
    Join Date
    Aug 2005
    Posts
    88

    thanks for the help

    I did what you suggested by changing out the Z,s with the K,s from line 205-210 that seemed to help but now I am getting a parity H. I am not sure what that is.

  8. #8
    Join Date
    Mar 2003
    Posts
    2932
    I don't think I said replace the Z's with K's. I believe you need them both.

    Parity H? Sounds like a tape reader problem. Is there an alarm number?

  9. #9
    Join Date
    Aug 2005
    Posts
    88

    Thanks

    I should have read that closer. I will give it a try.

    Vince

  10. #10
    Join Date
    Aug 2005
    Posts
    88
    -d
    &#37;
    N1g40G28 X Y Z
    N2G90G92X309949 Y61959 Z0
    N4G90G43G00 X8750 Y-20000 Z5000 H23
    N5G01 F220 Z0
    N6S2000M03
    N7M8
    N8G91 G01 Z-4989 F220
    N9G41 X1523 Y-1523 F76 H21
    N10G17 G03 X1523 Y1523 Z0089 I0 J1523 K0089 F30
    N11G03 X-3045 Y3051 Z0179 I-3051 J0 K0179 F43
    N12G03 X-3057 Y-3051 Z0179 I0 J-3057 K0179
    N13G03 X3057 Y-3062 Z0179 I3062 J0 K0179
    N14G03 X3068 Y3062 Z0179 I0 J3068 K0179
    N15G03 X-1534 Y1534 Z0089 I-1534 J0 K0089 F30
    N16G01 G40 X-1534 Y-1534 F220
    N17G00 Z4097
    N18G90 G00 Z5000
    N19G92Z0
    N20G28XY
    N21M9
    N22M5
    M30
    %

    This is my code at this point. It starts moves down turns on spindle and begins arc move and throws this error. #51 ( End Points of straight line and arc are different in linear circular simultaneous three axis interpolation) I know we are getting close.

  11. #11
    Join Date
    Aug 2005
    Posts
    88
    I wanted to let everyone know that we have this issue solved and thank everyone that contributed. This is the code that finally worked. XYZ are the endpoint or the helix IJ are the centerpoint of the helix and K is the pitch of the spiral in one revolution. The real issue was the putting the G17 in each of the helix lines. Again thanks for taking the time and have a great day.

    &#37;
    N1g40G28 X Y Z
    N2G90G92X309949 Y61959 Z0
    N4G90G43G00 X8750 Y-20000 Z5000 H23
    N5G01 F220 Z0
    N6S2000M03
    N7M8
    N8G91 G01 Z-4989 F220
    N9G41 X1523 Y-1523 F76 H21
    N10G17 G03 X1523 Y1523 Z0089 I0 J1523 K0714 F30
    N11G17 G03 X-3045 Y3051 Z0179 I-3051 J0 K0714 F43
    N12G17 G03 X-3057 Y-3051 Z0179 I0 J-3057 K0714
    N13G17 G03 X3057 Y-3062 Z0179 I3062 J0 K0714
    N14G17 G03 X3068 Y3062 Z0179 I0 J3068 K0714
    N15G17 G03 X-1534 Y1534 Z0089 I-1534 J0 K0714 F30
    N16G01 G40 X-1534 Y-1534 F220
    N17G00 Z4097
    N18G90 G00 Z5000
    N19G92Z0
    N20G28XY
    N21M9
    N22M5
    M30
    %

Similar Threads

  1. post code trouble, or me?
    By Martin 007 in forum BobCad-Cam
    Replies: 7
    Last Post: 07-30-2008, 07:52 AM
  2. NPT Threadmilling
    By john_mccarron in forum GibbsCAM
    Replies: 1
    Last Post: 07-20-2007, 11:54 PM
  3. Threadmilling
    By MetalMolder in forum MetalWork Discussion
    Replies: 4
    Last Post: 06-29-2007, 09:41 AM
  4. Trouble with DXF to G Code Transfer
    By mlapacz in forum SheetCam
    Replies: 8
    Last Post: 03-04-2007, 07:25 AM
  5. Trying to make this work- G code
    By WOODKNACK in forum CNC (Mill / Lathe) Control Software (NC)
    Replies: 17
    Last Post: 06-10-2003, 06:00 PM

Posting Permissions

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