Commit e4b26392 authored by Erik Strand's avatar Erik Strand

Add a partial CNC machining page

parent 4ee41003
+++
title = "CNC Machining"
date = "2018-10-17"
menu = "main"
weight = 8
+++
## Make Something Big
I've been waiting for this week. Having just moved from California, my aparment is in need of some more furniture. My most pressing need is additional shelving.
### Design
I want a shelving unit that fits exactly between two doors in my bedroom, and occupies all the space between the floor and ceiling. To enable laziness, I'm also taking as a design constraint the ability to assemble and dissamble the shelves without any glue or fasteners. I'm aiming for solid slot joints.
I started by drawing a parametric model in Fusion 360.
![](/img/07_fusion_design.jpg#c)
I then wrote my own code to generate the 2d profiles of each piece, rather than exporting them from Fusion. This is mostly because I'm curious to think about what primitives a code based CAD environment for panel structures should provide. But it also means I don't have to fix a few nuisances in the Fusion model, such as some infinitesimally thin surfaces left over from extruded cuts, and the fact that some beams repeatedly move to new locations despite the fact that they're in a rigid group (the only fix I've found is deleting the pattern feature and recreating it, with identical settings).
My code exports SVG images, because they're easy to write. (On this site it's in a raster format, since my SVGs don't respect the viewport defaults that browsers use.)
![](/img/07_2d_design.png#c)
### Test Model
To ensure that my generated 2d patterns are correct, I cut a 1/4 scale model out of cardboard with a laser cutter. It fits together nicely. If only this actually meant that my full-scale model would as well.
### Machining - Attempt 1
I reserved a block of time on Tuesday. The first hurdle I encountered is that VCarve can't import SVG files. So to load my models, I had to open them in Inkscape, and convert them to EPS. (Rhino won't load SVGs either.)
The second issue I encountered was that VCarve Pro is very hesitant to navigate into narrow slots. I'm using a quarter inch router bit (more on this later), and I would like to use it to cut some quarter inch slots. But VCarve wouln't insert toolpaths until I widened the slots to 0.255 inches. This difference isn't visible, but it's certainly enough to make otherwise tight slot joints sloppy and loose. I figured I could live with this, and expanded all of my model's quarter inch slots.
The quarter inch endmill should have no problem machining half inch slots, and I intentionally undersized these to get a tight fit. Unfortunately, after cutting my test pieces I found that the fit was still very loose. Calipers confirmed that the slots were quite a bit wider than in the model. And while investigating this issue, I also noticed that my whole shelving unit was about a quarter inch wider than it should be. The error in the overall length of my model turned out to be a bug in my SVG generation. The slot size problem I never traced down definitively, but it's likely some combination of error introduced during model conversion and rescaling, runout, and bit deflection.
### Generating GCode
As any [Plethora](https://www.plethora.com/) alum would conclude, I might as well just generate my own gcode. By using line segments and arcs, I can make the files a lot smaller than VCarve (though I'm not sure if it's VCarve that previously exploded the arcs, or InkScape). This required me to implement path offsetting for line segments and arcs, ShopBot code generation, and my own system for tabs.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment