This post is also available in: Français (French) Italiano (Italian) Deutsch (German) 日本語 (Japanese)
We created the Machining Fundamentals series to help you brush up on your CAM knowledge, whether you work in a machine shop or are just getting started. In-house machinists at our Birmingham Technology Center host each episode and provide a detailed overview of a tool/process. In the last edition, we covered tool length offset. Here we cover how to make your CNC machine move using NC-code.
NC-code is a CNC machine’s language. These commands are programmed into Fusion 360 and tell your machine how to cut a part. Post-processors turn toolpaths into NC-code in Fusion 360.
G-code and M-code
Let’s look at G-code and M-code, the two most common types of NC-codes.
First, to turn the spindle on, we type M03 into the controller. To tell the machine how quickly to rotate the spindle, we must program its spindle speed. By typing S1000 M03 and pressing Cycle Start, the machine turns the spindle on at 1,000 revolutions per minute (rpm). Another handy code is M08, which tells the machine to turn on the coolant.
Linear moves with G-code
Next, we’ll examine linear moves with G-code. In the Fusion 360 Manual Data Input (MDI) mode, we can enable the G54 coordinate system. Typing G0 (G zero) on the controller instructs the machine to move as quickly as possible to a known point. This is called a rapid move.
We can program the machine to go as fast as possible to specific work coordinates—for example (X0, Y0)—by typing G0 X0 Y0 (G zero X zero Y zero).
As you can see, NC-code is essential for telling a CNC machine where and how to move. Fusion 360 empowers machinists to take a toolpath and turn it into NC-code — a language that machines understand.
Check out the full Machining Fundamentals series:
Milling Machines
Milling Tools
Lathes
Post Processors
Toolpaths
Work Coordinate Systems (WCS)
Tool Length Offset
Feeds and Speeds