Homebuilt (DIY) CNC Router - Arduino Based (GRBL)




Introduction: Homebuilt (DIY) CNC Router - Arduino Based (GRBL)

Already for a few months or even years, I was planning to build my own CNC milling machine. Now I decided it was time to do it! I read a lot about other DIY projects and in the end I liked the design from the Arduino CNC intstructable that I found here. Although the dimensions were unclear and the programming and calibration was all in Spanish, I figured all that out by myself. In the end, I only used the design for reference.

In this instructable, I'll try to explain my steps, from the very beginning of the design, until the very end of your first gcode.

Note: I used a 3D printer to make some of the parts, but if you're working accurately, it's possible to make these parts from wood as well!


I noticed some movement in my design after the first routings. A solution might be using thicker rods than the 12mm that I used. However: This design DOES work!! I'm currently still improving the design and might update this instructable in the near future! If you have any questions, please ask and I'll try to answer them.

If you like this instructable, please vote for me in the Arduino Contest. :)

Update - December 29th:I'm really blown away by all the interest you're all showing for this project! I'll try to add some results and video's this weekend. Currently I'm routing hard foam, since it's easy to test with. For harder material speeds need to be lower, otherwise the hang-though is a bit too much. I'm looking at a way to fix this (probably thicker rails) and will update this instructable as soon as possible. I know that there are some proven ways to solve this, but it's my goal to make it as cheap as possible. :)

Update - January 3rd: I added some results and video's in step 11. I'm still figuring out the CAM functionality of Fusion 360 and didn't have much time the past days, so the final 'C' is falling of the limits of the foam. ;) However: It's clear that the machine works and that some pretty good quality can be reached!

Update - January 30th: In the past weeks, I updated this instructable for the use of 18mm steel tubes instead of 12mm rods. Also, I designed more 3D printed parts for better/easier alignment of the parts. However, because of vacation and other projects, I haven't had much time to do more tests, so these will follow soon. The design is already much stiffer than before, so I guess I can increase the feedrate, even on wood.

Update - February 3rd: Waahjoo! Although I didn't update this page so much (I AM working on the machine), I just got the news that I won the First Prize in the Arduino all the things Contest! Thanks a lot to everybody who voted! I'm very happy with this!!

Have fun building!

Step 1: Materials

To make this CNC router, I used the following parts:

  • 1 piece of hardwood plywood, thick 18mm, 2.44mx0.61m (€32) (local hardware store)
  • 2 steel rods, diameter 12mm 2 steel tubes, diameter 18x1.5mm, length 900mm (€5.50) (local hardware store)
  • 2 steel rods, diameter 12mm 2 steel tubes, diameter 18x1.5mm, length 528mm (€3.75) (local hardware store)
  • 2 steel rods, diameter 12mm, length 188mm (€1.35) (local hardware store)
  • 12x 4x nylon linear bearing 12mm (€1.50) (local hardware store)
  • 8x nylon linear bearing 18mm (€3.50) (local hardware store)
  • 2x threaded rod, M8, length 1m (€4.70) (local hardware store)
  • 1x threaded rod, M5, length 1m (€2.25) (local hardware store)
  • 2x coupler nut 5mm-M8 (€2) (local 3D print shop, 123-3d.nl)
  • 1x coupler nut 5mm-M5 (€1) (local 3D print shop, 123-3d.nl)
  • 2x NEMA17 (Wantai 42BYGHW811) 1.8 degree/step stepper motor (€30) (local 3D print shop, 123-3d.nl)
  • 1x NEMA17 (Wantai 42BYGHW208) 1.8 degree/step stepper motor (€12) (local 3D print shop, 123-3d.nl)
  • 3x TB6560 stepper driver (€16.50) Ebay
  • 1x 120W (12v, 10A) power supply (€10) Ebay
  • 3x 4pin wire of 1 meter (€6) (local 3D print shop, 123-3d.nl)
  • Some 608 ball bearings (€4) AliExpress
  • 1x Chinese Arduino UNO (€2.50) AliExpress
  • 1x Old laptop / raspberry pi / your own laptop (€??)
  • Some M8 nuts, some M5 nuts and some screws

Total: Around €140,-

Note that this does not yet include the milling device. I used a Dremel 8200 series to start, but will change to add my normal router to it, or make something like a DC spindle onto it.

Step 2: The Design

As explained in the introduction, my hardware design is based on the Arduino CNC instructable, that I found here. Since no exact dimensions etc. were given in this instructable, I made the design all by myself again in Autodesk's Fusion 360.

I designed it to have a range of ±70cm in y-direction, ±40cm in x-direction and ±10cm in z-direction.

Step 3: The Y-assembly

The y-assembly is one of the easiest (and biggest) parts to make. I attached a building drawing, in which all dimensions are in mm's.


  • Where 22-7 is written, this means that you need to drill a hole with a diameter of 22mm, and only 7mm's deep. This is for the bearings.
  • Panel A-A and C-C are identical.
  • Panel B-B and D-D are almost identical: In panel B-B you need to drill 1 22mm hole for the coupler nut between the stepper motor and the threaded rod. In panel D-D you don't drill this hole.
  • The 12mm holes in panels B-B and D-D are only 9 mm deep.

Update: 12mm rods seemed to hang through too much. Therefore, the design was changed for the use of 18mm tubes. The drawing with dimensions stays the same, ONLY in case of drilling 12mm holes, 18mm holes have to be drilled!

Before screwing the 80mm and 70mm pieces together, attach the first NEMA17 42BYGHW811 stepper motor to panel B-B. Then, attach the coupling nut and the threaded rod (cut it to 750mm) to the stepper motor. Now you can screw the 70mm and 80mm pieces together but don't attach the large board yet. Otherwise we won't be able to attach the x-assembly. You'll end up with something that looks like figure 3.

Step 4: The X-assembly

The x-assembly contains some 3d printed parts. You can find these all on Thingiverse. For the x-assembly, you'll need:

  • 4x XY-joint
  • 2x Y-nut-holder

You can also make these parts from wood, but then you'll have to be a bit more creative yourself. :)

Saw the wood as shown in drawing, but don't screw all parts together before the Z-Block is finished (next step).

Note: In the left side panel, the 22mm hole is only 7mm deep (bearing) and the 10mm hole goes through. In the right panel, the 22mm hole goes through (because of the coupler nut).

Update: Just like the Y-Assembly, the 12mm rods have been replaced by 18mm tubes. Also, there are now some 3d printed parts used to help aligning these tubes. They are upload to thingiverse as well. Again: If you work accurate enough, it might not be necessary to use these 3d printed parts and make it from wood.

Step 5: Z-block Assembly

One of the most difficult part is the Z-block. Drilling of the holes has to be very precise, otherwise the friction will be too high, since the steel rods won't be perfectly aligned with the holes in the side panels of the x-assembly. My tip is to use a mitre saw to cut the wood and a drill press to make the holes! For the larger holes, I first used a drill press to make a start and then a router to make enough space.

All black parts in the design are 3d printed, since it's easier to gain high accuracy then. Those parts can be found on the thingiverse link from the previous step. The white thingies are the nylon bearings.

The wood needs to be sawn and drilled as shown in figure 2.

Step 6: Assemble All Hardware

Now start assembling all parts. Begin with the Z parts, then connect them to the X-frame. Then attach the bottom part of the x assembly and attach all to the Y-axises. The 3D printed Y-Nut, X-Nut and Z-Block parts have space for a nut that goes over the threaded rods. Use these!

After assembling, make sure that you can move each axis by turning the threaded rod by hand. If this is very difficult, your alignment is probably wrong, causing a lot of friction. Reassemble and realign until this is all good!

In the end, you should end up with the full assembly as shown in the second image.

Step 7: Motordrivers and Wiring

With the motor drivers I used, the wiring should be as shown in figure 1. The ground on the left of the image, is the ground from the arduino (not from the 12v power supply).

The Phase A and Phase B can be found using a simple multimeter: The resistance over a phase (A+ and A- for example) is zero. For the wiring, it doesn't matter which one is A+ or A-, as long as the resistance between both A wires, is zero. Same for the B phase.

The switches on the motor driver are not really clear to me yet, but with S3 and S4 switched in this way, the step size will be 1/8 of the normal step size, resulting is much more gentle and precise steps.

The wiring on the Arduino is as explained in the grbl wiki on Github. For the minimum basics, we only have to wire digital pins 2-7 and GND to the stepper driver boards.

Step 8: Flashing the Arduino

Download and extract GRBL from Github and open the Arduino IDE. Via Sketch -> Include Library -> Add zip library select the 'grbl' directory from the just extracted folder. Restart the arduino IDE and under file -> Examples, there should now be a grbl example, named grblUpload. Open it and upload it to the Arduino.

Now open the Serial monitor (under Tools) and set baudrate to 115200.

You should now get the message 'Grbl 0.9j ['$' for help]'

So enter $ and hit return. Now enter $$ and hit return. There you should see all the current settings for your grbl, which should be as default. Now, you can change everything you need. Details are explained on the grbl Github. My settings are as attached, but if your axis move in the wrong direction (because you might have B- and B+ different for example), you should switch these.

Step 9: The First Circle

When the building and the flashing is done, it's time to do something! Download the Universal G-Code Sender here (info on Github, here) and connect to your Arduino with a baudrate of 115200 again.

Now power up your power supply and go to 'Machine Control'. You should now be able to move your machine using the controls on this display!!

Hook up a pen to your z-axis, and save this text (using notepad) as circle.gcode:

G17 G20 G90 G94 G54
G0 Z0.25X-0.5 Y0.
G01 Z0. F5.
G02 X0. Y0.5 I0.5 J0. F2.5
X0.5 Y0. I0. J-0.5
X0. Y-0.5 I-0.5 J0.
X-0.5 Y0. I0. J0.5
G01 Z0.1 F5.
G00 X0. Y0. Z0.25

When you go to the File Mode tab in the Universal G Code Sender, you open circle.gcode and as soon as you click Send, your machine should now start painting a circles with a diameter of exact 2 inches!

Step 10: Finishing

As soon as you know your machine is working, it's time to hook up your router of dremel to start milling! Because every router is different from others, you have to be a bit creative yourself. But when you have come this far, I'm sure you'll get your router attached!

Good luck!

If you liked this instructable, please vote for me in the Arduino Contest. :)

Step 11: Update: Seeing It Work

Ok, I was lacking some time this past week, but since I promised to show you guys some results, I did my best. I'm still figuring the CAM functions of Fusion 360 out, so as you can see in the images attached: The starting point of the sample was not correct, so that the final 'C' didn't fit. This had nothing to do with the machine, but with my abilities with Fusion 360.

As you can see: The finishing of hard foam is pretty good!

Note: The wooden piece is there to press the foam down. I didn't fix it too well, so it moved up a bit.

I'm very happy with the result so far!!

Step 12: After a Few Weeks

Ok, we're now a few weeks later. I tested some more and I'm very happy with the updated design.

Some facts:

  • I can route hardwood-plywood at a federate of 400mm/min with a 6mm 4-flute router bit and a depth of 2mm per pass.
  • I also tried the same feed-rate and same router with with a depth of 4mm per pass, but this caused the wood to burn because the friction was too high. The accuracy however, stayed acceptable, but I don't recommend this setting.
  • Because I used threaded rods instead of leadscrews, I have some backlash on the y-axis. This results in flattened circles. I can probably tune this a bit by tweaking the nuts under the x-gantry, but I'll probably switch to lead screws in the future.

Like I said: I'm very happy with it! Now I need more projects to use it for. ;-)

Arduino All The Things! Contest

First Prize in the
Arduino All The Things! Contest

2 People Made This Project!


  • Cold Challenge

    Cold Challenge
  • Block Code Contest

    Block Code Contest
  • Baking Contest

    Baking Contest



Question 3 months ago on Step 12

I am curious to know why you used 2 stepper model 42BYGHW811 & 42BYGHW208 instead of three of the same?


6 months ago

You can reduce backlash even with threaded rods by using antibacklash nuts. These use a spring and another nut to push the two nuts to opposing sides of the thread.


10 months ago

Looks good will have to get all the parts and start my machine.


1 year ago

It was interesting. Thank


Question 3 years ago on Introduction

Congratulations brother for your good struggle. I also try the same thing to make but I disappointed. I bought some hardware and connected with computer but stepper motor not run, I used stepper driver TB600, stepper Motor NEMA 23 Model 23SH5628, Mach 3 interface card and power supply 12V 33A. All the wiring and configuration was ok but they does work. Dear brother advice me for success of my project, please.


Answer 2 years ago

can you tell me exactly what your problem is ?


Question 2 years ago on Step 12

Do you know of any hardware stores which ship overseas? I cannot find reasonable prices on most of the hardware items you have listed (tubes, rods, linear bearings).


Answer 2 years ago

Ali Express ;-)


2 years ago

I've got a CNC already but it's too small for my needs.

Great project. I'd love to make someting like that. I have doubts on some issue. Especially on the long axis, I wonder if the two 18mm tubes are rigid enough. I wondered if it would not improve things to opt for a roller design that would have the drawback of counting on the weight of the moving parts not to lift up.

On the other hand the 18mm tubes may be overkill for Z and probably Y axis. 18mm linear bearings are indeed hard to find.

Aren't Nema 17 a bit weak for that project ? I'd use at least 2.8A Nema 23.

Best solution for motor drinver in my opinion is Arduino UNO + Proteneer 3.51 + 3xTMC2209.

Using lead screws seem very important too.

My other concern is the use of a dremel. Seem hard on a dremel to mount 6 mm router bits that are very interesting for roughing passes. From my experience a good spindle is really critical.

Limit switches are mandatory in my opinion to make it possible to change tools and have a reproducable positionning.

All this lets i be a bit more expansive but much better result


Question 2 years ago on Introduction

I would like to make this project, so I would ask you:
If it's possible, Can you zip (only Autodesk Fusion 360 project), and how to downloading?


Question 2 years ago

heb je toevallig ook een 3d model in met alle onderdelen dat mag uiteraard in Autodesk's Fusion 360. er zijn nog wat dingen onduidlijk voor mij, ik heb zelf geen 3D printer maar kan beschikken over een profesionele freesbank, en dan zou ik die kunnen uit frezen,


Question 3 years ago on Step 6

This looks great i want to do it but we dont have 3d printer
what should i do?


Answer 2 years ago

You can email to places that print 3d printers, or you can make them from materials such as wooden plastic, or you can get help from industry or engineers


Question 4 years ago

Hi, dumb question; which diameter do you mean on the bearings? And on the rods what does 18x1.5 mean?


Answer 3 years ago

18mm = approx metric version of 3/4 inch (should be 20mm for a more exact match) and 1.5mm = 1/16 wall thickness (could go thicker 3mm= 1/8 inch) wall but that does both increase weight and adds stability)


Question 4 years ago on Step 1

Great job. I plan to build one acc. your instruction. I already have most of the part for it, but I have few comment on that.
Not all the 3d printed parts updated some of them valid for the original rods (12mm)! I realized after print out, that can not be use. : o (
I can't buy in Europe Linear bearings in size 18 for the D18x1,5 Steel rods.
I soo sad, because I drilled all the wood parts for it, I purchased the tubes, than I realized that the available linear bearings in the market 8-10-12-16-20, no for D18 !
I think I will change back to 16mm steel tubes so I can use the wooden parts with holes, with metal bush (Inner diameter 16mm outer 18mm).
Can you share with me the reason, why you changed from D12 to D18? I know its much robust, but might be D16 rod or tube enough ? Thanks for your time to answer in advance.


4 years ago

Hi, Great share and am currently in the process of making, ive changeed the 18mm tubing to 19mm (3/4 inch) its a lot easier to get hold of here in the uk. Im also trying to get hold of you grbl settings for the arduino, It says they are attached somewhere here but ive been unable to find them. can someone point me in the right direction.



Reply 4 years ago

I'm also trying to build this in the UK, and like you, finding it much easier to find 3/4 tubing. However, I'm drawing a blank on 3/4 nylon linear bearings. Where did you find these?


Reply 4 years ago

I started off by following this build, but it was obvious that it’s only very basic and not upto much, although it’s a great start in to cnc. take a look at Will’s garage http://willysgaragenorway.no/category/cnc/. A lot more intuitive and easy to follow. I’ve coupled it with an Er11 spindle from eBay for £20 which is perfect for me, a lot better than burning out another Dremel