G-code Setting Home

Discussion about the arduino based g-code interpreter, grbl
Post Reply
gclayjr
Posts: 2
Joined: Wed Oct 24, 2018 1:17 pm

G-code Setting Home

Post by gclayjr » Wed Oct 24, 2018 4:21 pm

I am new here. I am building an Arduino based CNC mill and I plan on using GRBL. I am currently using a G-Code sender to test my Arduino board, and steppers, which I guess gives me an ability to set home (0-0-0). I notice that most G-code refers to absolute locations, rather than relative locations. I don't recognize any specific G-code that says something like "Set home here!"

Other than using the mystery of G-Code sender software, what would be the proper procedure to position the mill at some location and say "set home here", with a GRBL based Arduino system ?

AtDhVaAnNkCsE

George Clay

twforeman
Posts: 1351
Joined: Tue Jan 29, 2013 4:51 pm
Location: Minneapolis, MN
Contact:

Re: G-code Setting Home

Post by twforeman » Thu Oct 25, 2018 7:05 pm

Ender 3 3D Printer
ShapeOko v3 serial #0004 - upgrade thread
All of my ShapeOko related blog posts

gclayjr
Posts: 2
Joined: Wed Oct 24, 2018 1:17 pm

Re: G-code Setting Home

Post by gclayjr » Fri Oct 26, 2018 3:24 pm

twoforeman

Thank you for your response. I will probably have to reread and ponder the information you referenced in order to better understand it. I am a hobby machinist who is familiar with old manual lathes, and mills. I am a retired software engineer who is quite familiar with common languages such as C++, and JAVA, and I have been tinkering with Arduinos for the past couple of years.

That being said, I am a complete novice in my exploration of CNC milling and G-code. If I understand correctly, a quick summary would be to position the machine at what is to be "home" and send a properly constructed G10 command and that would tell the controller where "home" is.

Maybe I can take this moment to pose another, maybe somewhat philosophical question. I do own an inexpensive 3D printer. I can use some sort of CAD program to draw something. I can create an STL file and bring that file into a "slicer" program and manipulate a few parameters and then generate functioning G-code for the printer to print.

I would like to do something similar with my mill/router. However, it seems intuatively to me, that generating a functioning machine path program (G-code), for removing material to make something from potentially varying stock and a potential for needing to change tools , is not as easy to generalize as building up a shape on a blank table. Am I right? are there special different considerations I need to think through in generating workable G-code for a router or mill to cut something based upon something drawn in a CAD program as opposed to generating workable G-code for a 3D printer?


Again

AtDhVaAnNkCsE

George Clay

twforeman
Posts: 1351
Joined: Tue Jan 29, 2013 4:51 pm
Location: Minneapolis, MN
Contact:

Re: G-code Setting Home

Post by twforeman » Fri Nov 09, 2018 8:21 pm

What you need is a CAM program - Computer Aided Machining.

You would load in the 3D object you created in your CAD program and generate the tool paths required for machining it.

It's a pretty large problem space and difficult to get into in a forum. CAM is not as automated as the slicing programs for 3D printers (I have one) so there is a steeper learning curve.

https://wiki.shapeoko.com/index.php/CAM

The closest thing to a 3D slicer in CAM that I have used is MeshCAM. But I use many different CAD and CAM packages based on the application.
Ender 3 3D Printer
ShapeOko v3 serial #0004 - upgrade thread
All of my ShapeOko related blog posts

Post Reply