Creating a Ground-Up Introduction to 2D CAM Class for the Community Makerspace
I designed and recorded the videos for our 2D CAD class to give my subordinates a guideline for the finished product. I delegated the recording of the remainder of the videos, but created a script for the 2D CAM course, which I include below.
Introduction: Course Page
CAM is how we take our designs and come out with code a machine can use. Frequently, CAM software is different from our design software, as is the case here.
The workflow is going to take the following steps:
Import our design
Set up our machine
Set up our stock
Set up our operations
Choose our tools
Simulate our cuts
Export our GCode.
Each step is fairly simple and will be explained in full to provide you with the information you need. Each project is different and may require some flexibility. Don’t hesitate to ask on Discourse or on Slack in the #cad-cam channel.
VCarve will post projects for the ShapeOko, X-Carve, and ShopBot CNC routers. In this guide, we will be preparing a job for our ShapeOko.
For a guide on how to set up the Vectric VCarve Pro Trial Edition for home use, please check the Discourse thread on the topic.
Part 1: What Do I Need?
A modern computer running Windows
Vectric VCarve Makerspace Trial, which you can download here:
https://www.vectric.com/free-trial/vcarve-pro
The VCarve Pro Trial Edition will allow you to follow along entirely with the guide until we need to “post” our GCode. For that final step, you will need to bring your VCarve project file (.crv) to PS1 and complete the final step. The fully licensed machines will be the ones connected to the applicable machines (e.g. ShapeOko or ShopBot).
Similar to our 2D CAD video, I recommend using a mouse with left click, right click, and center wheel.
Part 2: What is CAM?
As described on the course intro page, CAM is how we get our designs into something the CNC machine can understand. CAM stands for Computer Aided Manufacturing, as opposed to CAD which is Computer Aided Design. The output from a CAM program, the code that a CNC machine reads, is generally called GCode.
GCode is the machine language which nearly all CNC machines use. Each line in a GCode file provides an instruction to the machine. Different machines use different controllers, and therefore use different GCode “dialects”. The commands are often the same, but are presented differently. All CNC machines use GCode, including routers, lasers, mills, and 3D printers, but that doesn’t mean any CAM software can be used to control any CNC machine. V-Carve cannot be used to control the 3D printers or lasers, nor should it be used for the Tormach.
In order to turn our design into machine-readable GCode, we use our CAM software to create toolpaths. Toolpaths are the paths that the machine will move along during its operation. We can create toolpaths that follow the contours of our design, which in turn will allow the machine to cut the design out of a piece of stock material.
In the following videos, we’ll take a look at VCarve and how we can use it to define toolpaths and output gcode.
—
So how do we get from our design to GCode? We use our CAM software to apply different operations to our design, usually in specific places. The CAM software then analyzes the geometry where we put the operation and comes out with a toolpath.
The toolpath is the critical part. It is like a vector, but instead of defining contours of a design, it is defining the path our cutting tool follows. From here, we can easily get to GCode, which are the instructions for moving that tool in space.
We give the CAM software the size of our stock, our design, and apply the operations. From there, we can get GCode!
Part 3: VCarve UI and Basics
First, we're going to open up the VCarve Pro Trial Edition. We are met with a main news page.
BEFORE DOING ANYTHING ELSE, WE MUST ENTER OUR MAKERSPACE ID SO WE CAN OPEN OUR PROJECTS FROM OUR HOME COMPUTER AT THE PS1 COMPUTERS.
[REDACTED]
We do this by launching VCarve Pro Trial Edition going to Help > About VCarve Pro Trial Edition and inputting the above Makerspace ID. You can copy and paste this ID from the course notes. Now close and re-open V-carve. If you do not enter the makerspace ID, you will not be able to open projects created at home on the PS1 computers.
You will also want to install the ShopBot and ShapeOko machine profiles and tool libraries. Instructions for doing so are available in the course notes.
I would first like to alert you to the “Video Tutorials” section on the left hand side of the screen. These tutorials can be very helpful when learning to use VCarve, and are highly recommended as additional learnings.
On the left hand side, we see our startup tasks. Since we are just getting to know the software, let’s hit “Create a new file”.
This next screen is our job setup dialog box. The first box is asking whether our job will have one setup, two setups, or is on a rotary device. The vast majority of projects will fall under the one setup or “single sided” dialog. If you have a project that needs both sides to be milled, that would use the double sided option. A rotary setup would be for more advanced geometry or for cylindrical work pieces.
The next box down asks about our job size. This is about our stock size, not our machine size.
The third box is extremely important. It is asking if we want to zero our machine off the top of the work or the bed of the machine. On PS1 machines, always zero off the machine bed. This will prevent damage to the spoilboard. If you have an advanced project, our CNC volunteers will be happy to help you find the right setup for you.
The fourth box is asking for our XY position. The “near left corner” (in this representation, on the bottom left) is most common. We can see, though, as we choose different boxes that a red square moves around our main view. That represents what we are setting up with these two boxes: the origin.
We’re going to stick with the bottom left corner, but a word on the origin: this is the starting point for the machine to know where the rest of the cuts are. If you set the origin in the wrong place, it will cut in the wrong place. The origin you select in the software must match the origin you set at the machine.
For instance, if we set our Z Zero Position to the material surface in CAM, but on the machine accidentally set it to the bed, it will mill through the entire bed of the machine, and that is no good for anyone.
If you like, you can design in V-Carve using similar tools to what are in Inkscape. That’s out of scope for this video, but that’s what you would use in the “Create Vectors”, “Transform Objects” and “Edit Objects” menus
I’m just going to open up a simple design, and we’ll take a look at the “Toolpaths” tab on the right. I like to hit the pushpin so it stays visible.
Here we set our material thickness. This needs to be the same as our material thickness on the “Job Setup” dialog.
Our XY Datum and Z Zero also need to be in the same place as our job setup. Once again, we must use the Machine Bed for our Z zero. We don’t need to worry too much about the “Rapid Z Gaps” and “Home/Start Position” options. If you’re using a big clamp or something like that, you will want to have big gaps to make sure the tool clears them. Those X and Y coordinates for the Home/Start Position are based on the XY Datum we set up in this tab.
Now that we have set up our job, we are able to see our Toolpath Operations. Our next video will focus on those, but these are how we tell the machine what and how to cut the material.
Part 4: About Operations
Note: Open “Simple Operations” file for VCarve
Now that we know our way around VCarve, let’s talk about operations. There are two main types of operations, roughing and finishing.
Roughing is all about quick-and-dirty material removal. It allows us to remove the bulk of the material we don’t need quickly.
Our cutting tools (end mills and router bits, for the most part) are designed only to manage a certain amount of pressure against the work. We use roughing to get most of the material we don’t need away from our part, and then we use finishing operations to get to the final dimension and geometry.
Finishing operations take less material off at a time and move slower than roughing operations. This provides superior surface finish and gets us closer to our nominal dimensions on the part.
One example of a finishing operation is a contour operation, which follows the contours of our parts. V-Carve calls it a Profile operation, but it is the same in this case.
Looking at the “Toolpath Operations” tab, let’s hover over them quickly and have a brief explanation of each. What I cover here will be provided in text below the video:
Profile Toolpath - this is a contour toolpath, and it is designed to cut along the border of a vector. We can choose which side of the vector we want to cut on, whether we want the tool to follow along the outside, inside, or center of our lines.
Pocket Toolpath - this is for mass material removal for something that does not go all the way through. In our example here, we’re going to cut away that interior square, but not all the way through to create a basin.
Drilling Toolpath - we don’t have drills for most of the PS1 machines that use V-Carve, but drilling needs special commands.
Thread Milling Toolpath - these are designed to use a custom cutting tool to make custom threads in a device. We don’t really have thread mill cutters, but if you feel your project needs it we can talk. Normally, I’ll recommend using a tap.
Quick Engrave - This is a super fast way to engrave text, and we’ll see it in our follow along project. These are best suited for diamond or engraving bits.
Inlay - this lets you make a matched set of inlays without necessarily needing to program each. It simplifies the process quite a lot from doing contour cuts or pockets.
V-Carve/Engraving Toolpath - a more advanced version of the Quick Engrave tool that gives you more control over the process.
Photo V-Carve lets you carve around particular pictures or vectors to get an effective grayscale. It’s perhaps the best tool we have for doing this kind of process aside from the lasers.
Fluting Toolpath - we can set lines and curves for our end mills to follow, and this is effective for things like making channels, grids, etc. We can set a ramp to taper the tool entry and exit for a clean look.
Texturing - a more specialized tool for adding a finish to our piece. If you want to use this tool, reach out to our CNC team on Slack or Discourse.
Prism Carving - for decorative raised lettering, usually for large, thick materials.
Moulding Toolpath - usually reserved for use with Ogee bits for custom moulding (e.g. frames, trim).
Chamfer Toolpath - these are for edge breaks for fit or decoration. Unlike the 2D chamfers we talked about with Inkscape, these get applied with a V-shaped bit against raised edges.
3D Roughing Toolpath - this is really for use with 3D models, and it is a larger roughing pass that moves in 3 dimensions to remove lots of material at once.
3D Finishing Toolpath - similar to the above, but it gets the finish closer to spec and visibly prettier. If you find yourself using the 3D tools often, you will want to check out our 3D CAD and CAM CNC course!
The Profile and Pocket operations are by far the ones that will get used the most, maybe with fluting and quick engrave after.
We have our material set up, so let’s check our machine out. We’ll go to the top toolbar, and chose “Toolpaths” > “Tool Database: Machine”
Using the “Machine” dropdown menu, we’ll choose the ShapeOko and press “OK”. Note: we will go over how to install the tool database in the virtual machine authorization modules.
I’m going to follow the same procedure for our ShapeOko tool library so we’ll have all the restocked tools for the machine available.
With our job set up at ½” thickness, let’s first make the pocket in the middle. I’ll choose the second icon for the Pocket toolpath.
First, the “Cutting Depths” box: Our “Start Depth” will be 0, and our “Cut Depth” will be ¼” because I only want this to go halfway into the material.
For the “Tools” box, I’ll use the generic ⅛” inch end mill for this job. Just as a sanity check from earlier, we can hit the “Select…” dialog to make sure the correct machine and tool library are chosen.
If you would like to learn more about dialing in feeds and speeds, we have some more technical material available. It is worth understanding if your parts are not coming out as intended.
We can add more passes, and how many you do depends on the kind of material you use. 3 passes to remove ¼” of material is OK for the ShapeOko. If we want to increase or decrease the number of passes, we can hit the “edit passes” button.
We’re going to leave the rest of the box alone with the pattern set to “Offset” and the cutting mode to “Climb” as well as leave the “Ramp Plunge Moves” box unticked.
Pocket Allowance will be left to 0.
Towards the bottom, we can see that “Vector Selection” is set to “Manual” so let’s choose a contour that defines the boundaries of the pocket, which is this inner rounded square. We can name it “Inside Pocket” here as well.
Just hit the “Calculate” button and we’ll have our first toolpath!
The software has put us into the 3D view tab, and we can see the toolpaths. Note that on the “Toolpaths” block on the right, we have two toolpaths. One roughing and one finishing operation. If you would like to edit them, you can simply double click the toolpath.You’ll note that the finishing pass has 5 passes, where the roughing one has 3.
Part 5: Follow Along Project—Name Tag
Document Units: mm
Machine area: 250mm x 250mm.
Stock size: 120mm x 120mm
Nametag: 100mm x 50mm
Fillet: 5mm
Now that we have a rough understanding of our software and what we want to do with it, let’s bring in our nametag from the 2D CAD project.
This is a simple project, consisting only of some engraving and a contour pass around the outside of the nametag itself to separate it from the stock.
So first, let’s fire up VCarve. We are looking at our main screen.We’re going to use the same nametag that we designed for our Intro to Inkscape course. To do that, under “Startup Tasks” I’m going to select “Open an existing file.” I’ve navigated to the file and will simply hit “Open.”
Opening this file has brought us into a great setup. First, because we set the file up such that the page was the same size as the ShapeOko. Looking at the Job Setup bar, we can see how that is the case. Unfortunately, our Z height is set at the software default - 6 inches, so let’s decrease that to the thickness of our material, ⅛”.
Let’s set the zero to our machine bed and use the bottom left hand corner as our XY zero and hit “OK”
Now, let’s take a look at what we have brought in here. Our stock is the largest rectangle, and we can leave it there without doing anything else because we have a lot of margin around our piece. We never want to keep our parts right against the boundary of our work surface because we can accidentally run out of room for the tool to go and get some errors.
We have our rounded corner box and the engraving. The engraving is some delicate work, and we should really do that before carving the rest of the piece out from our work, so let’s set that up first.
I’m going to click the “Toolpaths” tab on the upper right hand corner and hit the pin to keep it locked in place.
Next, I’ll choose the “quick engrave” operation and use the 1/16” end mill. Since the ShapeOko doesn’t have an automatic tool changer, or an ATC, I’m going to keep this to using a single tool for the entire project.
We’ll set the depth to 1/16” of an inch
I’m going to leave this set to Outline and choose the vectors by box selecting the text.
I’ll call this operation “Text”
I’ll set the Post Processor to GRBL (inch), and hit “Calculate.”
We’re now in the 3D view, and we can see the toolpaths! The travel movements are in red and the feed toolpaths are in blue. Keep your eye on the upper right, and we can simulate the toolpath by using the preview options. As we can see, it’s a little blurry because the text did not come over correctly, but I think we can work with this!
Now, let’s go back to the 2D view using the tabs at the top of the page and close out of the preview. Let’s do a profile operation on the outside of the nametag to separate it from the rest of the stock.
We have our 2D profile set. Our start depth is going to be set to 0 and our cut depth is going to be the thickness of our material, ⅛”. Make sure that the “Show advanced toolpath options” box is ticked so we can get familiar with the extra options.
We need to set our tool to the 1/16” tool, and we have a lot of passes. The 1/16” end mill is very thin, so we can’t do a super thick pass all at once, but let’s take it easy and do 4 passes to be easy on the tool. 4 passes over ⅛” gets us to 1/32” at a time, which should be plenty easy on the tool.
For the Machine Vectors section, this is where we tell VCarve if we want to be inside, outside, or on the line. I’m going to click the border and choose outside/right since this is the outer border of something, not an interior through cut. We’ll also leave this set to climb cutting. Climb and conventional cutting will impact surface finish - if you’re getting fuzz out on wood on the climb setting, try conventional cutting on your finishing operations. More information on climb vs conventional cutting is in the CAM Know-How page of our Canvas course.
If you want, you can set a separate last pass. If you leave some allowance in the “Machine Vectors” box, you can then get a clean single last pass that gives you a consistent surface finish. We’re not going to worry about that for today, though.
Moving to the next box, we can add tabs. What these do is leave little easy-to-remove connectors to our stock material. That way the final piece doesn’t go flying when it gets cut out. Different workholding - the way you secure your stock to the machine - can mean you don’t need it. The way we usually secure work to the ShapeOko doesn’t need it, but the ShopBot almost always does. To demonstrate, we’ll add them here.
Tick the box “Add tabs to toolpath”. ½” wide by ⅛” tall is maybe a little thick, so let’s set it to a quarter inch and 1/16” thick then hit “edit tabs”.
We’ll set it to 4 tabs and hit “Add Tabs”. If you don’t like where they go, you can add them manually instead by just clicking locations on the vector. This is a good look, though, so let’s continue by hitting “close”.
Let’s also add a ramp to this. Most CAM defaults to a “plunge” move which just shoves the bit straight down. This can be OK if you have the right kind of tooling, but we usually do not. What a ramp does is gently ease in over a certain length. Let’s set it to zig zag over 2 inches.
We’ll rename the toolpath to “border” and hit “Calculate”.Let’s select all toolpaths and hit “Preview All Toolpaths” to see how this looks. Simulating is crucial in ALL CAM packages so be certain to do it every single time before posting your code. This looks really good, so let’s save our project.
As a reminder, we can use the trial version of this software at home and get everything set up with our Makerspace ID. Then, when we’re at the space we can post the code into a language the machines understand and get them going. If you do not set up the Makerspace ID, the PS1 machines will not let you post your code.
So let’s go to File > Save As. I’m going to save this to my thumb drive so I can just bring it to the space. As you can see, I am naming the project so I can remember what machine I have it set up for. This is going to be a .crv file. Now that the file is saved, I will open in the Makerspace edition and post the process.
I have clicked on my “Toolpaths” banner again, and I am going to do two things. First, check the time on this part. The software says it’ll be 16 minutes, so we can see how true that is when we’re done.
I hit close, and now let’s hit the “Save Toolpaths” icon. Make sure that all your toolpaths are selected before proceeding. I’m going to select “visible toolpaths to one file”. Alternatively, we can do one toolpath at a time if we wanted to do things in batches, for instance
I will choose a post processor. This is what allows the CAM software to present the instructions to the machine in a way it can understand. The ShapeOko and X-Carve use the GRBL post processor. Since I designed in inches, I will select “GRBL (inches)”.
I will then hit “Save Toolpaths” and select my USB drive again. I’ll double check my USB folder and lo and behold it’s there and ready for the ShapeOko!
As you can see, VCarve makes sense with a little guidance. If you are still feeling lost, please do check out some of the video tutorials - they can even get into some of the more powerful design capabilities the software has, such as converting bitmap pictures into GCode. We’ll walk you through setting up the machines in person and supervise your first cuts and can schedule follow-up ones if that makes you feel more comfortable.
Happy milling, I can’t wait to see what you make!