G-code assistance

Can you just copy and paste the code into the text window, it will make things a lot easier.
 
O7777

(Justin Smith)
(NameTag)
(Origin 0,0)
(Tool - Sharpie)
(Paper 8.5" x 11")

N5 G17 G20 G40 G80 G90

N10 M1

N15 M06 T1

N20 M03 S90

N25 G00 X1.0 Y2.0 G54 E1

N30 G00 Z1.0 G43 H01

N35 G00 Z.1

N40 G01 Z-.002 F3.0

N45 G03 X3.0 Y2.0 I1.0 J0.0

N50 G01 Y6.0

N55 X1.75

N60 X4.25

N65 G00 X4.75 Y6.0 G54 E1

N70 G01 Z-.002 F3.0

N75 Y-6.0

N80 X6.5

N85 G00 X7.25 Y2.0 G54 E1

N86 G01 Z-.002 F3.0

N90 G03 X9.5 Y2.0 I1.0 J0.0

N95 G03 X8.25 Y3.5 I-1.0 J1.5

N100 G02 X7.25 Y4.75 I-1.0 J1.25

N105 G02 X10 Y4.75 I1.25 J0.0

N110 G00 Z1.0

N115 M05

N120 G28

N125 M30

(all done, enjoy your broken sharpie)
 
This should help explain what is going on, I added some code (xxxxxxxxx) to show the tool lifts

N5 G17 G20 G40 G80 G90

N10 M1

N15 M06 T1

N20 M03 S90

N25 G00 X1.0 Y2.0 G54 E1
Rapid X,Y to position, apply offset E1 (probably 0)

N30 G00 Z1.0 G43 H01
This line should not move the tool, but rather should apply the tool height offset to the DRO.

N35 G00 Z.1
Rapid Z down to 0.100 above part

N40 G01 Z-.002 F3.0
Move at plunge speed to -0.002

N45 G03 X3.0 Y2.0 I1.0 J0.0
Arc move CCW with an incremental radius of 1.0, end arc at X,Y position. Arc starts at position in N25

N50 G01 Y6.0
Move to Y

(N51 G00 Z0.100)
Lift tool

N55 X1.75
Move to X

(N56 G01 Z-G.002)
Tool down

N60 X4.25
Move to X

(N61 G00 Z0.100)
Lift tool, end of ''J''

N65 G00 X4.75 Y6.0 G54 E1
Move to start of ''L'', top

N70 G01 Z-.002 F3.0
Tool Down

The code below here needs some attention, you are showing incremental moves, but you are in absolute mode (G90)

N75 Y-6.0

N80 X6.5

N85 G00 X7.25 Y2.0 G54 E1

N86 G01 Z-.002 F3.0

N90 G03 X9.5 Y2.0 I1.0 J0.0

N95 G03 X8.25 Y3.5 I-1.0 J1.5

N100 G02 X7.25 Y4.75 I-1.0 J1.25

N105 G02 X10 Y4.75 I1.25 J0.0

N110 G00 Z1.0

N115 M05

N120 G28

N125 M30

(all done, enjoy your broken sharpie)
 
Thanks for the awesome clarification. Do you mind if I rework some of this tomorrow? It's late now but I want to attempt to re-do it based on your fixes. I really appreciate it!
 
Any time you want. :) G code and the process is easy to learn, prior to 2014 I couldn't even spell G code :grin: You can teach an old dog new tricks. You'll do fine.:encourage:
 
O7777

(JUSTIN SMITH)
(NAMETAG)
(ORIGIN 0,0)
(TOOL - SHARPIE)
(PAPER 8.5" X 11")

N5 G17 G20 G40 G80 G90

N10 M1

N15 M06 T1

N20 M03 S90

N25 G00 X1.0 Y2.0 G54 E1

N30 G00 Z1.0 G43 H01

N35 G00 Z.1

N40 G01 Z-.002 F3.0

N45 G03 X3.0 Y2.0 I1.0 J0.0

N50 G01 Y6.0

N51 G00 Z.100

N55 X1.75

N56 G01 Z-.002

N60 X4.25

N61 G00 Z.100

N65 G00 X4.75 Y6.0 G54 E1

N70 G01 Z-.002 F3.0

N75 Y.75

N80 X6.5

N81 G00 Z.100

N85 G00 X7.25 Y2.0 G54 E1

N86 G01 Z-.002 F3.0

N90 G03 X9.5 Y2.0 I1.13 J0.0

N95 G03 X8.25 Y3.5 R1.25

N100 G02 X7.25 Y4.75 R1.25

N105 G02 X9.5 Y4.75 I1.13 J0.0

N110 G00 Z1.0

N115 M05

N120 G28

N125 M30

(ALL DONE)
 
Last edited:
Yup, a typo;)

I made a couple of changes below

N110 G00 Z1.0

N115 M05
Stop spindle

(N117 G49)
Cancel tool height offset

N120 G28
Go X,Y,Z home. This could be replaced by some other code, maybe to move the table to a convenient location for a part change or measuring.

N125 M30
End program and rewind. Rewind is old code for paper tape machines, where you actually had to rewind the tape, today it just jumps to the top of the program.
 
sorry i thought I added that last lines to mine. i edited it and put mine in there. we don't need to put the G49 in I don't think because we haven't really learned that. he gave us a paper that shows us how to shutdown, but I will add it if need be. anyways, thank you so much for helping! everything i fixed looks good now? like the y-6.0 was incremental so i changed that to .075 i think that was right.
 
I tried to run the code on my computer, but there is something wrong. It doesn't like the code. I'll figure it out and let you know.
 
Well it's for a really old Fadal CNC. Keep that in mind. Also what software are you using to test it?
 
Back
Top