G Code for Chess piece

Ok,
I will give it a try.
I will let you know how it works out.
Right now waiting a couple of parts for my lathe.
Had a few pieces on the lathe break, so waiting on
the parts to fix it... Thanks for all the help, I will read the
gcode and see how it works, Like I said in my earlier post I have
written a gcode for turning pens and pencils which was easy,
just straight cuts once I learned how that worked it was pretty
simple to write different thickness of cuts..


I just realized that g-code is a mirror image of what you want, and a few more operations need to be added to speed up the process and make it machinable with a single tool. But let's see if the code will run at all, then we'll worry about getting it right.
 
Will do,
well here is one of the Gcodes I wrote for
my Sherline Lathe

G01 X-0.0500 F15
Z-2.1138
X-0.0450
G00 Z0
G01 X-0.0600
Z-2.1138
X-0.0550
G00 Z0
G01 X-0.0700
Z-2.1138
X-0.0650
G00 Z0
G01 X-0.0800
Z-2.1138
X-0.0750
G00 Z0
G01 X-0.0900
Z-2.1138
X-0.0850
G00 Z0
G01 X-0.1000
Z-2.1138
X-0.0950
G00 Z0
G01 X-0.1100
Z-2.1138
X-0.1050
G00 Z0
G01 X-0.1200
Z-2.1138
X-0.1150
G00 Z0
G01 X-0.1300
Z-2.1138
X-0.1250
G00 Z0
G01 X-0.1490
Z-2.1138
G00 X0
Z0
M30
 
I made this with CamBam, and compiled it with a Mach-Turn post. You might see if this will run on your machine.

( Made using CamBam - http://www.cambam.co.uk )
( ChessPiece 2/10/2015 14:30:38 )
( T0 : 0.01 )
G20 G90 G91.1 G61 G40
G0 X0.25
( T0 : 0.01 )
T0 M6
( Lathe1 )
G17
M3 S1000
G0 Z-0.1975
G0 X1.0214
G1 F5.0 X0.9439
G1 F10.0 X0.9334

G3 X0.6951 Z-0.4521 I0.1357 K-0.3659
G1 Z-0.4895
G2 X0.6901 Z-0.4945 I-0.005 K0.0
G1 X0.6867
G1 X0.6861 Z-0.6285
G2 X0.6816 Z-0.6335 I-0.005 K0.0
G3 X0.5238 Z-0.7855 I0.0168 K-0.1754
G1 Z-0.8731
G2 X0.5216 Z-0.8772 I-0.005 K0.0
G3 X0.4176 Z-1.2491 I0.1748 K-0.2494
G2 Z-1.2492 I-0.0046 K-0.002
G1 X0.5863 Z-1.6564
G2 X0.5847 Z-1.6624 I-0.0046 K-0.0019
G3 X0.5285 Z-1.7498 I0.0889 K-0.119
G2 X0.5236 Z-1.7538 I-0.0049 K0.0011
G1 X0.5169
G1 Z-1.8098
G1 X0.5324
G2 X0.5374 Z-1.8148 I0.0 K-0.005
G1 Z-1.886
G2 X0.5358 Z-1.8897 I-0.005 K0.0
G3 X0.406 Z-2.0891 I0.3166 K-0.3481
G1 Z-2.1813
G1 X0.6617 Z-2.1793
G2 X0.6668 Z-2.1842 I0.0 K-0.005
G1 X0.673 Z-2.5015
G2 Z-2.5023 I-0.005 K-0.0001
G2 X0.3306 Z-3.4493 I-2.3325 K0.308
G3 X0.3695 Z-3.6301 I0.2121 K-0.0489
G2 X0.3681 Z-3.6374 I-0.004 K-0.003
G3 X0.2637 Z-4.0988 I0.17 K-0.281
G2 Z-4.1042 I-0.0042 K-0.0027
G1 X0.2061 Z-4.1955
G1 Z-4.3205
G1 X0.9455
G0 X0.25
M5
M30
What do these 2 lines do?
 
What do these 2 lines do?

G1 F5.0 X0.9439
G1 F10.0 X0.9334

I just ran the code (on my desktop) in Mach-turn It looks like the first line prepositions the tool, the second line sets up the start point for the following arc. I have never created any G-code for turning, so without some study I'm not sure what is there. It looks pretty straight forward, but you have to think a lot about tool clearance and shape. The code above could not make the part with one tool, but with some changes it would.

The current goal is just to see if the lathe will even run the code (with no tool bit/material) without choking.
 
Try this gcode
Sorry it didn't work for me either
 

Attachments

  • glen.txt
    1.9 KB · Views: 19
Hey U.P. North,
Thanks, Now my question is, is this a single cutting tool
cut, because my lathe doesn't auto change cutting tools.
Oh yeah I forgot to mention I will be turning acrylic with
carbide inserts.
Thanks
Glen
 
Hey U.P. North,
Thanks, Now my question is, is this a single cutting tool
cut, because my lathe doesn't auto change cutting tools.
Oh yeah I forgot to mention I will be turning acrylic with
carbide inserts.
Thanks
Glen
This will take a minimum of 2 tools.
 
Welp still waiting on the parts for my lathe to get here, once they do then I can try the code out..
Will keep you guys updated on the progress
Glen
 
Hello Everyone,
Well sorry it took so long to get back, I finally got the parts in
and then I wound up getting the flu, and I still have this junk..
But anyhow, I got the lathe back up and running, I hadn't had
any luck with the codes.. I noticed on the codes there is a Y axis,
I don't have Y axis on mine just X and Z, so I don't know if the is a problem.
Oh yeah when I load The file into DeksCNC it tells me unknown G code on line 4
and that's for as it gets.
 
Last edited:
Back
Top