Originally Posted by
Sam A
I have a Practical CNC with a WinCNC controller. I use BobCad for creating g-code files.
I am adding a Peck Drill Cycle to my machining tools.
Simple questions;
1. Do I have to have G83 on each line of code?
2. How do I set the Rapid movement Z in the code?
Thanks
Sam
Hi Sam, G83 is a canned cycle designed to make it easier to drill multiple holes. While I don't have either of the mentioned programs, here is how it works on Mach3 and Deskcnc.
1. No. the code looks like this,
G83 x0 y0 z-1 r.1 q .050
x1 y1
x0 y2
x4
y4
G00 z2 (to clear the tool and cancel the G81)
X0 Y0
The second line and the rest just have x and y coordinates.
The tool does the following. It will rapid to the X0 Y0 Z.1 position, then it will drill in increments of .050 (the Q value) retracting to .1 above the surface (the R value) until it gets to -1(the Z value).
All of the retracts and the return to drilling are done at the machines rapid speed. The cycle stops the return rapid just short of the last depth, then goes to the feed rate to drill the next increment. It makes coding this much easier than hand coding it. It is also cool to watch.
Be careful about setting R to 0 as it will rapid right to the surface of the part, depending on where your Z0 is set. IIRC
You may have to add code to clear obstacles, so in my example above you might put in a G00 Z4, then on the next line a X0 Y0 to get around something and put the tool above the hole before starting the g83.
It will then move to all the other X,Y values untill the G83 is cancelled by another G-code such as G00. You can even have just the X value or the Y value on a line and it is still valid.
I would try some air cutting the first time to make sure it will work with your program and that I have not left out anything.
Mike
Warning: DIY CNC may cause extreme hair loss due to you pulling your hair out.