3D Computer Graphics in the Real World
My Account Wish List (0) Shopping Cart Checkout
Wittystore
Login
E-Mail Address:
Password:
Forgotten Password
Sign Up Join Us
// `$_SERVER['REQUEST_URI']` to get the current URL and then check if it contains 'latest-blog' // If the user is using the blog the language menu above is not shown so that the blog is only in english
€
€ Euro £ Pound Sterling $ US Dollar
0
0
0 €0.00
Your shopping cart is empty!
Menu
  • Home
  • 3D Models Download
    • Art
    • DIY
    • Ecolife
    • Garden
    • Home
    • Learning
    • Music
    • Sport
    • Style
    • Board Games
    • Office
    • Toys
    • Characters
    • Collections
      • Baby shower
      • Christmas
      • Earrings
      • Halloween
      • Key-chains
      • Movember
      • Phrases
      • Picks
      • Vehicles
      • Vikings
  • Books
  • Hardware
    • Consumables
      • Filaments
      • Materials
      • Accessories
      • Resins
      • Composite Powder
    • 3D Printers
      • By industry
      • By series
      • By application
      • By technology
      • By materials
    • 3D Pens
    • 3D Scanners
    • Laser Engravers & Cutters
  • Software
    • 3D Modelling Software
    • 3D Printing Software
    • AI Software
    • CNC Software
    • Metaverse
    • Video games
  • Upload

    Share your digital creations!

    upload digital content

    UPLOAD

    Become a Wittyer

    Login/Sign up for a "Wittyer Profile" and upload your content with our easy-to-use tool.

    Choose your licence

    Choose the license that best represents your work between commercial or open source options. Check licences here

    Monetize

    For each download, you will receive up to 85% of the net selling price. Check our royalty options here

  • Customizer3D
  • Blogs
  • 3D Models Download
    • Art
    • DIY
    • Ecolife
    • Garden
    • Home
    • Learning
    • Music
    • Sport
    • Style
    • Board Games
    • Office
    • Toys
    • Characters
    • Collections
      • Baby shower
      • Christmas
      • Earrings
      • Halloween
      • Key-chains
      • Movember
      • Phrases
      • Picks
      • Vehicles
      • Vikings
  • Books
  • Hardware
    • Consumables
      • Filaments
      • Materials
      • Accessories
      • Resins
      • Composite Powder
    • 3D Printers
      • By industry
      • By series
      • By application
      • By technology
      • By materials
    • 3D Pens
    • 3D Scanners
    • Laser Engravers & Cutters
  • Software
    • 3D Modelling Software
    • 3D Printing Software
    • AI Software
    • CNC Software
    • Metaverse
    • Video games
  • Customizer3D
  • Blogs
Blog Category
  • Facts & News
  • Guides & Tutorials
    +-
    • Blender Tools and Commands
  • Tech Explained
  • Industry Insights
You may like
Leaf-Shaped Earrings education filament storing key-chains 3D Printer shipbuilding gifts necklace cookie cutter xmas tree
Home » Tech Explained » What is G-Code?
27 Dec
Share This:
    Share on Facebook X Post to Tumblr Pin it Submit to Reddit Share on LinkedIn Save to Pinboard Send email

What is G-Code?

27 Dec 2017
Published In: Tech Explained Hits: 7013

G-code (also RS-274) is a language in which people tell computerized machine tools how to make something. The "how" is defined by g-code instructions provided to a machine controller (industrial computer) that tells the motors where to move, how fast to move, and what path to follow. The most common situation is that, within a machine tool, a cutting tool is moved according to these instructions through a toolpath and cuts away material to leave only the finished workpiece. The same concept also extends to noncutting tools such as forming or burnishing tools, photoplotting, additive methods such as 3D printing, and measuring instruments.

G-Code is the language used to control CNC machines. It’s one type of CNC programming that CNC programmers use, the other type being CAM programming. Your machine’s CNC controller probably executes g-code. Some machines with proprietary formats can also run g-code. It is the Lingua Franca (working language) of CNC.

In order to make a part on a CNC machine, you tell it how to make the part using a G-Code Program.

Why Learn G-Code?

Even if it is not essential, if you’re interested in CNC machining and 3D printing, you should know a bit of g-code. Nowadays you do not need to buy an industrial machine to make parts. You can use g-code commands on almost all FFF desktop 3D printers. These affordable machines are CNC machines and can be directly controlled using G-Code.

G-Code Dialects

While much of the g-code remains the same from controller to controller, there are important details and defaults you need to be aware of to understand the particular dialect of g-code your controller needs to be happy.

In terms of sheer numbers of users, the Fanuc dialects of G-Code are probably the most common among professionals and Mach3 among hobbyists. This is not to say they are better than other G-Code dialects, just that they are more common and so if you're going to talk to other machinists or move around from job to job and machine to machine, it may be helpful if you're familiar with those dialects and how they differ if your machine doesn't use one of these two controllers.

G-Code has an extremely long history. The first attempts at standardizing it came out of the Electronics Industry Association's RS-274 standard which has evolved to NIST's RS-274NGC standard. The original EIA standards work was begun in the 1960's but the first standard wasn't released until 1980. Even though there are now standards (ISO has one too that is nearly the same as RS-274), it isn't clear how many controllers out there are purely standards based. Indeed, many controls will claim to be some standard or other, but when you look closely at the details they're pretty non-standard.

How Are the Dialects Different?

G-Code dialects differ in a variety of ways. Most manufacturers have added their own little bells and whistles to make their dialect better for competitive and marketing reasons. For example, Haas has a series of special g-codes for pocket milling, as well as some special parameters and capabilities on some standard G-Codes. It pays to understand the special capabilities of your machine because they were probably put there to save time based on feedback the manufacturer got from its customers.

In general, we see the following categories of differences between G-Code dialects:

  • Which G-Codes are Supported. Not all controllers support all G-Codes. For example, many early lathe controls do not support the G71 and similar roughing cycles.
  • G-Code mappings. Sometimes the same function will be supported by different g-code numbers on different controls.
  • Parameters and Macro Programming. Parametric programming with macros is something that emerged after the basic standards were in place. Fanuc Macro B is probably the most common standard for it. Many controls are very limited in their capabilities around Macro Programming and there are a lot of detail differences around exactly how Macros work.
  • Parameters. Many G-Codes need additional information to do their job, so they use other words (letters) to collect that information. Exactly which words collect which information can vary from one control to the next.
  • Formatting. Some controls allow G0 or G00. Some insist on G00. Some allow numbers with no decimal, others insist on a decimal or even a trailing zero. "1", "1.", and "1.0" are all variations that may be accepted, rejected, or required when specifying the number 1.

For simple programs and Manual Data Input Mode (MDI) use, obviously a lot of the above won't matter, but if you need to write complex hand-written G-Code you'll need to be aware of the dialect issues.

Tags: G-code course cnc 3d-printing
Same In Category
  • Blender 2.8x vs Fusion 360
  • What’s the Difference Between PLA, ABS, and Nylon?
  • What is 3D Printing?
  • What does cnc mean in text?
  • What does cam mean in text?
  • Text2STL: Bridging the Gap in 3D Printing While Awaiting AI Advancements
  • Metaverse the next generation of the web
  • List of M-Codes commonly found on FANUC and similarly designed controls
  • List of G-Codes commonly found on FANUC and similarly designed controls
  • Laser Scanning vs Photogrammetry
Related Blogs By Tags
  • ONO Team Finds Solution to Major Board Issues
  • Markforged 3D printer manufacturer to open European headquarters in Ireland
  • What is G-Code?
  • What does cam mean in text?
  • List of M-Codes commonly found on FANUC and similarly designed controls
  • List of G-Codes commonly found on FANUC and similarly designed controls
  • JSCut: Your Free Alternative to MakerCAM for Easy CNC Machining
  • G Code and M Code what's the difference?
  • 3D Printing with PETG
Sign in with Sign inSign inSign inSign in

Find us also on:

About us

Wittystore is a company focused on products that are ingeniously clever in conception, execution and expression.

GET IN TOUCH:

 General Enquiries

 Business Enquiries

 Get Support

Information
  • About Us
  • Create Account
  • Privacy Policy
  • Terms & Conditions
  • Advertisement Rates
  • Licences for Digital content
  • Contact Us
Extras
  • Brands
  • Gift Vouchers
  • Affiliates
  • Specials
  • Site Map
My Account
  • My Account
  • Order History
  • Returns
  • Wish List
  • Newsletter
All rights reserved Wittystore © 2014-2025, Company Reg.No. 544064 Ireland, VAT Registered
secure website