CNC Prac4 NL en R C
CNC Prac4 NL en R C
INTRODUCTION TO PRAC4
BAS KEMPERMAN
CURRICULUM
• First lesson
Is a theory lesson. 1.5 clock hours R26
• Second lesson
Is a kind of practical lesson. R26
In the practical room we look at the CNC milling machine. How does this work ?
• Third lesson
Is an excursion.
We visit a production company: Doeko at Weurt
Hand in report on Friday 2 June via HAND-IN, see education online for the assignment description
INTRODUCTION TO CNC TECHNOLOGY
• Heidenhain
• Okuma
• Fanuc
Source:http://www.helmancnc.com/cnc-program-block/
13-1-2020
- Modal/non-modal codes
- Default codes:
MODAL/NON-MODAL CODES
• A code is modal if it remains active in a program after a command until it is cancelled by another
code.
• There are codes that are always active once the machine is started up and are only changed if
another code is programmed.
• E.g. G21 metric programming (active with power on) and G20 inch programming. (only active if
specified in program)
• In case of a RESET or POWER OFF, the first one becomes active again.
This also applies to zero points. After a reset, the machine often returns to G54,
which is the first zero point.
GROUPS OF CODES
Groups:
Codes are also divided into groups.
This means that codes from the same group cannot be programmed on the same line.
Typed of groups:
• G codes
• M codes
• T codes
• S codes
• F codes
GROUPS OF CODES
G code:
• Codes that can be used to specify linear/circular motion.
• But also functions such as radius compensation, choice of coordinate system, drilling cycles, zero
points, etc.
M code:
• Code that turns a machine function on/off.
• Acts like a switch: stays on until it is turned off.
• E.g. M3 = spindle clockwise, M5 = spindle stop, M9 = cooling off, M8 = cooling on.
• Tool change often cancels some of these functions.
T code:
• Code related to a tool.
• E.g. T1 M6 = tool number 1, perform tool change.
GROUPS OF CODES
S code:
• Code representing the rotational speed.
• E.g. S1000 M3 = 1000 rpm, direction of rotation clockwise.
F code:
• Code to specify the feed rate.
• E.g. G1 X100 F250 = Linear motion X+ axis with a feed rate of 250mm/min.
• This code is not cancelled by a G00 (rapid mode) but remains active until
another feed rate is programmed.
IMPORTANT G CODES
• If a code is modal, or remains coordinately the same on the next line, it may be omitted.
For instance:
• G90 X10 Y10 motion to X10 Y10 (hole 1)
• X30 Y20 motion to X30Y20 (hole 2)
IMPORTANT G CODES
G91
Incremental programming. (modal)
Coordinates are given as motions in relation to the current position.
For instance:
G91 IX10 IY10 motion to X10 Y10 (hole 4.)
IX20 IY10 motion to X30 Y20 (hole 5)
WORKPIECE ZERO POINT
Workpiece Zero
Point
The machine zero point is determined by three reference switches that must be activated when the
machine is started. In the X-axis, Y-axis and Z-axis
As soon as these are passed, the machine knows where each point is located in the coordinate
system, allowing the machine to be used.
Machine
Zero Point
https://webshop.han.nl/
Stand in front of the machine.
Right arm straight out to the side. X + axis
Left arm straight ahead. Y + axis
Your head Z + axis
G17 Programming in the XY plane and the Z-axis is the tool axis.
G18 Programming in the XZ plane and the Y-axis is the tool axis.
G19 Programming in the YZ plane and the X-axis is the tool axis.
In general, programming is done in G17 (2,5 D) and the further examples will
therefore also be in G17.
TOOL GEOMETRY OFFSET
• In this offset register, the dimensions (geometry) of the tools are entered.
• The length offset is the measured value in the Z-axis, of the difference in millimetres from the spindle
nose (= fixed zero point) to the tip of the tool.
This is also often referred to as the projection length of the tool.
• The diameter offset represents the tool radius in the X/Y axis.
Here the wear or measurement differences of the tools are compensated in both length and radius.
Activating offsets
• Face milling
• O0001
• T10 M6; (FACE MILL CUTTER 40MM HM)
• N01 G54 G43 X-25 Y85 Z50 H10 D10 S1250 T10 M3 F5000 ;
• Z0 ;
• G01 X125 F500 ;
• G00 Z10 ;
• X-25 Y52 ;
• Z0 ;
• G01 X125 ;
• G00 Z10 ;
• X-25 Y19 ;
• Z0 ;
• G01 X125 ;
• M98 P1001 ;
• M30 ;
• O1001(SUB-PROGRAM CHANGE POSITION AND BENCH FORWARD)
• G90 G40 G80 G00 Z300 H0 D0 M09 ;
• G53 Y0 Z-10 ;
• M99 ;
PROGRAM EXPLANATION
• Face milling = program name
• T10 M6; (FACE MILL CUTTER 40MM HM) = Tool 10; - M6 is tool change
• N01 G54 G43 X-25 Y85 Z50 H10 D10 S1250 T10 M3 F5000 ;
N01 = line number G54 = activate zero point 1; G43 = enable tool length
compensation H; X-25 Y85 Z50 = Starting coordinates; H10 = call length
compensation from the wear offset for Tool No. 10; D10 = radius compensation of
Tool 10 on; S1250 = required rotational speed of Tool 10; M3 = spindle rotates
clockwise; F5000 = feed rate 5000mm/min