CNC Lathe G-code for cutting radius


Results 1 to 6 of 6

Thread: CNC Lathe G-code for cutting radius

  1. #1
    kyle1333333's Avatar
    Join Date
    Feb 2019
    Posts
    2
    Downloads
    0
    Uploads
    0

    Default CNC Lathe G-code for cutting radius

    Hi, guys im trying to code a 2mm radius cut into stainless steel on our Okuma LB15 CNC lathe, however, im getting the error, alarm B data word arc cal. 3
    can anyone see what is wrong with the code?

    G00 X300Z200
    T0303M03M08M42S2005G97
    G00 X20Z50
    G00 Z2
    G01 Z-8F0.1
    G01 X28
    G03 X30Z-10K-2
    G01 Z-14
    G00 Z100X50
    G00 X300Z200
    MO2



  2. #2
    Member RansomAMG's Avatar
    Join Date
    Apr 2019
    Posts
    1
    Downloads
    0
    Uploads
    0

    Default Re: CNC Lathe G-code for cutting radius

    Hi Kyle,

    Your G03 line looks okay, though for doing a 90° arc it would be easier to use R2.0 instead of K-2.0, not that it is wrong.
    The issue is the line before "G01 X28.0" as the X works in diameter on a lathe, so to produce a 2mm radius you move 2mm in Z but 4mm in X, so you would need to start at X26.0.



  3. #3
    Flies Fast Superman's Avatar
    Join Date
    Dec 2008
    Location
    Antarctica
    Posts
    3109
    Downloads
    0
    Uploads
    0

    Default Re: CNC Lathe G-code for cutting radius

    doubled up

    Last edited by Superman; 11-21-2019 at 03:14 AM.


  4. #4
    Member deadlykitten's Avatar
    Join Date
    Jun 2015
    Location
    Antarctica
    Posts
    4154
    Downloads
    0
    Uploads
    0

    Default Re: CNC Lathe G-code for cutting radius

    hy kyle replace K-2 with L2 and it will work; check attached : there is no way to get a r2 using k-2

    if you wish, check also this okuma forum, it is pretty good : https://www.cnczone.com/forums/okuma/

    kindly

    ps : try this shorter version

    Code:
    G00 X300Z200
    T0303G97S2000M03M08M42G00X20Z2F0.1G95(M63)
    G01 Z-8
        X28
    G03 X30Z-10
    G01 Z-14
        X31Z-13.5
    G00 X300Z200M05M09(M63)


    we are merely at the start of " Internet of Things / Industrial Revolution 4.0 " era : a mix of AI, plastics, human estrangement, powerful non-state actors ...


  5. #5
    Member
    Join Date
    Feb 2011
    Location
    usa
    Posts
    353
    Downloads
    2
    Uploads
    0

    Default Re: CNC Lathe G-code for cutting radius

    The LB15 that i have worked on also has chamfering and corner rounding
    corner rounding would be



    G00 X300Z200
    T0303M03M08M42S2005G97
    G00 X20Z50
    G00 Z2
    G01 Z-8F0.1

    G76G01X30L-2.


    G01 Z-14
    G00 Z100X50
    G00 X300Z200

    also there is no cutter comp set and if a 2mm radius is wanted the 2mm would have to be compensated for by the tool nose radius



  6. #6
    Member deadlykitten's Avatar
    Join Date
    Jun 2015
    Location
    Antarctica
    Posts
    4154
    Downloads
    0
    Uploads
    0

    Default Re: CNC Lathe G-code for cutting radius

    hy rcs initial shape may not be suitable for g76L±2, because difference between diameters is 30-28=2, thus 1per radius, so :
    ... there will be a nice 'fit' for a circle with radius 2 ( >1 ); aesthetically speaking, chamfer radius should be <=1
    ... because the circle radius is greater then the face ( 2>1 ), then there will be the case of 'chamfering' 2 paralel lines

    attached is the shape; it can be seen that using a circle with rad 2 is overshooting with 0.017 above the o30

    to fix that code :
    ... i would recomand using r1 instead of r2
    ... like you said, activating comp / kindly

    we are merely at the start of " Internet of Things / Industrial Revolution 4.0 " era : a mix of AI, plastics, human estrangement, powerful non-state actors ...


  7. #7
    Flies Fast Superman's Avatar
    Join Date
    Dec 2008
    Location
    Antarctica
    Posts
    3109
    Downloads
    0
    Uploads
    0

    Default Re: CNC Lathe G-code for cutting radius

    This post was started back in March 2019
    the OP has probably worked it out

    so kitty... stop beating a dead horse
    .... there is no one at home to test your code.



  8. #8
    Member
    Join Date
    Feb 2011
    Location
    usa
    Posts
    353
    Downloads
    2
    Uploads
    0

    Default Re: CNC Lathe G-code for cutting radius

    Quote Originally Posted by deadlykitten View Post
    hy rcs initial shape may not be suitable for g76L±2, because difference between diameters is 30-28=2, thus 1per radius, so :
    ... there will be a nice 'fit' for a circle with radius 2 ( >1 ); aesthetically speaking, chamfer radius should be <=1
    ... because the circle radius is greater then the face ( 2>1 ), then there will be the case of 'chamfering' 2 paralel lines

    attached is the shape; it can be seen that using a circle with rad 2 is overshooting with 0.017 above the o30

    to fix that code :
    ... i would recomand using r1 instead of r2
    ... like you said, activating comp / kindly
    deadlykitten if you had looked at the post you would have found that the op program starts a x20 then goes to x28 in my version i had removed the line G1X28 so that the linear movement would be from 20mm to 30 mm with the 2mm corner radius



  9. #9
    Member deadlykitten's Avatar
    Join Date
    Jun 2015
    Location
    Antarctica
    Posts
    4154
    Downloads
    0
    Uploads
    0

    Default Re: CNC Lathe G-code for cutting radius

    hi rcs yes, i see now, but this would deliver a different part, without the o28

    well, is ok 2 show how g76 works, but like superman said, it's old stuff, and i didn't see that / kindly

    we are merely at the start of " Internet of Things / Industrial Revolution 4.0 " era : a mix of AI, plastics, human estrangement, powerful non-state actors ...


Tags for this Thread

Posting Permissions

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


About CNCzone.com

    We are the largest and most active discussion forum for manufacturing industry. The site is 100% free to join and use, so join today!

Follow us on


Our Brands

CNC Lathe G-code for cutting radius

CNC Lathe G-code for cutting radius