Tag Archives: RepRap

RepRap gcode using MeshCAM

Warning – this post was sitting in the drafts, I don’t know how helpful it’ll be but it’s been sitting for 5 years – may as well release the information and hope it helps someone.


If anyone out there is running the RepRap / Makerbot gcode intrepreter for a CNC dremel / router / etc and is trying to use MeshCAM here’s some instructions:

Use MeshCAM as usual, but you’ll want to use this post script (you probably don’t actually need to print all of the XYZ commands when you’re not moving them, but it doesn’t hurt to do it, hence the @ rather than #):
; MeshCAM config
; This config is the basis for the minimum
; gcode output. If you're looking for
; the shortest output file then this is the config
; to start with. Also show how to integrate CutViewer config into
; the output.
; 2/29/04 Changed comments to be enclosed by () rather than start with ;
; Added CutViewer config output
; 5/13/04 Added toolchange gcode
; 2/12/05 Changed name and added units
; 3/17/05 Changed stock definition to use CUTVIEWERSTOCK variable
; 5/19/05 Removed feedrate command for rapid moves
; 5/25/05 Added dummy tool for CutViewer
; 6/27/05 Changed the formats to 1.4 to get 4 decimal places of accuracy
DESCRIPTION = "RepRap GCode-MM(*.nc)"
FORMAT = [F|@|F|1.1]
FORMAT = [X|@|X|1.4]
FORMAT = [Y|@|Y|1.4]
FORMAT = [Z|@|Z|1.4]
START = "%"
; The following is a dummy tool to keep CutViewer from generating an error when G20 is called without a tool
START = "(TOOL/MILL,0.1,0.05,0.000,0)"
START = "G21 ;Metric is good"
START = "G90 ;Absolute Positioning"
RAPID_RATE_MOVE = "G0 [X] [Y] [Z]"
FEED_RATE_MOVE = "G1 [X] [Y] [Z]"
END = "(END)"

Here’s a text version, make sure to rename the extension to .con and put it in your posts folder in the MeshCAM installation directory

RepRap gcode-MM

Next up, open your STL/etc file, set up your tooling, and then the important part:

Your RepRap will not allow you to cross the Z axis, so when MeshCAM creates the gcode and moves the position to positive Z to clear the work surface, your RepRap will toss this command and destruction will ensue. . .  Figure out your retract height, in my case I set it to 2.5mm so I can easily remember it.  You want to take this number, then set your stock size to fit geometry (or as needed), but make sure you add your retract height to the stock height and put it in the Z Position.

For example, I have a 5.08mm block I’m machining, with a 2.5mm retract height.  So I would define my Z Position as 5.08+2.50 or 7.58mm  This will result in your retraction remaining less than 0mm and the machine will actually retract away from the workpiece.

RepRap is Alive!

I’ve been wrenching for a few weeks to machine enough pieces to create a CNC plastic extruder (RepRap / Makerbot). I’ve got the CNC part done, now I have to get the extruder and heated bed up and running so I can start RPing parts.

Sector67 Forum Thread

I’ve gotten a few questions as to what you’re looking at, if you’re completely unfamiliar a visit to Wikipedia should clear things up.

It’s made out of 2″ x 2″ extruded aluminum channel, the railed looking stuff that makes up the top of the arm and the drop for the spindle (dremel) is called 80/20, it’s fairly expensive but is very precise and saves a lot of time for some projects.

The Z axis is the classic over constrained parallel rods, I pulled the rods out of a pair of identical printers and then drilled and reamed to size the end blocks and the slider block, which is just a chunk of delrin plastic. The bad part about using a plastic block for a sliding surface is that you have a drill/ream it over significantly to get it the right size, which in my case just means it’s sloppy and will be replaced by linear bearing when it becomes the weakest link in the machine for precision or stiffness.

The bottom end X-Y axes are THK precision linear bearing. I picked this out of discarded equipment at the university, which I understand it not available to “normal people”. I found out a few years after I picked it up that it’s $0.43/millimeter (yep, that’s a half of a dollar per the thickness of your fingernail, it’s expensive). The bearing carriages are ~$130/each. I was fortunate enough to find a pair of 18″ linear track and a pair of bearings still in their well oiled bags! They do have lash in them and should certainly be run in parallel or with a precision guide track for stiffness/rigidity but for my application (milling light plastics and depositing plastic in an additive process) it’s not a major concern this early in the project.

The other common question is how much does this thing cost. So far I have $199 for the full generation 3 Makerbot electronics (thanks Zach et al., they work great!) and $4.11 for 3 x 1″ long 1/4-20 nuts that are used on each of the axes (True Value). The rest has been collected or given to me by others.