Here I show how I program a CNC router using freely available open source software. In my previous instructable, I briefly explained how I made my own CNC router from a radial arm saw.
Whether you prefer video or written instructions, this instructable has both. Watch the video here. Everything is described in detail in the following steps.
Before you start, be aware of woodworking and power tool safety. Step Zero is to install all the software you don't already have...
64 bit computer Amazon
CAELinux 2013 caelinux.com
Inkscape 0.91 www.inkscape.org
PyCAM 0.5.1 https://sourceforge.net/projects/pycam/
CAMotics 1.0.6 http://camotics.org/
You can use the same computer for both CNC control and programming, but I have a separate old P4 32 bit computer that was collecting dust, which is now dedicated to controlling the CNC router.
I run Ubuntu Linux on a 64-bit refurbished PC using the CAELinux distribution, which comes loaded with some great engineering tools. It can be downloaded as a bootable DVD image. Hershey Text is a single-line font made for efficient engraving. This is not absolutely necessary, but my example uses it. Follow the instructions on the Hershey Text link to install after Inkscape is installed.
In this example we will engrave an eraser to use as a stamp. It is broken down into many simple steps with screenshots showing where to click. Open Inkscape and move on to Step 1...
Step 1: Inkscape
Make the rectangle as shown in the figure. The arrows are numbered in the order you click to make a rectangle the size of the eraser I want to carve.
Step 2: Hershey Text
In the menu at the top, select
Then create the single-line text as shown in the figure.
Step 3: Size and Move the Text
Flip horizontally as shown in the figure so the stamp leaves a print in the right direction.
Select “Inkscape SVG (*.svg)” file type.
Step 4: PyCAM
Set units (I'm using mm in this example).
Set a safe height above the working surface for rapid moves between cutting steps, as shown in the figure.
Step 5: Model
Open .svg file made in the prior steps.
Shift to origin and shift down as shown in the figure.
We will let Z=0 at the surface of the workpiece, so we shift the lines down to the depth we want to engrave (.5 mm).
Step 6: Tool
There is no conical "V-bit" shape in PyCAM, but it doesn't matter in this case. We are simply telling PyCAM to put the toolpath right on the line, with no offset to worry about, so the tool shape doesn't have any effect. We'll just pick "spherical" instead, which will give us an idea what to expect in the "visualization" window.
Step 7: Process
We are only carving. 5mm deep, all in one pass. We don't need any offset because we are following right on the lines with the point of the V-bit.
Step 8: Bounds
We just need to establish bounds outside the area we are carving.
Step 9: Task
Again, one single pass of the engraving process is all we need, using the tool we defined.
Step 10: Toolpath
This is basically the "go" button. Simulate here to confirm that the intended lines are cut. Next we use CAMotics to get a more accurate simulation.
Step 11: CAMotics
Why simulate? Running the program on a virtual machine is much safer. It takes very little extra time and saves you from crashing a tool or ruining your project. Open CAMotics and set the units.
Step 12: Open G-code File
This is the file we just made in PyCAM. Set up the tool as shown in the figure.
Step 13: Define Tool
Set up our v-bit.
Step 14: Run Simulation
Step 15: Inspect the Result
Maybe this seems like a low risk program, but checking the simulation output is good practice.
Step 16: The Machine!
Clamp your stock in the CNC machine with the power off.
Step 17: Linuxcnc
Fire up Linuxcnc and start your machine control program. In my case, I use the Axis shortcut created by the stepper configuration wizard.
Step 18: Open G-code Program
Open the program we made in PyCAM.
Step 19: Home All Axes
1. Turn off E-stop
2. Machine On
3. Home all
I have my machine set up to home Z first to make sure the tool is up and out of the way before moving in the X and Y directions from an unknown position.
Step 20: Touch Off (zero) All Axes
You can use the mouse, but I find the keyboard is more convenient. Use the arrow keys to jog in the X and Y directions and PgUp/PgDn to jog in the Z. In this program, the coordinate systems (zero) origin is in the lower left corner of the eraser. For something like this, I use the point of the v-bit to line up the X and Y by eye and use a sheet of paper to slide under the bit to tell when the z is just touching the surface.
For each axis, when you have it in position:
1. click the axis identifier
2. click "Touch off"
3. type "0"
Step 21: Run the Program
If you have manual spindle control like I have, start your spindle, start the program, as shown in the figure, and enjoy the show!
Step 22: Inspect Your Work
When the program is done, stop your spindle and inspect your work. If all went well your design is engraved!
If you like this style of step-by-step instruction, please share with others and subscribe, so you'll be notified when I post more. If you have questions, please post them in the comments. I will try to answer and probably update the instructions, too. Read about more of my woodworking projects and tools at ChipsWoodShop.com.