Machsupport Forum

G-Code, CAD, and CAM => G-Code, CAD, and CAM discussions => Topic started by: 01sporty on December 10, 2022, 03:00:04 PM

Title: Another why doesn't this code work thread.
Post by: 01sporty on December 10, 2022, 03:00:04 PM
Simple little program.  At least it should be.  Once I put in a G0 rapid, that's all it will do.  The feed words have absolutely no affect.  If I comment out all of the rapids, it feeds fine.  I ended up just substituting a large feed value for the G00's but I'd still like to know what's up with this program.

G90 G95 (ABS DIST MODE / FEED PER REV)
(CREATED 12/09/2022 )
(#3 - Cutoff TOOL 3 )
M6 T0303
g00
x-.2 z0
z.005 x.16
z-.456
M3 S1200
g04 P2
F0.002
x.082
(g00)
x.16 z-.45
z-.478
F0.002
x.081
z-.456
(g00)
x.16
z-.499
F0.002
x.080
z-.456
(g00)
x.16
z-.506
F0.001
x.15 z-.502 
x.080
z-.456
(g00)
x.16 z.005
m5
m9
x-.2
z0
M30
N470

Thanks,
Walt
Title: Re: Another why doesn't this code work thread.
Post by: Graham Waterworth on December 10, 2022, 04:48:21 PM
My guess is its for lathe.

If its lathe you do not enter M6 only T0303.

Do you have encoder feed back on the spindle, are you working inch or MM program don't know.

You also need some feed commands (G01).
Title: Re: Another why doesn't this code work thread.
Post by: 01sporty on December 10, 2022, 05:11:09 PM
Thanks for the feedback Graham.
It is a lathe.  There is spindle feedback.  Most of my programs are CAM generated.  I scribbled this out by hand. The M6 is in all of my programs, doesn't seem to hurt anything.

And, I now see the problem.  Lack of G01.  Duh.
Title: Re: Another why doesn't this code work thread.
Post by: 01sporty on December 10, 2022, 08:01:23 PM
Here's the corrected code for the benefit of the next person suffering brain fade.

G90 G95 (ABS DIST MODE / FEED PER REV)
(CREATED 12/09/2022 )
(#3 - Cutoff TOOL 3 )
M6 T0303
g00 x-.2 z0
z.005 x.16
z-.46
M3 S1200
g04 P2
g01 x.082 f.002
g00 x.16 z-.45
z-.48
g01 x.081 f.002
z-.456
g00 x.16
z-.502
g01 x.080 f.002
z-.456
g00 x.16
z-.506
g01 x.080 f.001
z-.456
g00 x.16
z.005
m5
m9
x-.2
z0
M30
N470