Once your gShield is powered on and you have the stepper motors moving. It’s time to dial in the machine movements to create the desired motion by updating the GRBL settings. This is done using the command line interface which in my case is accessed through the Universal Gcode Sender.
If you don’t already have Universal Gcode Sender and GRBL installed, click here for a step by step guide to setup your DIY CNC Controller.
Display Current GRBL Settings
There are quite a few GRBL settings that we can adjust to get our CNC machines to do exactly what we want. I found it was easier to refer back to a single sheet while setting up my machine as opposed to going back and searching the GRBL wiki page. To download a copy of this cheat sheet, click the link below.
Get Your GRBL Pocket Guide Here
The first step is to see your current settings. Type “$$” to display the available user defined settings in the console window.
For a complete list check out the GRBL wiki available by clicking here.
Here, we are interested in the “Steps/mm” settings.
$100=314.961 (x, step/mm)
$101=314.961 (y, step/mm)
$102=78.740 (z, step/mm)
Note these were not the default settings on my system. How did I get 314.961? Good question. All it takes is some quick math and a few pieces of information.
Lead Screw Pitch = .200 inches (inches per revolution)
Stepper Motor # of Steps per Revolution = 200 (steps/revolution)
Micro Stepping Setting = 8X
I am using .200 inch pitch lead screws, my stepper motors are 200 steps per revolution and my stepper motor controller is set to 8X micro stepping for the x & y axis.
Calculating the “step/mm” Value
Lets break it down one step at a time.
After a few quick calculations you have the values you need. Update the GRBL settings by typing the following into the command line.
$100 = 314.961
This will set the X axis steps per mm. Repeat the process for the Y and Z axis using $101 and $102 respectively.
Note the Z axis setting is different because I am running a lower micro stepping count of 2x to get a little more power to lift the head of the mill.
Remember, these are just initial values to get you int the ball park. We will need to use a dial indicator and tweak the values to get the most accurate motion. More on that in the future.
Are you building a CNC mill? Are thinking about building one? Are you simply fascinated by CNC machines like me? Tell us what you want to make in the comments below.
Thanks for reading. Until next time…