0% found this document useful (0 votes)
24 views37 pages

Unit III Learning Material

Uploaded by

kk11091079
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
24 views37 pages

Unit III Learning Material

Uploaded by

kk11091079
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 37

CAD/CAM

UNIT –III
NUMERICAL CONTROL
Syllabus : NC, NC modes, NC elements, NC machine tools, structure of CNC machine
tools, features of Machining centre, turning centre.
CNC part programming: fundamentals, part programming methods.
Course objectives:
 To present the role of computers and technology that drives the modern industry.
Learning outcomes:
Upon successful completion of the course, the students will be able to
 appraise the role of computers in manufacturing
Numerical Control (NC):
Numerical control of machine tools may be defined as a method of automation in which various
functions of machine tools are controlled by letters, numbers and symbols.
In NC machine tools one or more of the following functions may be automatic:
a. Starting and stopping of machine tool spindle
b. Controlling the spindle speed
c. Positioning the tool tip at desired locations and guiding it along desired paths by
automatic control of the motion of slides
d. Controlling the rate of movement of the tool tip (i.e. feed rate)
e. Changing of tools in the spindle
Components of NC:
An operational numerical control system consists of the following three basic components:
1. Program of instructions
2. Controller unit, also called a Machine Control Unit (MCU)
3. Machine tool or other controlled process
Figure: Components of NC System
Program of Instructions:
The program of instructions is detailed step by step set of directions which tell the machine tool
what to do and in what sequence. The part program is written in coded form and contains all the
information needed for machining the component. The part program is fed to the machine
control unit through some input medium. Various types of input medium are:
a. Punched cards
b. Magnetic tape and floppy disks
c. Paper tape
a. Punched cards: These were once widely used as a medium for data input in all numeric
control systems. A typical punched card used in IBM systems has 80 columns and each
column numbers which identified the punching position. There are 12 punch positions or
rows in each card designated as 12, 11 and 0 to 9. For any numeric and alphabet to be
punched on the card, a code is used and rectangular blocks are punched on the card at one or
more places.
b. Magnetic Tape and Disk: These are widely used for data storage as well as data input to NC
systems. The data is stored in the coded form by means of magnetised spots on magnetic
medium in both cases. Magnetic tapes used in NC system are identical to the tape used in
common home tape recorder. The width of the tape is 6 mm or 25 mm.
c. Punched Tape: It is widely used for feeding the programme to NC systems. A standard tape
size is 25 mm wide. The punched tape has capacity for storing 10 characters per 25 mm
length. There are 8 tracks on the tape, which are used for punching the information in coded
form. The adjacent to track 1 is called reference edge. A row of small holes between track 3
and track 4 is used for feeding the tape into the tape reader. The information required to
machine the component is punched on the tape by a tape punching device.
Controller Unit:
This consists of the electronics and hardware that read and interpret the program of instructions
and convert it into mechanical actions of the machine tool. The typical elements of a
conventional NC controller unit include:
a. Tape reader
b. Data buffer
c. Signal output channels to the machine tool
d. Feedback channels from the machine tool.
e. Sequence controller
The tape reader is an electromechanical device for winding and reading the punched tape
containing the program of instructions. When a punched tape is passed through a punched – tape
reader, electric connections are either close or open depending on whether there is a hole
punched at a particular track or not. The coded instructions on the tape are transformed into their
electric analogues which are utilized for controlling the various machine tool functions. The
punched tape readers commonly used are mechanical (electro – mechanical), Photo electrical and
Pneumatic readers.
The data contained on the tape are read into the data buffer. The data buffer stores the input
instructions in logical blocks of information. The signal output channels are connected to the
servomotors and other controls in the machine tool. Through these channels, the instructions are
sent to the machine tool from the controller unit. To make certain that the instructions are sent to
the machine tool from the controller via the feedback channels. The most important function of
this return loop is to assure that the table and work parts have been properly located w.r.t . the
tool.
The sequence control coordinates the activities of the other elements of the controller unit. The
tape reader is actuated to read data into buffer from the tape, signals are sent to and from the
machine tool, and so on. These types of operations are to be synchronized and this is the function
of the sequence controls.
Machine Tool or other Controlled Process:
It is the part of NC which produces the useful work. In a numerically controlled machine all the
movements of the tool and the machine table are done automatically with the help of electric
motors. For example, in case of CNC lathe the longitudinal and transverse movements of the tool
are controlled by two motors fitted on the machine i.e. one for longitudinal movement and the
other for transverse movement of the tool. In addition, the speed of the spindle motor is
controlled by the part programme. The machine may have a tool magazine, so that tool changing
is done automatically. Also the other functions like machine ON/OFF, coolant ON/OFF, etc. are
controlled through the part programme. The motors used for controlling the speed, feed and
depth of cut are either servomotors or stepper motors which enable the user to select any desired
speeds and feeds.
The NC Procedure:
To utilize numerical control in manufacturing, the following steps must be accomplished:
1. Process Planning: The engineering drawing of the work part must be interpreted in
terms of the manufacturing processes to be used. This step is referred to as process
planning and it is concerned with the preparation of route sheet. The route sheet is a
listing of the sequence of operations which must be performed on the work part along
with the required machining data like speeds, feeds, depth of cut, tool used, etc. It is
called route sheet because it also lists the machines through which the part must be routed
in order to accomplish the sequence of operations.
2. Part Programming: Part programming plans the process for the portions of the job to be
accomplished by numerical control. There are two ways to develop programme for
numerical control machines:
a. Manual Part Programming: In manual part programming the machining
instructions are prepared on a form called a part programme manuscript. The
manuscript is a listing of the relative cutter/ work piece positions which must be
followed to machine the work piece.
b. Computer Assisted Part Programming: In computer assisted part programming
much of the tedious computational work required in manual part programming is
transferred to computer. This is especially appropriate for complex work piece
geometries and jobs with many machining steps. Use of the computer in these
situations results in significant saving in part programming time.
3. Tape Preparation: A punched tape is prepared from the part programmer’s process plan.
In manual part programming, the punched tape is prepared directly from the part
programme manuscript on a type writer like device equipped with tape punching
capability. In computer assisted part programming, the computer interprets the list of part
programming instructions, performs the necessary calculations to convert this into a
detailed set of machine tool motion commands, and then controls a tape punching device
to prepare the tape for the specific NC machine.
4. Tape Verification: After the punched tape has been prepared, some method is usually
provided for checking the accuracy of the tape. Sometimes the tape is checked by running
it through a computer programme which plots the various tool movements on paper. In
this way a major errors in the tape can be checked. The “acid test” of the tape involves
trying out on the machine tool to make the part. Foam or plastic material is sometimes
used for this tryout.
5. Production: The final step in numerical control procedure is to use the part programme
in the production. This involves ordering of raw work parts, specifying and preparing the
tooling and any special fixturing that may be required and setting up the numerically
controlled machine tool for the job. The machine tool operator’s function is to load the
raw work part in the machine and establish the starting position of the cutting tool
relative to the work piece. The numerical control system then takes over and machines
the part according to the instructions on tape.
NC Classification:
NC machines are classified based on two criterias:
a. Based on feedback control
b. Based on control system features
Classification based on feedback control: A NC machine can be controlled through two types
of control circuits, which are open loop and closed loop.
In the open loop system, the signals are given to the motor by the processor, but the movements
and final destinations of the worktable are not accurate. The open loop system cannot accurate,
but it still can produce the shape that is required.

Figure: Open Loop NC Control System


The closed loop system is equipped with various transducers, sensors, and counters that measure
the position of the table accurately. Through feedback control, the position of the worktable is
compared against the signal. Table movements terminate when the proper coordinates are
reached. For the close loop system normally servomotor is utilized. For open loop system
normally the stepper motor is utilized. The closed loop system is more complicated and more
expensive than the open loop.

Figure: Closed Loop NC Control System


Classification based on control system features: There are two basic types of control systems
in numerical control, point-to-point, straight cut and contouring.
In Point-to-Point system, also called positioning, each axis of the machine is driven separately
by ball screw, depending on the type of operation, at different velocities. The machine moves
initially at maximum velocity in order to reduce non-productive time, but decelerates as the tool
reaches its numerically defined position. Thus in an operation such as drilling or punching, the
positioning and cutting take place sequentially. The time required in the operation is minimized
for efficiency. Point-to-point systems are used mainly in drilling, punching, and straight milling
operations.

Figure: Point to Point Control in NC


The Straight Cut System is an extension of point – to – point system with the provision of
machining along a straight line as in case of milling and turning operations. This is obtained by
providing movement at controlled feed rate along the axis in the line of motion. It is possible to
machine along diagonal lines with the movement in two axis at a controlled feed rate. However,
in such cases the control system must be capable of calculating and displacing the slides
simultaneously at suitable feed rates to reach the desired points because in this case the feed rates
along different axis will have to be different.

Figure: Straight Cut control in NC

In the Contouring System, also known as the continuous path system, positioning and cutting
operations are both along controlled paths but at different velocities. Because the tool cuts as it
travels along the path, accurate control and synchronization of velocities and movements are
important. The contouring system is used on lathes, milling machines, grinders, welding
machinery and machining centres.

Figure: Continuous Path Control in NC

Structure of CNC Machine Tools:


While designing the machine tool structure, it is important to provide sufficiently high static
stiffness along with the best stiffness- to-weight ratio. The stiffness-to-weight ratio is important
to achieve better dynamic response.
Typical machine tool structures used in CNC machine tools are generally cast-iron based with
heavy ribbing to provide high stiffness and low weight further the cast-iron structure provides the
necessary material damping to reduce the vibrations which is essentially for large material
removal rates and high-speed machining. The heavy structural design is generally provided with
the ribs at the strategic locations to improve the static stiffness.
Spindle Design:
In the machine tool, spindle provides the necessary motion and power for the machining. Thus, it
is a very important element whose accuracy is to be taken care of by proper design. The
machining forces are directly transmitted to the spindle as axial and radial forces. In NC machine
tools, because of the larger material, removal rates, the magnitude of the cutting forces is so
larger. Hence it is necessary in spindle design to see that the spindle deflection be minimized so
as to get proper surface finish and also to reduce the possibility of chatter.
A typically feature to be noted in the design is that the spindle is well supported with very little
over hang beyond the end bearings. The spindle is supported with sufficiently large ball and
roller bearings to take care of the large axial and radial cutting forces.

Figure: Spindle Design for CNC turning Centre


The heat generated in the spindle will be substantial because of the large power used ad high
spindle speeds used. It, therefore, becomes necessary to provide proper cooling of the spindle so
as to maintain thermal equilibrium so that the spindle growth is maintained in reasonable limits.
For this purpose, many methods are employed. The oil circulated through the spindle is provided
with a heat exchanger so that the heat is removed continuously from the spindle. Optionally, it
may also be provided with a chilling arrangement for more efficient heat removable from the
spindle.
The spindle motor and the gear box are isolated from the main structure so that part of the heat
generated in them is not transmitted to the mission tool structure. Bridgeport has introduced a
temperature compensation system in which four temperature sensors are used to continuously
measure and then get compensated by the MCU.
Drives:
Following are the two drives used in CNC machines.
 Spindle drives to provide the main spindle power for cutting
 Feed drives to drive the axis as per the programme
Feed Drives:
The feed drives that are used in CNC machine tools are the following
 dc servomotors
 stepper motors
DC Servomotors:
The dc servomotors are high performance motors and are useful as prime movers in a
numerically control machine tools where starts and stops must be made quickly and accurately.
The force that rotates the motor armature is the result of the interaction between two magnetic
fields. To produce a constant torque from the motor these two fields must remain constant in
magnitude and in relative orientation. This is achieved by constructing the armature as a series of
small sections connected in sequence to the segments of a commutator. Electrical connection is
made to the commutator by means of two brushes. As successive commutator segments pass the
brushes, the current in the coils connected those segments changes directions. This commutation
or switching effect results in a current flow in the armature occupies a fixed position in space,
independent of the armature rotation and allows the armature to be regarded as a wound core
with an axis of magnetization fixed in space. This gives rise to the production of a constant
torque output from the motor shaft. The axis of magnetization is determined by the position of
the brushes. If the motor is to similar characteristics in both directions of rotation, the brush axis
must be positioned to produce an axis of magnetization that is at 90 degrees to the stator field.

Figure: Working Principle of DC Motor


Stepper Motors:
A stepper motor rotates (steps) in fixed angular increments. Step size or step angle, is
determined by the construction of the motor and the type of drive scheme used to control it.
Typical step resolution is 1.8 degress (200 step per rev).however, micro-step motors are capable
of 0.0144 degree steps (25000 steps per rev). Micro-step motors are hybrid 200 steps per rev
motors that are electrically controlled to produce 25000 steps per rev.

Figure: Typical Step motor system. Precise step systems have feedback loop
Permanent Magnet Step Motors:
The permanent magnet step motor moves in steps when its windings are sequentially
energized. The following figure illustrates a permanent magnet rotor surrounded by a two phase
stator. Two rotor sections (N and S) are offset by one half-tooth pitch to each other. As energy is
switched from phase 2 to phase 1, a set of rotor magnets will align with phase 1 and rotor will
turn one step. If both phases are energized simultaneously, the rotor will establish its equilibrium
midway between steps. Thus, the motor is said to be half-stepping.

Figure: Stepper Motor with Permanent Magnet Rotor


Stepper motors have the following benefits, which call for their use in motion-control
applications.
 Low cost
 Ruggedness
 Simplicity in construction
 High reliability
 No maintenance
There is virtually no conceivable failure within the stepper drive module that could cause the
motor to run away. Stepper motors are simple to drive and control in an open-loop configuration.
They only require four leads. They provide excellent torque at low speeds, up to 5 times the
continuous torque of a brush motor of the same frame size or double the torque of the equivalent
brush motor. This often eliminates the need for gearbox. A stepper-driven system is inherently
stiff, with known limits to the dynamic position error.
Actuation Systems:
Lead screws:
The rotary motion from the drive motor needs to be converted to the linear motion to
move the various axes of the machine tool. In conventional machine tools, the square (Acme)
thread is normally used for this purpose. However, in view of the metal to metal and sliding
contact between the nut and the screw, the friction is very high. This results in greater power
being utilized for the movement of the axes.

Figure: Lead Screw with Acme Nut


In the case of recirculating ball screws, the nut is replaced by a series of balls which circulate in
the channel in the form of threads. This results in a highly efficient rolling motion of balls in the
space between the screw shaft and nut. The balls at the end of the thread portion in the nut will
be repositioned back into the beginning of the thread form by a deflector. The size of the being
an internal return of the balls is small as compared to the external return type using an external
return tube.
Figure: A Recirculating ball screw and nut arrangement
The recirculating ball screws have a number of advantages in comparison to the conventional
type of screws.
1. They have a longer life.
2. The wear of the screw is relatively small. Hence, it maintains accuracy through the entire
life of the screw.
3. The frictional resistance offered is small, hence can be used for carrying heavier loads at
faster speeds.
4. The power required for driving is small due to small friction.
Slideways:
Another important element for considering during the design of the CNC machine tool is
the slide motion. The conventional slide ways such as the V, flat, round or dovetail has a large
amount of friction because of the sliding contact between the sliding members. This will not
allow for faster slide movement demanded by most of the CNC machine tools. As a result, a
number of rolling friction elements capable of providing a very low friction have been
developed, which are generally classified as linear-motion or LM devices.

Feedback Devices:
As discussed in the closed loop control system, two two types of feedback required are:
i. Velocity feedback to measure and monitor the speed of the driver motor.
ii. Positional feedback to measure and monitor the position or displacement of the
machine slides.
Velocity Feedback:
Velocity feedback is normally provided by a device is called tachogenerator. A tachogenerator is
simply a voltage generator that gives voltage output which is proportional to its speed. The
tachogenerator is normally built in the servomotor case and is directly fitted on the servomotor
shaft. The output voltage from the tachogenerator is used as feedback to monitor the motor
speed. Rotary encoders are also used to provide feedback for velocity control.
Position Feedback
The ideal methods of measuring the displacement or position of the cutting tool will be to
continuously measure the position of the cutting tool edge relative to the datum point. This will
result in accurate displacements and it will take into account the tool wear, etc. The positional
feedback is provided by measuring the slide movements with measuring device. The position
measuring devices used are either rotary or linear measuring transducers.
Rotary or Angular Position Measuring Transducers:
Angular position measuring transducers operate by measuring the angular speed of a rotating
element, normally of a leadscrew. From the known value of lead of the leadscrew, movement of
worktable or machine slide is calculated by the control system. Most commonly used angular
position measuring transducers operate on the photo electric principle.

The transducer consists of a disc fitted on the axis of leadscrew. The disc is made up of uniform
alternate transparent and opaque areas. A light source is fitted on one side of the disc and
photocell on the other side. When the disc rotates with the rotation of the leadscrew, the
photocell will sense light and dark areas alternatively. As the dark area of disc is gradually
uncovered, the light intensity falling on the photocell goes on increasing until it reaches a
maximum when the transparent part of the disc comes in front of the light source. As the disc
continues to rotate the dark area starts to reduce the light intensity falling on the photocell which
will gradually reduces to zero when the dark area comes between the photocell and the light
source. The photocell gives output voltage based on the intensity of light falling on it and the out
from photocell resembles a sine-wave, which is converted into square shaped pulses to make it
useful for control purposes. The number of output pulses is then counted. As the out from the
photocell is related to the rate at which the transparent areas of the disc come in front of the light
source, the rotary speed of leadscrew is calculated from the known number of lines engraved on
the rotating disc. The displacement of the slide is then calculated from the lead of the leadscrew.
The directions of rotation of the leadscrew are sensed by putting a second photocell in the circuit.
The second photocell is positioned in such a way that the output from this photocell is identical
to that of first photocell but the output from the two photocells will be out of phase. This phase
difference is used to determine the direction of rotation of leadscrew. Position measurement by
angular position measuring transducer is indirect as the output of the transducer has to be
converted into table displacement.

Figure: Two Photocells sense direction of movement by phase difference


Linear Position Measuring Transducers:
Linear position measuring transducer also operates on the photoelectric principle. The linear
measuring system measures the displacement of the machine slide from a fixed datum. A linear
measuring system consist of a precision linear scale engraved with close spaced alternate
transparent and opaque parallel lines as one unit and a photocell and light source as the second
unit. One of the units is fixed on the stationary element of the machine tool and the other unit is
fixed to the moving worktable. A pulse is generated by the photocell as it is exposed to light
source through the transparent areas of the linear scale. From the known number of engraved
lines per unit length on the linear scale and by counting the number of pulses, the displacement
of the worktable can be established.
As in the case of rotary transducers, a second photocell is used to detect the directions of
movement. The linear system may have either a glass scale in which case light passes through
the transparent area or a stainless steel scale in which case the light is reflected from the
transparent areas. Principle of linear measuring system is shown is Fig. 3.5.

Figure: Linear Position measuring transducer

NC Coordinate Systems:
In order for the part programmer to plan the sequence of positions and movements of the cutting
tool relative to the workpiece, it is necessary to establish standard axis system by which the
relative positions can be specified. However, to make things easier for the programmer, we adopt
the viewpoint that the workpiece is stationary while the tool is moved relative to it. Accordingly,
the coordinate system of axes is established with respect to the machine table.
Two axes, x and y, are defined in the plane of the table, as shown in the figure. The z axis is
perpendicular to this plane and movement in the z direction is controlled by the vertical motion
of the spindle. The positive and negative directions of motion of tool relative to table along these
axes. NC drill presses are classified as either two-axis or three-axis machines, depending on
whether or not they have the capability to control the z axis.
Figure: NC machine tool axis system for milling and drilling operations
A numerical control milling machines and similar machine tools (boring mill, for example) use
an axis system similar to that of the drill press. However, in addition to the three linear axes,
these machines may possess the capacity to control one or more rotational axes. Three rotational
axes are defined in NC: the a, b, c axes. These axes specify angles about the x, y, and z axes,
respectively. To distinguish positive from negative angular motions, the “right-hand rule” can be
used. Using the right hand with the thumb pointing in the positive linear axis direction (x, y, or
z), the fingers of the hand are curled to point in the positive rotational direction.
For turning operations, two axes are normally all that are required to command the
movement of the tool relative to the rotating workpiece. The z axis is the axis of rotation of the
workpart, and x axis defines the radial location of the cutting tool.
The purpose of the coordinate system is to provide a means of locating the tool in relation to
the workpiece. Depending on the NC machine, the part programmer may have several different
options available for specifying this location.

Figure: NC machine tool axis system for turning operation


Fixed zero and floating zero:
The programmer must determine the position of the tool relative to the origin (zero point) of the
coordinate system. NC machines have either of two methods for specifying the zero point. The
first possibility is for the machine to have a fixed zero. In this case, the origin is always located at
the same position on the machine table. Usually, that position is the southwest corner (lower left-
hand corner) of the table and all tool locations will be defined by positive x and y coordinates.
The second and more common feature on modern NC machines allows the machine operator to
set the zero point at any position on the machine table. This feature is called floating zero. The
part programmer is the one who decides where the zero point should be located. The decision is
based on part programming convenience. For example, the workparts may be symmetrical and
the zero point should be established at the centre of symmetry. The location of the zero point is
communicated to the machine operator. At the beginning of the job, the operator moves the tool
under manual control to some “target point” on the table. The target point is some convenient
place on the workpiece or table for the operator to position the tool. For example, it might be a
predrilled hole in the workpiece. The target point has been referenced to the zero point by the
part programmer. In fact, the programmer may have selected the target point as the zero point for
tool positioning. When the tool has been positioned at the target point, the machine operator
presses a “zero” button on the machine tool console, which tells the machine where the origin is
located for subsequent tool movements.
Absolute positioning and incremental positioning:
Another option sometimes available to the part programmer is to use either an absolute system of
tool positioning or an incremental system. Absolute positioning means that the tool locations are
always defined in relation to the zero point. If a hole is to be drilled at a spot that is 8 in. above
the x axis and 6 in. to the right of y axis, the coordinate location of the hole would be specified as
x = +6.000 and y = +8.000. By contrast, incremental positioning means that the next tool
location must be defined with reference to the previous tool location. If in drilling example,
suppose that the previous hole had been drilled at an absolute position of x = +4.000 and y =
+5.000. Accordingly, the incremental position instructions would be specified as x = +2.000 and
y = +3.000 in order to move the drill to the desired spot. Figure 7.6 illustrates the difference
between absolute and incremental positioning.

Figure: Absolute versus Incremental Positioning

CNC Part Programming:


APT Language:
There are four basic types of statements in the APT language:
1. Geometric Statements: also called definition statements; are used to define the
geometry elements that comprise the part.
2. Motion Statements: are used to specify the tool path.
3. Postprocessor Statements: control the machine tool operation, for example, to specify
speeds and feeds, set tolerance values for circular interpolation, and actuate other
capabilities of the machine tool.
4. Auxiliary Statements: a group of miscellaneous statements used to name the part
program, insert comments in the program and accomplish similar functions.
Geometry Statements:
The points, lines, and surfaces must be defined in the program prior to specifying the motion
statements. The general form of an APT geometry statement is the following:
SYMBOL = GEOMETRY TYPE/descriptive data
As an example,

A symbol can be any combination of six or fewer alphabetical and numerical characters, at least
one of which must be alphabetical. Also the symbol cannot be an APT vocabulary word. Some
examples are presented below:

1. Points: Specification of a point can be accomplished by the following:


a. Designating its x-, y-, and z-coordinates;
P1 = POINT/15.0, 10.0, 25.0
b. As the intersection of two intersecting lines;
P2 = POINT/INTOF, L1, L2
L1 and L2 are two previously defined lines.
2. Lines: A line in APT is considered to be of infinite length in both directions. Specification of
a line can be accomplished by the following:
a. Two points through which it passes;
L1 = LINE/P3, P4
P3 and P4 are two previously defined points.
b. Passes through point (P5) and parallel to another line (L3) that has been previously
defined;
L2 = LINE/P5, PARLEL, L3
3. Planes: In APT, a plane extends indefinitely. A plane can be defined by the following:
a. Three points through which it passes;
PL1 = PLANE/P1, P2, P3
P1, P2 and P3 must be non-collinear.
b. Passes through point (P2) and parallel to another plane (PL1) that has been previously
defined;
PL2 = PLANE/P2, PARLEL, PL1
4. Circles: In APT, a circle is considered to be a cylindrical surface that is perpendicular to the
x-y plane and extends to infinity in the z-direction. A circle can be defined by the following:
a. Its center and radius;
C1 = CIRCLE/CENTER, P1, RADIUS, 25.0
b. Three points through which it passes;
C2 = CIRCLE/P4, P5, P6
The three points must not be collinear
Motion Statements:
The format for motion commands follows the pattern:
motion/description
The initial motion starts from a home position, and takes the form:
FROM/P0 or FROM/ 0.0, 1.0, 2.0
The FROM motion statement occurs only once for each set of a motion type, at the start of the
set of motions.
Contouring motion – is the most common motion used in APT programming, and these
statements specify the tool path continuously throughout the motion. They make use of three
surfaces: (a) drive; (b) check; and (c) part surfaces.
Figure: Three Surfaces in APT contouring motions that guide the cutting tool
Drive surfaces represent the surface along which the vertical edges of the tool will follow. Part
surfaces specify the surfaces the tip of the tool will follow. And check surfaces describe where
the tool will come to rest after it has completed the motion of the current step. There are four
locations for the tool to stop with respect to a check surface. These four possibilities each have
their own modifier words.
The TO modifier stops the tool when the first surface of the tool would come into contact with
the check surface. The ON modifier stops the tool where the centre point of the tool would
come into contact with the check surface. The PAST modifier stops the tool where the last
surface of the tool would contact the check surface. And the TANTO modifier stops the tool at
the point of circular tangency with the edge of the tool.
The initial contouring motion statement is the GO/TO, which defines the initial drive, part
and check surfaces. It takes the form:
GO/TO, drive surface, TO, part surface, TO, check surface
An example would be:
GO/TO, L1, TO, PL1, TO, L2 specifying that the tool should use line L1 as the
drive surface, plane P1 as the part surface, and line
L2 as the check surface.
Note: the GOTO and the GO/TO statements are not the same. The former specifies point to
point motion (see below), and the latter initiates contouring motion.
Continuing contouring motion statements are given from the vantage point of a person sitting on
the top of the tool.
The motion words are: (a) GOLFT; (b) GORGT; (c) GOFWD; (d) GOBACK; (e) GOUP; and
(f) GODOWN.
The sense of these words depends on the direction the tool has been coming from, and is
depicted in Figure:

Figure: Motion Continuation Statements


Point to point motion – may be specified as absolute, or as incremental (relative to the last point
visited). An example of absolute, point to point motion is:
GOTO/P0
An example of incremental, point to point motion is:
GODLTA/1.0, 2.0, 3.0
Point to point motion is useful in peck drilling or similar operations, since the motion path in-between
the point is unimportant.
Post-Processor Statements:
These statements provide processing parameters to the post-processor program. Typical
programs will require parameters for feeds, speed, and other tool/spindle/machine controls.
Examples:
SPINDL/600 specifies the spindle to be 600 rpm.
FEDRAT/6.0 specifies a feed rate of 6 inches per minute.
TURRET/T2 specifies loading tool # 2 in the turret.
A final post-processor statement must specify to the post-processor program what type of
machine is intended for the final NC code, and the specific controller to generate the code for.
An example is:
MACHIN/MILL,2 specifies a mill machine type, and controller type 2
Auxiliary Statements:
These statements complete the APT programming language, and include the FINI statement to
mark the end of the program as well as statements to define the width of the tool. An example
of the latter is:
CUTTER/0.25 specifies a quarter-inch cutter diameter.
The computer would then know to calculate a 0.125 inch offset to accommodate the cutter
diameter in computing the centre of the tool.
Example APT Problem:
An APT program for the profiling of the part in Figure 2 is to be generated. The processing
parameters are: (a) feed rate is 5.39 inches per minute; (b) spindle speed is 573 revolutions per
minute; (c) a coolant is to be used to flush the chips; (d) the cutter diameter is to be 0.5 inches,
and (e) the tool home position is (0, -1, 0). (Adapted from Groover, M. P. (1980). Automation,
Production Systems, and Computer-Aided Manufacturing. Englewood Cliffs, NJ: Prentice-Hall.
pp. 253-255.)

Figure: APT Program Workpiece

Figure: APT Geometry and Tool Path for Workpiece


Part Programming:
Part programme is an important component of the CNC system. The shape of the manufactured
components will depend on how correctly the programme has been prepared. Part programme is
a set of instructions which instructs the machine tool about the processing steps to be performed
for the manufacture of a component. Part programming is produced by which the sequence of
processing steps and other related data, to be performed on the CNC machine is planned and
documented. The part programme is then transferred to one of the input media, which is used to
instruct the CNC machine.
NC Words:
The combination of binary digits (bits) in a row on the tape denotes a character. A NC word is a
collection of characters used to form an instruction. Typical NC words are X – position, Y –
position, feed rate, etc. A collection of NC – words is called a block and a block of words is a
complete NC instruction. Following are the NC words used in the formation of blocks
1. Sequence Number (N – Word): The first word in every block is the sequence number. The
sequence number is used to identify the block. The sequence number is preceded by word N
and is written as N 0001, N 0002, N 9999, etc. The programme is executed from lowest
block number to highest unless instructed otherwise. It is customary to start with block No.
0001 or 0010 and proceed in steps of 5 or 10, so that accidently omitted block may be
inserted easily.
2. Preparatory Function (G – Words): The preparatory word prepares the control unit to
execute the instructions that are to be followed. The preparatory function is represented by
two digits preceded by G i.e. G00, G99. The preparatory function enables the controller to
interpret the data which follows and it precedes the coordinate words. For example G01 is
used to prepare the controller for linear interpolation. Some of the preparatory functions are
given below:
Preparatory Functions (G –Codes)
Code Function
G00 Rapid Traverse
G01 Linear Interpolation
G02 Circular Interpolation (Clock Wise)
G03 Circular Interpolation (Counter Clock Wise)
G04 Dwell
Input of Cutter offset data, followed by a P –
G10
Code and an R – Code.
G17 XY Plane Designation
G18 ZX Plane Designation
G19 YZ Plane Designation
G20 Input Values Specified in Inches
G21 Input Values Specified in millimeters
G28 Return to reference point.
G32 Thread Cutting in Turning
G40 Cutter Compensation – Cancel
G41 Cutter Compensation – Left
G42 Cutter Compensation – Right
Specify location of coordinate axes system
origin relative to starting location of cutting
G50
tool. Used in some lathes. Milling and
drilling machines uses G92.
G90 Absolute Dimensioning
G91 Incremental Dimensioning
G92 Zero Preset
G94 Feed rate mm/min in milling and drilling
G95 Feed rate mm/rev in milling and drillimg
G98 Feed rate mm/min in turning
G99 Feed rate mm/rev in turning
3. Coordinate (X, Y, Z –Words): these words give final coordinate positions for X, Y, Z
motions. In two – axis CNC systems only two coordinate words would be used. To specify
angular position around the three – coordinate axis additional, i.e., a – word, and b – word,
are used. In addition, the words I, J, K are used to specify the position of arc centre in case of
a circular interpolation. Different CNC systems use different formats for expressing
coordinates of a point. In some systems, decimal point is not coded but the control system
automatically provides a decimal point at a pre – set position. While giving the data positive
sign is optional but negative sign has to be given in case of negative dimensional positions.
4. Feed Function (F –Word): The feed function is used to specify the feed rate in the
machining operations. The rate is expressed in millimeters per minute (mm/min) or mm/rev.
If the feed rate is 200 mm/min, it will be represented as F 200. The appropriate G code
should be specified to instruct the machine whether the feed value is mm/min or mm/rev.
(G94 or G95).

5. Spindle Speed Function (S –Word): The spindle speed is specified either in revolutions per
minute (r.p.m) or as meters per minute. If the speed is given in meters per minute, the control
unit calculates the rev/minute using the appropriate formulae. If the machine is required to
run at 800 rpm the speed will be specified as S 800.
6. Tool Selection ( T –Word): the T –word is needed only for machines with programmable
tool turret or automatic tool changer (ATC). Each tool pocket on the tool turret or ATC has a
distinct tool number. The T –word in the part programme specifies which tool is to be used in
the operation. The tool number for a particular operation is specified as T00 to T99. Also
with each tool code, the corresponding tool length offset is also specified with the help of
two additional digits i.e. T01.01 where second 01 denotes the tool length offset for tool No.
01.
7. Miscellaneous Function (M – Word): The Miscellaneous function word is used to specify
certain miscellaneous or auxiliary functions which do not relate to the dimensional
movements of the machine. The miscellaneous functions may be spindle stop, coolant
ON/OFF, etc. An example of M – word is M02 which indicates end of programme. The
miscellaneous functions are given below:
Miscellaneous Functions (M –Codes)
Code Function
M00 Program Stop
M01 Optional Programmable Stop
M02 End of Program
M03 Spindle on, CW
M04 Spindle on, CCW
M05 Spindle Stop
M06 Tool Change
M07 Turn Cutting Fluid on Flood
M08 Turn Cutting Fluid on Mist
M09 Turn Cutting Fluid Off
Automatic Calmping of Fixture, machine
M10
slides, etc.
M11 Automatic Unclamping
M13 Spindle On, CW + Coolant On
M14 Spindle On, CCW + Coolant On
M17 Spindle and Cutting Fluid off
M19 Turn Spindle off at oriented Position
M30 Program stop at end tape + tape rewind

Machine Tool Zero Point Setting:


The machine zero point can be set by two methods by the operator, manually by a
programmed absolute zero shift, or by work coordinates, to suit the holding fixture or the
part to be machined.
Manual Setting:
The operator can use the MCU controls to locate the spindle over the desired part
zero and then set the X and Y coordinate registers on the console to zero.
Absolute Zero Shift:
The absolute zero shift can change the position of the coordinate system by a
command in the CNC program. The programmer first sends the machine spindle to
home zero position by a command in the program. Then another command tells
the MCU how far from the home zero location, the coordinate system origin is to
be positioned.

Figure: Machine Tool Zero Point Setting


R = Reference Point (Maximum travel of Machine)
W = Part Zero point Work piece coordinate system
M = Machine zero point (X0, Y0, Z0) of machine coordinate system
The sample commands may be as follows:
N1 G28 X0 Y0 Z0 (sends spindle to home zero position or Return to reference
point).
N2 G92 X3.000 Y4.000 Z5.000 (the position the machine will reference as part
zero or Programmed zero shift).
Cutter Compensation:
In CNC machining, if the cutter axis is moving along the programmed path, the dimension of the
workpiece obtained will be incorrect since the diameter of the cutter has not be taken into
account.
Modern CNC systems are capable of doing this type of calculation which is known as cutter
compensation. What the system requires are the programmed path, the cutter diameter and the
position of the cutter with reference to the contour. Normally, the cutter diameter is not included
in the programme it has to be input to the CNC system in tool setting process.

Figure: Cutter Compensation


Example:
A 2.0-in 2.0-in. square is to be milled using a 1/2-in. end milling cutter (end mill). Write an NC
part program to make the square.
Program:

Part program Explanation

N0010 G41 S1000 F5 M03 Begin compensation (left), set feed and speed, spindle on (CW)
N0020 G00 X6.000 Y6.000 Move to lower left corner
N0030 G01 Z-1.000 Plunge down the tool
N0040 G01 Y8.000 Cut to upper left corner
N0050 G01 X8.000 M96 Cut to upper right corner with external curve
N0060 G01 Y6.000 M96 Cut to lower right corner with external curve
N0070 G01 X6.000 M96 Cut to lower left corner with external curve
N0080 G01 Z1.000 Lift the tool
N0090 G40 M30 End the composition, stop the machine

Computer Numerical Control (CNC):


CNC is an NC system that utilizes a dedicated, stored program computer to perform some or all
of the basic numerical control functions. The external appearance of the CNC machine is very
similar to that of conventional NC machine. Part programs are initially entered in a similar
manner. Punched tape readers are still the common device to input the part program into the
system. However, with conventional numerical control the punched tape is cycled through the
reader for every work piece in the batch. With CNC, the program is entered once and then stored
in the computer memory. Thus the tape reader is used only for the original loading of the part
program and data. New system options can be incorporated into the CNC controller simply by
reprogramming the unit. Because of this reprogramming capacity, both in terms of part programs
and system control options, CNC is often referred by the term “soft wired” NC.

Figure: General configuration of computer numerical control (CNC) system


Functions of CNC:
The principal functions of CNC are
1. Machine tool control
2. In – Process compensations
3. Improved Programming and operating features
4. Diagnostics
Machine Tool Control:
The primary function of the CNC system is control of the machine tool. This involves conversion
of the part program instructions into machine tool motions through the computer interface and
servo system. Some of the control functions such as circular interpolation, can be accomplished
more efficiently with hard wired circuits than with the computer. This fact has lead the
development of two alternative controller designs in CNC:
a. Hybrid CNC
b. Straight CNC
Hybrid CNC: In the hybrid CNC system, the controller consists of the soft – wired computer
plus hard wired logic circuits. The hard wired components perform those functions which they
do best, such as feed rate generation and circular interpolation. The computer performs the
remaining control function plus other duties not normally associated with a conventional hard –
wired controller. Use of these hard wired circuits saves the computer from performing these
calculation chores. Hence a less expensive computer is required in the hybrid CNC system.

Figure: Hybrid CNC


Straight CNC: It uses a computer to perform all the NC functions. The only hard wired
elements are those required to interface the computer with the machine tool and the operator’s
console. Interpolation, tool position feedback and all other functions are performed by computer
software. Accordingly, the computer required in a straight CNC system must be more powerful
than that needed for a hybrid system. It is possible to make changes in the interpolation
programs, whereas the logic contained in the hard wired circuits of hybrid CNC cannot be
altered.

Figure: Straight CNC


In – Process Compensation: This involves the dynamic correction of the machine tool motions
for changes or errors which occur during processing. Some of the options included within the
category of CNC in – process compensation are:
 Adjustments for errors sensed by in – process inspection probes and gauges.
 Re-Computation of axis positions when an inspection probe is used to locate a datum
reference on a work part.
 Offset adjustments for tool radius and length.
 Adaptive control adjustments to speed and/or feed.
 Computation of predicted tool life and selection of alternating tooling when indicated.
Improved Programming and Operating Features: The flexibility of soft – wired control has
permitted the introduction of many convenient programming and operating features. Included
among these features are the following:
 Editing of part program at the machine. This permits correction or optimization of the
program.
 Graphic display of the tool path to verify the tape.
 Various types of interpolation: Circular, parabolic and cubic interpolation.
 Support of both U.S. customary units and metric units.
 Use of specially written sub routes.
 Manual data input
 Local storage of more than one part program.
Diagnostics: NC machine tools are complex and expensive systems. The complexity increases
the risk of component failures which led to system downtime. It also requires that the
maintenance personal be trained to a higher level of proficiency in order to make repairs. CNC
machines are often equipped with a diagnostic capability to assist in maintaining and repairing
the system. Ideally the diagnostic subsystem would accomplish several functions. The subsystem
would be able to identify the reason for a downtime occurrence so that the maintenance
personnel could make repairs more quickly. The subsystem would be alert to signs that indicate
the imminent failure of a certain component. Hence maintenance personnel could replace the
faulty component during a scheduled downtime, thus avoiding an unplanned interruption of
production. A third possible function is for the CNC system to contain a certain amount of
redundancy of components which are considered unreliable. When one of these components
fails, the diagnostics subsystem would automatically disconnect the faulty component and
activate the redundant component. Repairs could be accomplished without any breaks in normal
operation.
Advantages of CNC:
CNC possesses a number of inherent advantages over conventional NC. The following are list of
benefits:
 The part program tape and tape reader are used only once to enter the program into
computer memory. This results in improved reliability.
 Tape editing at the machine site: The NC tape can be corrected and even optimized
during tape try out at the site of machine tool.
 Metric conversion: CNC can accommodate conversion of tapes prepared in units of
inches into the International System of units (SI)
 Greater flexibility: This flexibility provides the opportunity to introduce the new control
options with relative ease at low cost.
 User written programs: One of the possibilities not originally anticipated for CNC was
the generation of specialized programs by the user.
 Total manufacturing system: CNC is more compatible with the use of a computerized
factory wide manufacturing system.
Direct Numerical Control (DNC):
Direct numerical control can be defines as a manufacturing system in which a number of
machines are controlled by a computer through direct connection and in real time. The tape
reader is omitted from the DNC.
Figure: General configuration of direct numerical control (DNC) system
Instead of using tape reader, the part program is transmitted to the machine tool directly from the
computer memory. In principle one large computer can be used to control more than 100
separate machines.

Figure: DNC with satellite minicomputers


Components of DNC:
A Direct Numerical Control system consists of four basic components:
1. Central Computer
2. Bulk Memory, which stores the NC part programs
3. Telecommunication lines
4. Machine tools
The computer calls the part program instructions from bulk storage and sends them to the
individual machines as the need arises. It also receives data back from the machines. This two –
way information flow occurs in real time, which means that the each machines request for
instructions must be satisfied almost instantaneously. Similarly the computer must always be
ready to receive information from the machines and to respond accordingly.
Depending on the number of machines and the computational requirements that are imposed on
the computer, it is sometimes necessary to make use of satellite computers. These satellites are
minicomputers and they serve to take some of the burden off the central computer. Each satellite
controls several machines. Group of part program instructions are received from the central
computer and stored in buffers. They are then dispensed to the individual machines as required.
Feedback data from the machines are also stored in the satellite’s buffer before being collected at
the central computer.
Types of DNC:
There are two alternative system configurations by which the communication link is established
between the control computer and the machine tool.
a. Behind the Tape Reader (BTR) system
b. Special Machine Control Unit
Behind the Tape Reader (BTR) system:
In this arrangement the computer is linked directly to the regular NC controller unit. The
replacement of the tape reader by the telecommunication lines to the DNC computer is what
gives the BTR configuration its name. The connection with the computer is made between the
tape reader and the controller unit – behind the tape reader. The controller unit uses two
temporary storage buffers to receive blocks of instructions from the DNC computer and convert
them into machine actions. While one buffer is receiving a block of data, the other is providing
control instructions to the machine tool.

Figure: DNC with behind the tape reader (BTR) configuration


Special Machine Control Unit:
The other strategy in DNC is to eliminate the regular NC controller altogether and replace it with
a special machine control unit. This special MCU is a device that is specially designed to
facilitate communication between the machine tool and the computer. One area where this
communication link is important is in circular interpolation of the cutter path. The special MCU
configuration achieves a superior balance between accuracy of the interpolation and fast metal
removal rate than is generally possible with the BTR system.

Figure: DNC with special machine control unit (MCU)


Functions of DNC:
There are several functions which a DNC system is designed to perform. The principal functions
of DNC are:
1. NC without punched tape
2. NC part program storage
3. Data collection, processing and reporting
4. Communications
NC without Punched Tape:
One of the original objectives in DNC was to eliminate the use of punched tape. There is also the
expense associated with the equipment that produces the punched tape. All of these costs and
inconveniences can be eliminated with the DNC approach.
NC part program storage:
The part programs in a DNC system would typically be stored as the CLFILE. The CLFILE must
be converted into instructions for a particular machine tool. This conversion is performed by the
post processor. The storage subsystem must be structured to perform the certain data processing
and management functions, such as file security, display of programs, manipulation of data and
so on.
Data Collection, Processing and Reporting:
The other important function of DNC involves the transfer of data from the machine tool back to
the central computer. DNC involves two – way transfer of data. The basic purpose behind the
data collection, processing, and reporting function of DNC is to monitor production in the
factory. Data are collected on production piece counts, tool usage, machine utilization and other
factors that measure performance in the shop. These data must be processed by the DNC
computer, and reports are prepared to provide management with information necessary for
running the plant.
Communications:
A communication network is required to accomplish the previous three functions of DNC.
Communication among the various subsystems is a function that is central to the operation of
any DNC system. The essential communication links in direct numerical control are between the
following components of the system:
 Central computer and machine tools
 Central computer and NC part programmer terminals
 Central computer and bulk memory, which stores NC programs
Optional communication links may also be established between the DNC system
 Computer aided design (CAD) system
 Shop floor control
 Corporate data processing computer
 Remote maintenance diagnostics system
 Other computer automated systems in the plant
Advantages of DNC:
The following are the advantages of Direct Numerical Control System
1. Elimination of punched tape and tape readers
2. Greater computational capability and flexibility
3. Conventional storage of NC part programs in computer files
4. Programs stores as CLFILE
5. Reporting of shop performance
6. Establishes the frame work for the evolution of the future computer automated factory

You might also like