This section gives a brief description of how a CNC machine is viewed from the input and output ends of the Interpreter.
1. Mechanical Components
A CNC machine has many mechanical components that may be controlled or may affect the way in which control is exercised. This section describes the subset of those components that interact with the Interpreter. Mechanical components that do not interact directly with the Interpreter, such as the jog buttons, are not described here, even if they affect control.
1.1. Axes
Any CNC machine has one or more Axes. Different types of CNC machines have different combinations. For instance, a 4-axis milling machine may have XYZA or XYZB axes. A lathe typically has XZ axes. A foam-cutting machine may have XYUV axes. In LinuxCNC, the case of a XYYZ gantry machine with two motors for one axis is better handled by kinematics rather than by a second linear axis.
|
Nota
|
If the motion of mechanical components is not independent, as with hexapod machines, the RS274/NGC language and the canonical machining functions will still be usable, as long as the lower levels of control know how to control the actual mechanisms to produce the same relative motion of tool and workpiece as would be produced by independent axes. This is called kinematics. |
|
Nota
|
With LinuxCNC, the case of the XYYZ gantry machine with two motors for one axis is better handled by the kinematics than by an additional linear axis. |
The X, Y, and Z axes produce linear motion in three mutually orthogonal directions.
The U, V, and W axes produce linear motion in three mutually orthogonal directions. Typically, X and U are parallel, Y and V are parallel, and Z and W are parallel.
The A, B and C axes produce angular motion (rotation). Typically, A rotates around a line parallel to X, B rotates around a line parallel to Y, and C rotates around a line parallel to Z.
1.2. Spindle
A CNC machine typically has a spindle which holds one cutting tool, probe, or the material in the case of a lathe. The spindle may or may not be controlled by the CNC software. LinuxCNC offers support for up to 8 spindles, which can be individually controlled and can run simultaneously at different speeds and in different directions.
1.3. Coolant
Flood coolant and mist coolant may each be turned on independently. The RS274/NGC language turns them off together see section M7 M8 M9.
1.4. Deshabilita los ajustes de avance y velocidad
A CNC machine can have separate feed and speed override controls, which let the operator specify that the actual feed rate or spindle speed used in machining at some percentage of the programmed rate.
1.5. Block Delete Switch
A CNC machine can have a block delete switch. See the Block Delete section.
1.6. Interruptor de parada de programa opcional
A CNC machine can have an optional program stop switch. See the Optional Program Stop section.
2. Control and Data Components
2.1. Linear Axes
The X, Y, and Z axes form a standard right-handed coordinate system of orthogonal linear axes. Positions of the three linear motion mechanisms are expressed using coordinates on these axes.
Los ejes U, V y W también forman un sistema de coordenadas diestro estándar. X y U son paralelos, Y y V son paralelos, y Z y W son paralelos (cuando A, B y C se rotan a cero).
2.2. Rotational Axes
Los ejes de rotación se miden en grados como ejes lineales de revolución en los que la dirección de la rotación positiva es en sentido antihorario cuando se ven desde el extremo positivo del eje X, Y o Z correspondiente. Por eje lineal de revolucion, nos referimos a uno en el que la posición angular puede aumentar sin límite (va hacia más-infinito) a medida que el eje gira en sentido antihorario y decrece sin límite (va hacia menos-infinito) a medida que el eje gira en el sentido de las agujas del reloj. Se utilizan ejes lineales de revolucion independientemente de si hay o no un límite mecánico en la rotación.
Clockwise or counterclockwise is from the point of view of the workpiece. If the workpiece is fastened to a turntable which turns on a rotational axis, a counterclockwise turn from the point of view of the workpiece is accomplished by turning the turntable in a direction that (for most common machine configurations) looks clockwise from the point of view of someone standing next to the machine.
[If the parallelism requirement is violated, the system builder will have to say how to distinguish clockwise from counterclockwise.]
2.3. Controlled Point
The controlled point is the point whose position and rate of motion are controlled. When the tool length offset is zero (the default value), this is a point on the spindle axis (often called the gauge point) that is some fixed distance beyond the end of the spindle, usually near the end of a tool holder that fits into the spindle. The location of the controlled point can be moved out along the spindle axis by specifying some positive amount for the tool length offset. This amount is normally the length of the cutting tool in use, so that the controlled point is at the end of the cutting tool. On a lathe, tool length offsets can be specified for X and Z axes, and the controlled point is either at the tool tip or slightly outside it (where the perpendicular, axis-aligned lines touched by the front and side of the tool intersect).
2.4. Coordinated Linear Motion
Para manejar una herramienta a lo largo de una ruta especifica, un centro de mecanizado debe coordinar el movimiento de varios ejes. Usamos el término movimiento lineal coordinado para describir la situación en la que, nominalmente, cada eje se mueve a velocidad constante y todos los ejes se mueven desde sus posiciones iniciales a sus posiciones finales al mismo tiempo. Si solo los ejes X, Y y Z (o uno o dos de ellos) se mueven, se produce movimiento en una línea recta, de ahí la palabra lineal en el término. En movimientos reales, a menudo no es posible mantener la velocidad constante porque se requiere aceleración o desaceleración al comienzo y/o al final del movimiento. Sin embargo, es factible controlar los ejes para que, en todo momento, cada eje haya completado la misma fracción del movimiento requerido que los otros ejes. Esto mueve la herramienta a lo largo de la misma ruta, y también llamamos a este tipo de movimiento movimiento lineal coordinado.
Coordinated linear motion can be performed either at the prevailing feed rate, or at traverse rate, or it may be synchronized to the spindle rotation. If physical limits on axis speed make the desired rate unobtainable, all axes are slowed to maintain the desired path.
2.5. Feed Rate
The rate at which the controlled point moves is nominally a steady rate which may be set by the user. In the Interpreter, the feed rate is interpreted as follows (unless inverse time feed or feed per revolution modes are being used, in which case see section G93-G94-G95-Mode).
-
If any of XYZ are moving, F is in units per minute in the XYZ cartesian system, and all other axes (ABCUVW) move so as to start and stop in coordinated fashion.
-
Otherwise, if any of UVW are moving, F is in units per minute in the UVW cartesian system, and all other axes (ABC) move so as to start and stop in coordinated fashion.
-
Otherwise, the move is pure rotary motion and the F word is in rotary units in the ABC pseudo-cartesian system.
2.6. Cooling
Flood or droplets cooling can be enabled separately. RS274/NGC language stops them together. See section about cooling control.
2.7. Dwell
A machining center may be commanded to dwell (i.e., keep all axes unmoving) for a specific amount of time. The most common use of dwell is to break and clear chips, so the spindle is usually turning during a dwell. Regardless of the Path Control Mode (see section Path Control) the machine will stop exactly at the end of the previous programmed move, as though it was in exact path mode.
2.8. Units
Units used for distances along the X, Y, and Z axes may be measured in millimeters or inches. Units for all other quantities involved in machine control cannot be changed. Different quantities use different specific units. Spindle speed is measured in revolutions per minute. The positions of rotational axes are measured in degrees. Feed rates are expressed in current length units per minute, or degrees per minute, or length units per spindle revolution, as described in section G93 G94 G95.
2.9. Current Position
The controlled point is always at some location called the current position, and the controller always knows where that is. The numbers representing the current position must be adjusted in the absence of any axis motion if any of several events take place:
-
Length units are changed.
-
Tool length offset is changed.
-
Coordinate system offsets are changed.
2.10. Selected Plane
There is always a selected plane, which must be the XY-plane, the YZ-plane, or the XZ-plane of the machining center. The Z-axis is, of course, perpendicular to the XY-plane, the X-axis to the YZ-plane, and the Y-axis to the XZ-plane.
2.11. Tool Carousel
Zero or one tool is assigned to each slot in the tool carousel.
2.12. Tool Change
A machining center may be commanded to change tools.
2.13. Pallet Shuttle
The two pallets may be exchanged by command.
2.14. Speed Override
The speed override buttons can be activated (they function normally) or rendered inoperative (they no longer have any effect). The RS274/NGC language has a command that activates all the buttons and another that disables them. See inhibition and activation speed correctors. See also here for further details.
2.15. Path Control Mode
El centro de mecanizado puede colocarse en cualquier modo de control de ruta entre estos tres:
- exact stop mode
-
In exact stop mode, the machine stops briefly at the end of each programmed move.
- exact path mode
-
In exact path mode, the machine follows the programmed path as exactly as possible, slowing or stopping if necessary at sharp corners of the path.
- continuous mode
-
In continuous mode, sharp corners of the path may be rounded slightly so that the feed rate may be kept up (but by no more than the tolerance, if specified).
3. Interpreter Interaction with Switches
The Interpreter interacts with several switches. This section describes the interactions in more detail. In no case does the Interpreter know what the setting of any of these switches is.
3.1. Cancelación de interruptores de avance y velocidad
The Interpreter will interpret RS274/NGC commands which enable M48 or disable M49 the feed and speed override switches. For certain moves, such as the traverse out of the end of a thread during a threading cycle, the switches are disabled automatically.
LinuxCNC reacts to the speed and feed override settings when these switches are enabled.
See the M48 M49 Override section for more information.
3.2. Block Delete Switch
If the block delete switch is on, lines of G-code which start with a slash (the block delete character) are not interpreted. If the switch is off, such lines are interpreted. Normally the block delete switch should be set before starting the NGC program.
3.3. Interruptor de parada de programa opcional
If this switch is on and an M1 code is encountered, program execution is paused.
4. Tool Table
A tool table is required to use the Interpreter. The file tells which tools are in which tool changer slots and what the size and type of each tool is. The name of the tool table is defined in the INI file:
[EMCIO] # tool table file TOOL_TABLE = tooltable.tbl
The default filename probably looks something like the above, but you may prefer to give your machine its own tool table, using the same name as your INI file, but with a tbl extension:
TOOL_TABLE = acme_300.tbl
o:
TOOL_TABLE = EMC-AXIS-SIM.tbl
For more information on the specifics of the tool table format, see the Tool Table Format section.
5. Parameters
In the RS274/NGC language view, a machining center maintains an array of numerical parameters defined by a system definition (RS274NGC_MAX_PARAMETERS). Many of them have specific uses especially in defining coordinate systems. The number of numerical parameters can increase as development adds support for new parameters. The parameter array persists over time, even if the machining center is powered down. LinuxCNC uses a parameter file to ensure persistence and gives the Interpreter the responsibility for maintaining the file. The Interpreter reads the file when it starts up, and writes the file when it exits.
All parameters are available for use in G-code programs.
The format of a parameter file is shown in the following table. The file consists of any number of header lines, followed by one blank line, followed by any number of lines of data. The Interpreter skips over the header lines. It is important that there be exactly one blank line (with no spaces or tabs, even) before the data. The header line shown in the following table describes the data columns, so it is suggested (but not required) that that line always be included in the header.
El intérprete solo lee las dos primeras columnas de la tabla. La tercer columna, Comentario, no es leída por el intérprete.
Cada línea del archivo contiene el número de índice del parámetro en la primera columna y, en la segunda columna, el valor al que ese parámetro debe establecerse. El valor se representa como un numero flotante de doble precisión dentro del intérprete, pero el punto decimal no es obligatorio en el archivo. Todos los parámetros que se muestran en la siguiente tabla son parámetros requeridos y deben ser incluidos en cualquier archivo de parámetros, excepto cualquier parámetro que represente un valor de eje de rotación para un eje no utilizado, que puede omitirse. Se señalará un error si falta algún parámetro requerido. El archivo puede incluir cualquier otro parámetro, siempre que su número esté en el rango de 1 a 5400. Los números de los parámetros se deben organizar en orden ascendente; si no lo estan, se señalará un error. Cualquier parámetro incluido en el archivo leído por el intérprete se incluirá en el archivo que se escriba cuando se cierre. El archivo original se guarda como un archivo de copia de seguridad cuando se escribe el nuevo archivo. Los comentarios no se conservan cuando se escribe el archivo.
| Parameter Number | Parameter Value | Comment |
|---|---|---|
5161 |
0.0 |
G28 Home X |
5162 |
0.0 |
G28 Home Y |
See the Parameters section for more information.