Friday, October 19, 2018

File Preparation and Layout for CNC Routing

This topic discusses preparing a 3D model for 3-axis CNC routing. It's geared towards working with sheet goods (plywood) and toolpath programming in Mastercam. The comments about CAD software are specific to Rhino. It also is written assuming someone else is going to be routing your job (like the lab assistants in the Taubman Fab Lab).

Important Note: If you haven't read it already please see the topic CNC Router - Typical Machining Workflow for an overview of cutting on a router. This topic assumes you understand the basics of the overall workflow.

Preparing to Model

Before you begin your final, accurate 3D model, you need to know the type of material and its thickness. So be sure to measure your material before you begin. For typical Baltic Birch plywood it's going to be around 18mm (0.71"). You need to know what your material is exactly.  This has a big impact on how your parts will fit together. I've seen it as low as 0.68" and as high as 0.72". That difference of 0.04 is huge if you want accurate results!

Make sure you use your measured value in your drawings. For example if you have a mortise sized to accept the material you'll want to draw it to the material thickness exactly. I recommend not 3D modeling joint tolerances (extra offsets to allow the parts to slide past one another). Model them as exact fits - then accomplish the offset in the 2D layout portion of the setup. More on this later...

Once you have your 3D model you'll need to generate 2D curves for the router to cut from.

Commands for Laying Out for Nesting on the Sheet

There are some very useful commands in Rhino to extract the contour and pocket curves from your 3D model. These are:

  • Orient3Pt: This command moves or copies and rotates objects using three reference and three target points. This lets you lay a 3D part down flat on the XY Plane, oriented correctly for curve extraction. Rhino Orient3Pt Help
  • DupFaceBorder: This will give you back the curves from the entire face of a part. This includes the outer contour and any interior curves for joints. Rhino DupFaceBorder Help
  • DupEdge: This creates curves from any selected edge of a surface or solid. Rhino DupEdge Help
  • ProjectToCPlane: Use this command to flatten the selected entities directly onto the construction plane. This is useful to ensure everything is entirely flat (no control vertices or anything not at Z of 0.0. Rhino ProjectToCPlane Help
  • Make2D: This can generate 2D projections of your 3D model. I personally find this less useful than using the commands above on a part by part basis. Rhino Make2D Help
  • SelDup: Use this command, followed by the Delete key, to remove any duplicate lines. Those can confound Mastercam at times (it tries to chain them end to end). This is useful for example after you use Make2D which sometimes introduces lines on top of each other. 

Stock Setup

The stock is the volume of your actual material to route. To create it, draw a rectangular volume (box) for your sheet representing the size of your material. Place one corner at 0,0,0. Place the other corner at the size of your material, for example 4',4',-0.71". For orientation, the short axis of the Fab Lab 3-axis router is 4' and is X. The long axis is 8' and is Y. Note that the top of your material will be Z of 0.0. The stock box should go into negative Z. Everything you wish to route should exist inside your stock boundary.

The lab assistants are taught to program everything absolute. That means all the curves are drawn at Z of 0.0. And they program the router toolpaths to cut to the correct depths. Therefore your layer names should indicate the depths to cut to.

Layer Naming

Have your Rhino file organized by layer based on the type of cutting that you'll do. You'll likely want Contour, Pocket and Drill layers. You should list the tool to use for that operation as well. You should also list the depth of cut in your layer names. That makes it perfectly clear to the toolpath programmer (lab assistant) what operation to use, what tool to use, and what depth to cut at. Here's an example - this is cutting the guitar body shown below:

The red box is the stock, notice that it is in -Z (the top is at 0 and it is 1.75" thick). There are pockets for the pickups, tone controls and neck, all at different depths. There are drill holes for the bridge and neck. And there's a contour to cut the body from the stock. Here are the layer names - note the operation, tool and depth of cut are listed.

In this case the contour will be cut with a 3/8" diameter compression bit, it cuts all the way through the body, so down to -1.75" (the stock thickness).

The pockets will all be cut with a 1/4" downshear bit. However the depth differs for each one.

Some drill holes are cut with an 1/8" brad point to a depth of -0.25". A larger drill will go all the way through to -1.75".

The 3D model is also included for reference. In this way you can measure the geometry to double-check the depths.

Having your file organized in this way will make it much easier to understand for the toolpath programmer who sets up your job to cut. And much less error prone.

Corner Preparation

Cylindrical router bits can't cut square corners, as shown below. Picture a top view of two parts that need to slide together. If the router follows the blue line it won't reach into the corner since the bit is a cylinder.

The actual cut part would look like this: 

You need to clear out that corner material. The usual method is to drill out the corners. Here the circles are the diameter of the drill bit. You can see they just clear the corner.

When drilled the finished parts would look like this, and would slide together.

I've written a utility that runs in Rhino for setting up the drill holes. You can find it here: CNC Corner Fix Utility. It lets you pick the lines which meet in a corner and it'll will add the drill point automatically.

You can also draw your geometry to move past the corners to remove material. This is usually more problematic because the router has to slow down to get into the corner and change direction. When the cutting slows down the friction goes up. So the cutters get hotter. This reduces tool life and can possibly result in the workpiece or spoilboard starting on fire.

Offset for Fit

Here are a few example joints. In each one the offsets for getting a nice fit are discussed. Remember - if the parts are cut to the same size they won't slide past one another to fit. If they are cut too loose, you'll wind up with a weak joint. For a review of this idea see Tolerance Issues in Joint Fit.

Example Joint 1

This joint has two identical parts which half-lap over one another. This joint provides a lot of glue surface area and racking resistance.

The curves for cutting the joint are shown below.

There are two tenons which nest in two mortises. The tenons should be cut slightly smaller and the mortises slightly larger. This is due to the high degree of curvature in the joint. Thus both sides of the joint are offset slightly.

The orange lines are for a pocket. This should be cut slightly outside the line - outside the boundary of the curve. This will make the pocket slightly larger than the 3D model.

The blue lines are for the joint portion of the contour. These lines should be offset inside - towards the center of the piece. This will make the opening slightly larger than drawn.

Example Joint 2

This joint joins two boards together edge to edge using dovetails on each side of the parts.

The curves for cutting the joint are shown below.

When the parts are straight and simple the offset can be tighter. There is a high degree of curvature to this joint. There needs to be extra space between the parts (more than the usual 0.01"). Offset the mortise outside to make it larger by 0.01". Offset the tenon towards the inside to make them smaller by 0.01". This leaves a gap of 0.02" which is larger than usual but necessary to accommodate the curvature. The orange line is a pocket which is offset towards the outside marking larger mortises. The blue line is a contour which is offset towards the inside of the piece resulting in smaller tenons.

Example Joint 3

This corner joint features a dovetailed key to hold the parts together. There are three tenons and three mortises.  

The tenons should be cut slightly smaller or the mortises slightly bigger. Because these parts are fairly simple without a lot of curvature a single offset on one of the mating parts of 0.01" is sufficient.

Many more specific wood joints can be found in this post: CNC Cut Wood Joinery.

Preparing for Cutting

What info should you have before you visit the CNC assistant to set up cutting your job?

Make a list of tools you'll need. For a simple job it might look like this:
  1. 3/8" compression bit
  2. 1/4" downshear endmill
  3. 1/8" brad point drill bit
  4. 1/4" brad point drill bit
Inform them of your exact material thickness.

You need to be present when they are toolpath programming your job. Make sure you watch the simulation to verify that everything has been set up correctly.

See Also

Wood Basics - Overview of hardwood and veneer materials.

Plywood and Fiberboard Sheet Goods - Overview of sheet goods.

CNC Router Tools and Tool Holders - Shows many types of tools used in CNC routing. 

Tolerance Issues in Joint Fit - A discussion of joint fit and the tolerances needed for a good fit.

CNC Router - Typical Machining Workflow - Overview of setting up a job for the router - more general than this post.

CNC Corner Fix Utility - The aforementioned utility for creating the drill holes at the corners for CNC routing. 

No comments:

Post a Comment