Multi-axis machining with Fusion
Published

External Input for Programmed Values

Parametric programming provides three easy ways to access external data.

Share

Standard CNC programs lack intelligence. They are executed sequentially, commands result in predetermined action/s and words for each command are fixed.

Parametric programming provides additional capabilities, and various compensation types such as fixture offsets, tool length and cutter radius compensation allow programs to reference data from outside the program. These data are typically stored in offset registers and affect the way a CNC program performs.

Certain applications require CNC programs to access other data from outside the program in much the same way that compensation does. These applications exceed the limits of what is possible with standard G code. With parametric programming, however, it is easy to make programs access external data.

Sources for external data include offset registers, permanent common variable registers and input signal terminals on a printed circuit board. Parametric programming system variables allow access to each type.

For offset access, most CNCs use a system variable name or number that corresponds to the offset register being accessed. For a popular FANUC CNC machining center model, system variable #2001 provides reading and writing access to the register for geometry offset number one, #2002 provides access to register number two, and so on. While each kind of offset is accessed with a different series of system variables, rest assured that you can access any offset register if you know the corresponding system variable name or number.

Permanent common variables are much like offset registers. You can enter them using the MDI panel keyboard, or data can be entered by some other source (maybe the results coming from a probing program). While the naming/numbering for these system variables vary, FANUC uses a series of system variables beginning with #500 to access them. Permanent common variable #501, for example, is used to access (read and write) the value in the permanent common variable register number 501.

Input and output terminals are accessed through a series of system variables ranging from #1100 to #1131 for inputs and from #2000 to #2031 for outputs. Each corresponds to a printed circuit board terminal location. If the terminal is active/on (current is flowing), the value of the corresponding system variable will be 1. If the terminal is inactive/off (current is not flowing), its value will be 0. For example, when terminal location number 2 is active, the value of system variable #1102 will be 1.

Which method you will use to store/access data will depend on your application. Sometimes it makes sense to place related data in offset registers, especially if the data is related to workholding or cutting tools. Other times, it is more logical to place the data in permanent common variables, especially if the data is more related to machine usage than tooling. Input/output terminals are important if external devices are being used that must provide feedback information to the CNC.

How data are placed in data registers also varies. In some applications, the operator will enter data through the MDI panel keyboard. In others, the data are entered by an external device, like a touch probe or post process gaging system. In another application, a machine sensor (like one that monitors the angular position of a rotary table) is connected to an input/output terminal.

What are some ways to access external CNC program data?

Here are three ways to access external data, with an example for each application:

  1. Offset Register Access: Enhancing Wear Offsets

There are times when the turning center operator cannot easily determine the amount of adjustment needed for a sizing adjustment. Consider a dimension specified over a ball (see Figure 1). Instead of calculating the offset adjustment amount, which requires trigonometry, have the operator store the measurement taken over the ball in an unused offset register. The program can then reference this value in a calculation that determines how to adjust the X- and Z-axis motions required to correctly machine the taper.

  1. Permanent Common Variable Access: Automating Program-Zero Assignment

The center of a round workpiece, when held in a V-block clamp (see Figure 2), will vary in a predictable way based on workpiece diameter. Instead of measuring this position every time a setup is changed, have the operator enter the workpiece diameter in a permanent common variable. The program can reference this value to determine the center position and then specify an appropriate value into the corresponding fixture offset register.

  1. Input Signal Terminal Access: Determine Rotary Device Position

If a rotary table is in the wrong angular position when a program is activated or restarted, the results could be disastrous. A sensor mounted to the rotary table (possibly a limit switch) can be connected to an input signal terminal in such a way that, when the appropriate side of the table is facing the spindle, the current will flow at the terminal. The program can test whether this terminal is active. If it is not, it can generate an alarm.

HCL CAMworks
ProShop
SmartCAM
Surface finishing in Fusion
Koma Precision
DNS Financial Services America
The Automated Shop Conference
World Machine Tool Survey
Discover a variety of the best CNC machines
IMTS 2024
Techspex
EZ Access - Have it all with Ez - Mazak

Related Content

Sponsored

How to Mitigate Chatter to Boost Machining Rates

There are usually better solutions to chatter than just reducing the feed rate. Through vibration analysis, the chatter problem can be solved, enabling much higher metal removal rates, better quality and longer tool life.

Read More

7 CNC Parameters You Should Know

Parameters tell the CNC every little detail about the specific machine tool being used, and how all CNC features and functions are to be utilized.

Read More

5 Reasons Why Machine Shop Ownership Is Changing

Mergers, acquisitions and other ownership changes are an effect of Boomer-age shop owners retiring, but only in part. Also important: The way we think about machining has changed.    

Read More
Basics

6 Machine Shop Essentials to Stay Competitive

If you want to streamline production and be competitive in the industry, you will need far more than a standard three-axis CNC mill or two-axis CNC lathe and a few measuring tools.

Read More

Read Next

Basics

Obscure CNC Features That Can Help (or Hurt) You

You cannot begin to take advantage of an available feature if you do not know it exists. Conversely, you will not know how to avoid CNC features that may be detrimental to your process.

Read More

3 Mistakes That Cause CNC Programs to Fail

Despite enhancements to manufacturing technology, there are still issues today that can cause programs to fail. These failures can cause lost time, scrapped parts, damaged machines and even injured operators.

Read More
Micromachining

A History of Precision: The Invention and Evolution of Swiss-Style Machining

In the late 1800s, a new technology — Swiss-type machines — emerged to serve Switzerland’s growing watchmaking industry. Today, Swiss-machined parts are ubiquitous, and there’s a good reason for that: No other machining technology can produce tiny, complex components more efficiently or at higher quality.

Read More
SmartCAM