My Haas Welcome,
!
Haas Tooling MyHaas/HaasConnect Sign In Register Haas Tooling MyHaas/HaasConnect Sign Out Welcome, My Machines Latest Activity My Quotes My Account My Users Sign Out
Find Your Distributor
  1. Select Language
    1. English
    2. Deutsch
    3. Español - España
    4. Español - México
    5. Français
    6. Italiano
    7. Português
    8. Český
    9. Dansk
    10. Nederlands
    11. Magyar
    12. Polski
    13. Svenska
    14. Türkçe
    15. 中文
    16. Suomi
    17. Norsk
    18. الإنجليزية
    19. български
    20. Hrvatski
    21. Ελληνικά
    22. Română
    23. Slovenský
    24. Slovenščina
    25. 한국어
    26. 日本語
    27. Українська
  • machines Main Menu
    • Vertical Mills
      Vertical Mills
      Vertical Mills View All
      • Vertical Mills
      • VF Series
      • Universal Machines
      • VR Series
      • VP-5 Prismatic
      • Pallet-Changing VMCs
      • Mini Mills
      • Mold Machines
      • High-Speed Drill Centers
      • Drill/Tap/ Mill Series
      • Toolroom Mills
      • Pocket Mill
      • Compact Mills
      • Gantry Series
      • SR Sheet Routers
      • Extra-Large VMC
      • Double-Column Mills
      • 3+2 Positioning Machines
    • Multi-Axis Solutions
      Multi-Axis Solutions
      Multi-Axis Solutions View All
      • Multi-Axis Solutions
      • Y-Axis Lathes
      • 5-Axis Mills
    • Lathes
      Lathes
      Lathes View All
      • Lathes
      • ST Series
      • Dual-Spindle
      • Box Way Series
      • Toolroom Lathes
      • Chucker Lathe
      • Haas Bar Feeders
    • Horizontal Mills
      Horizontal Mills
      Horizontal Mills View All
      • Horizontal Mills
      • 50-Taper
      • 40-Taper
    • Rotaries & Indexers
      Rotaries & Indexers
      Rotaries & Indexers View All
      • Rotaries & Indexers
      • Rotary Tables
      • Indexers
      • 5-Axis Rotaries
      • Extra-Large Rotaries
    • Special Series
      Special Series
      Special Series View All
      • Special Series
      • EU_Series_Redirect
    • Automation Systems
      Automation Systems
      Automation Systems View All
      • Automation Systems
      • Mill Automation
      • Lathe Automation
      • Automatic Parts Loaders
      • Automation Models
    • Desktop Machines
      Desktop Machines
      Desktop Machines View All
      • Desktop Machines
      • Desktop Mill
      • Desktop Lathe
      • Control Simulator, Standard
      • Control Simulator, Premium
    • Shop Equipment
      Shop Equipment
      Shop Equipment View All
      • Shop Equipment
      • Knee Mill
      • Haas Manual Lathes
      • Haas Saws
    • Fabrication Machines
      Fabrication Machines
      Fabrication Machines View All
      • Fabrication Machines
      • Laser Cutting Machines
      • CNC Press Brakes
    • QUICK LINKS Special Series  Special Series 
      EU SERIES EU SERIES BUILD & PRICE | PRICE LIST BUILD & PRICE | PRICE LIST In-Stock Machines In-Stock Machines WHAT’S NEW WHAT’S NEW YOUR FIRST CNC YOUR FIRST CNC
      SHOPPING TOOLS
      • Build & Price a Haas
      • Price List
      • Available Inventory
      • CNCA Financing
      WANT TO TALK TO SOMEONE?

      A Haas Factory Outlet (HFO) can answer your questions, and walk you through your best options.

      CONTACT YOUR DISTRIBUTOR >
  • Options Main Menu
    • The Haas Control Value Option Packages
      Value Option Packages
      Value Option Packages View All
      • Value Option Packages
    • Product Image Spindles
      Spindles
      Spindles View All
      • Spindles
    • Product Image Tool Changers
      Tool Changers
      Tool Changers View All
      • Tool Changers
    • Product Image 4th- | 5th-Axis
      4th- | 5th-Axis
      4th- | 5th-Axis View All
      • 4th- | 5th-Axis
    • Product Image Turrets & Live Tooling
      Turrets & Live Tooling
      Turrets & Live Tooling View All
      • Turrets & Live Tooling
    • Product Image Probing
      Probing
      Probing View All
      • Probing
    • Haas Chip & Coolant Management Chip & Coolant Management
      Chip & Coolant Management
      Chip & Coolant Management View All
      • Chip & Coolant Management
    • The Haas Control The Haas Control
      The Haas Control
      The Haas Control View All
      • The Haas Control
    • Product Image Product Options
      Product Options
      Product Options View All
      • Product Options
    • Product Image Tooling & Fixturing
      Tooling & Fixturing
      Tooling & Fixturing View All
      • Tooling & Fixturing
    • Product Image Workholding
      Workholding
      Workholding View All
      • Workholding
    • Product Image 5-Axis Solutions
      5-Axis Solutions
      5-Axis Solutions View All
      • 5-Axis Solutions
      • 5 Easy Steps to 5-Axis
    • QUICK LINKS Special Series  Special Series 
      EU SERIES EU SERIES BUILD & PRICE | PRICE LIST BUILD & PRICE | PRICE LIST In-Stock Machines In-Stock Machines WHAT’S NEW WHAT’S NEW YOUR FIRST CNC YOUR FIRST CNC
      SHOPPING TOOLS
      • Build & Price a Haas
      • Price List
      • Available Inventory
      • CNCA Financing
      WANT TO TALK TO SOMEONE?

      A Haas Factory Outlet (HFO) can answer your questions, and walk you through your best options.

      CONTACT YOUR DISTRIBUTOR >
  • Why Haas Main Menu
      Discover the Haas Difference
    • Why Haas
    • MyHaas
    • Education Community
    • Industry 4.0
    • Haas Certification
    • Customer Testimonials
  • Service Main Menu
      Welcome to Haas Service
      SERVICE HOME Operator’s Manuals How-To Procedures Troubleshooting Guides Preventive Maintenance Haas Parts Haas Tooling Videos
  • Videos Main Menu
  • Main Menu
    • View All
    • View All
    • View All
    • View All
      • HTEC Curriculum Support
      • Haas Value Option Packages (VOP) Journey
    • View All
      • Haas 10 kg Cobot Package
      • Cobot Kits
      • DC-1 Drill Center
      • CNC Sales News
      • Do More With Your Haas
    • View All
    • View All
      • contact-us-test
      • 4 - AUTOMATION SYSTEMS
      • Carousel-V2
      • expert test
      • Demo_Day_Trident-test
      • Link Test
      • image-sale-tag-test
      • article-list-test
      • Haas 25 kg Robot Package
      • test-algolia-page
    • View All
      • Choose Options
    • View All
    • View All
    • View All
    • View All
    • View All
      • calc-test
    • View All
    • QUICK LINKS Special Series  Special Series 
      EU SERIES EU SERIES BUILD & PRICE | PRICE LIST BUILD & PRICE | PRICE LIST In-Stock Machines In-Stock Machines WHAT’S NEW WHAT’S NEW YOUR FIRST CNC YOUR FIRST CNC
      SHOPPING TOOLS
      • Build & Price a Haas
      • Price List
      • Available Inventory
      • CNCA Financing
      WANT TO TALK TO SOMEONE?

      A Haas Factory Outlet (HFO) can answer your questions, and walk you through your best options.

      CONTACT YOUR DISTRIBUTOR >
  • Haas Tooling Main Menu
  • Haas Service Parts Main Menu
My Haas Welcome,
!
Haas Tooling MyHaas/HaasConnect Sign In Register Haas Tooling MyHaas/HaasConnect Sign Out Welcome, My Machines Latest Activity My Quotes My Account My Users Sign Out
Find Your Distributor
  1. Select Language
    1. English
    2. Deutsch
    3. Español - España
    4. Español - México
    5. Français
    6. Italiano
    7. Português
    8. Český
    9. Dansk
    10. Nederlands
    11. Magyar
    12. Polski
    13. Svenska
    14. Türkçe
    15. 中文
    16. Suomi
    17. Norsk
    18. الإنجليزية
    19. български
    20. Hrvatski
    21. Ελληνικά
    22. Română
    23. Slovenský
    24. Slovenščina
    25. 한국어
    26. 日本語
    27. Українська
×

Search Results

Web Pages

Images

    • <
    • 1
    • >

G-code, M-code, and Setting

Service Home G51 Scaling (Group 11)

G51 Scaling (Group 11)

G51 Scaling (Group 11)



NOTE: You must purchase the Rotation and Scaling option to use this G-code. A 200-hour option tryout is also available; refer to Option Tryout for instructions.
*X - Center of scaling for the X Axis
*Y - Center of scaling for the Y Axis
*Z - Center of scaling for the Z Axis
*P - Scaling factor for all axes; three-place decimal from 0.001 to 999.999
*indicates optional
G51 [X...] [Y...] [Z...] [P...] ;
The control always uses a scaling center to determine the scaled position. If you do not specify a scaling center in the G51 command block, then the control uses the last commanded position as the scaling center.With a scaling (G51) command, the control multiplies by a scaling factor (P) all X, Y, Z, A, B, and C end points for rapids, linear feeds, and circular feeds. G51 also scales I, J, K, and R for G02 and G03. The control offsets all of these positions relative to a scaling center.There are (3) ways to specify the scaling factor:A P address code in the G51 block applies the specified scaling factor to all axes.
Setting 71 applies its value as a scaling factor to all axes if it has a nonzero value and you do not use a P address code.
Settings 188, 189, and 190 apply their values as scaling factors to the X, Y, and Z axes independently if you do not specify a P value and Setting 71 has a value of zero. These settings must have equal values to use them with G02 or G03 commands.
G51 affects all appropriate positioning values in the blocks after the G51 command.These example programs show how different scaling centers affect the scaling command.G51 No Scaling Gothic Window: [1] Work coordinate origin.


%
O60511 (G51 SCALING SUBPROGRAM) ;
(G54 X0 Y0 is at the bottom left of window) ;
(Z0 is on top of the part) ;
(Run with a main program) ;
(BEGIN CUTTING BLOCKS) ;
G01 X2. ;
Y2. ;
G03 X1. R0.5 ;
G01 Y1. ;
M99 ;
%
The first example illustrates how the control uses the current work coordinate location as a scaling center. Here, it is X0Y0Z0.G51 Scaling Current Work Coordinates: The Origin [1] is the work origin and the center of scaling.


%
o60512 (G51 SCALING FROM ORIGIN) ;
(G54 X0 Y0 is at the bottom left of part) ;
(Z0 is on top of the part) ;
(BEGIN PREPARATION BLOCKS) ;
T1 M06 (Select tool 1) ;
G00 G90 G40 G49 G54 (Safe startup) ;
G00 G54 X0 Y0 (Rapid to 1st position) ;
S1000 M03 (Spindle on CW) ;
G43 H01 Z0.1 M08 (Activate tool offset 1) ;
(Coolant on) ;
(BEGIN CUTTING BLOCKS) ;
G01 Z-0.1 F25. (Feed to cutting depth) ;
M98 P60511 (Cuts shape without scaling) ;
G00 Z0.1 (Rapid Retract) ;
G00 X2. Y2. (Rapid to new scale position) ;
G01 Z-.1 F25. (Feed to cutting depth) ;
G51 X0 Y0 P2. (2x scale from origin) ;
M98 P60511 (run subprogram) ;
(BEGIN COMPLETION BLOCKS) ;
G00 Z0.1 M09(Rapid retract, Coolant off) ;
G50 (CANCELS G51);
G53 G49 Z0 M05 (Z home, Spindle off) ;
G53 Y0 (Y home) ;
M30 (End program) ;
%
The next example specifies the center of the window as the scaling center.G51 Scaling Center of Window: [1] Work coordinate origin, [2] Center of scaling.


%
o60513 (G51 SCALING FROM CENTER OF WINDOW) ;
(G54 X0 Y0 is at the bottom left of part) ;
(Z0 is on top of the part) ;
(BEGIN PREPARATION BLOCKS) ;
T1 M06 (Select tool 1) ;
G00 G90 G40 G49 G54 (Safe startup) ;
G00 G54 X0 Y0 (Rapid to 1st position) ;
S1000 M03 (Spindle on CW) ;
G43 H01 Z0.1 M08 (Activate tool offset 1) ;
(Coolant on) ;
(BEGIN CUTTING BLOCKS) ;
G01 Z-0.1 F25. (Feed to cutting depth) ;
M98 P60511 (Cuts shape without scaling) ;
G00 Z0.1 (Rapid Retract) ;
G00 X0.5 Y0.5 (Rapid to new scale position) ;
G01 Z-.1 F25. (Feed to cutting depth) ;
G51 X1.5 Y1.5 P2. (2x scale from center of window) ;
M98 P60511 (run subprogram) ;
(BEGIN COMPLETION BLOCKS) ;
G00 Z0.1 M09(Rapid retract, Coolant off) ;
G50 (CANCELS G51);
G53 G49 Z0 M05 (Z home, Spindle off) ;
G53 Y0 (Y home) ;
M30 (End program) ;
%
The last example illustrates how scaling can be placed at the edge of tool paths as if the part was being set against locating pins.G51 Scaling Edge of Tool Path: [1] Work coordinate origin, [2] Center of scaling.


%
O60514 (G51 SCALING FROM EDGE OF TOOLPATH) ;
(G54 X0 Y0 is at the bottom left of part) ;
(Z0 is on top of the part) ;
(BEGIN PREPARATION BLOCKS) ;
T1 M06 (Select tool 1) ;
G00 G90 G40 G49 G54 (Safe startup) ;
G00 G54 X0 Y0 (Rapid to 1st position) ;
S1000 M03 (Spindle on CW) ;
G43 H01 Z0.1 M08 (Activate tool offset 1) ;
(Coolant on) ;
(BEGIN CUTTING BLOCKS) ;
G01 Z-0.1 F25. (Feed to cutting depth) ;
M98 P60511 (Cuts shape without scaling) ;
G00 Z0.1 (Rapid Retract) ;
G00 X1. Y1. (Rapid to new scale position) ;
G01 Z-.1 F25. (Feed to cutting depth) ;
G51 X1. Y1. P2. (2x scale from edge of toolpath) ;
M98 P60511 (run subprogram) ;
(BEGIN COMPLETION BLOCKS) ;
G00 Z0.1 M09(Rapid retract, Coolant off) ;
G50 (CANCELS G51);
G53 G49 Z0 M05 (Z home, Spindle off) ;
G53 Y0 (Y home) ;
M30 (End program) ;
%
Tool offsets and cutter compensation values are not affected by scaling.For canned cycles, G51 scales the initial point, depth, and return plane relative to the center of scaling.To retain the functionality of canned cycles, G51 does not scale these:In G73 and G83:
Peck depth (Q)
Depth of first peck (I)
Amount to reduce peck depth per pass (J)
Minimum peck depth (K)

In G76 and G77: The shift value (Q)

The control rounds the final results of scaling to the lowest fractional value of the variable being scaled.

Recently Viewed Items

You Have No Recently Viewed Items Yet

Feedback
Haas Logo

Haas Delivered Price

This price includes shipping cost, export and import duties, insurance, and any other expenses incurred during shipping to a location in France agreed with you as a buyer. No other mandatory costs can be added to the delivery of a Haas CNC Product.

KEEP UP WITH THE LATEST HAAS TIPS AND TECHNOLOGY...

Sign up now!   

HAAS TOOLING ACCEPTS THE FOLLOWING:

  • Service & Support
  • Owners
  • Request Service
  • Operator Manuals
  • Haas Parts
  • Rotary Repair Request
  • Pre-Install Guides
  • Shopping Tools
  • Build & Price a New Haas
  • Available Inventory
  • The Haas Price List
  • CNCA Financing
  • About Haas
  • Accessibility Statement
  • DNSH Statement
  • Export Compliance
  • Careers
  • Certifications & Safety
  • Contact Us
  • History
  • Terms & Conditions
  • Haas Tooling Terms & Conditions
  • Privacy
  • Warranty
  • Haas Community
  • Haas Certification Program
  • Haas Motorsports
  • Gene Haas Foundation
  • Haas Technical Education Community
  • Events
  • Join the Conversation
  • Facebook
  • X
  • Flickr
  • YouTube
  • LinkedIn
  • Instagram
  • TikTok
© 2026 Haas Automation, Inc – CNC Machine Tools

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

2800 Sturgis Rd., Oxnard, CA 93030
Toll Free: (888) 817-4446 / Fax: 805-278-8554