DYNAMIC OFFSETTING II: G54.2P0, G54.2P1 - G54.2P8 (M640M 5X) 25 25 DYNAMIC OFFSETTING II: G54.2P0, G54.2P1 - G54.2P8 (M640M 5X) 1. Function and purpose When a workpiece fixed on the turntable is to be machined with the rotation of the table, mismatching between the workpiece reference position (program origin) and the origin of workpiece coordinates (center of rotation of the table) leads to an error in machining contour. Provided that the vector of a particular deviation from the center of rotation to the workpiece reference position is given as a “reference”, the “Dynamic Offsetting II” function will calculate for each command of rotation the deviation vector for the designated angular motion in order to control the linear axes for an adequate movement to the ending point as programmed with respect to the ideal workpiece origin, and thus to prevent the above-mentioned faulty machining from occurring. 2. Programming format G54.2 Pn; n: Dynamic offset number (1 to Give a “G54.2 P0” command (n = 0) to cancel the dynamic offsetting function. 8) Cancellation is the initial state of the function (upon turning-on). 3. Definitions of terms A. Deviation vector The vector of a deviation from the center of rotation of the table (Wo: presupposed position of the workpiece origin) to the actual origin of coordinates of the workpiece mounted on the table. B. Dynamic offset The offsetting vector (= deviation vector; whose direction depends upon the angular position of the table) for the ending point of each block containing a command of rotation. C. Reference dynamic offset A particular deviation vector entered as the reference for the calculation of dynamic offsets. Consists of the vector proper (measured and entered in three-axis component vectors) and the positions (in machine coordinates) of the A- and C-axis for the measurement. 25-1 25 DYNAMIC OFFSETTING II: G54.2P0, G54.2P1 - G54.2P8 (M640M 5X) 4. Operation description A. Operation by a command of rotation in the G54.2 mode In the G54.2 mode (modal group 23), which is selected by a “G54.2Pn” command, deviation vector (to be used in a vector addition for offsetting) is re-calculated for each command of table rotation beforehand in order to create an adequate tool path for the block’s ending point as programmed with respect to the ideal workpiece origin. Mounted here. Work offset (e.g. G54) Machine zero point D735S1101 [Legend] W1: W1’: W2’: W2: Wo: Gs: G: a (a1, a1’): b (b1, b2’): The ideal workpiece mounting position (the workpiece origin set on to the center of rotation of the table) The actual workpiece mounting position (vector Gs denotes the deviation from the ideal position) The position of the actual workpiece W1’ after a table rotation by q The position of the ideally mounted workpiece W1 after a table rotation by q The origin of workpiece coordinates (given by a corresponding preparatory function, such as G54) The reference deviation vector (to be registered in the NC unit as a reference dynamic offset.) The deviation vector for the rotation of the rotational axis by q The starting point of the G1 (linear interpolation) microsegment command The ending point of the G1 (linear interpolation) microsegment command With the measurement results of the reference dynamic offset (Gs) registered for workpiece W fixed on the turntable, the selection (activation) of the G54.2 mode causes the tool to be shifted by the deviation vector Gs from the current position, point a1 for example, to point a1’ (if bit 0 of the F87 parameter described later is set to “0”). A succeeding command of “G1b1” (b1 = designation of a point with X-, Y-, and Z-coordinates) feeds the tool from a1’ to b1’ in the G1 mode (linearly). If, however, simultaneous motion of the rotational axis is designated in the same block, “G1b1Cq” for example, the tool is also fed linearly from the current position a1’ to the offset position b2’ which is obtained by adding the deviation vector G internally calculated for the q rotation to point b2, the ending point on the ideally mounted workpiece. 25-2 DYNAMIC OFFSETTING II: G54.2P0, G54.2P1 - G54.2P8 (M640M 5X) B. 25 On-reset operation When the system is reset, the dynamic offsetting mode is normally canceled. It depends, however, on the setting of parameter F95 bit 7 whether or not dynamic offsetting is canceled on system reset operations. F95 bit 7 = 0: The dynamic offset is cleared and the G54.2 mode is also canceled. = 1: The existing dynamic offset is held along with the G54.2 mode. When the automatic operation is started again after resetting, the dynamic offsetting mode is active from the beginning of the program. Note: C. When the dynamic offset is cleared by resetting, the tool will not move on the path corresponding to the cleared vector (even if bit 0 of the F87 parameter described later is set to “0”). Operation by the selection and cancellation of the G54.2 mode When a G54.2Pn command is given, the deviation vector for the current position of the rotational axis is calculated and an offsetting movement is carried out on the linear axes by their respective components of the computed vector (dynamic offset). If an axis motion command is given in the same block, the deviation vector for the ending point of that block is calculated and the corresponding motion is performed from the current point to the dynamically offset ending point. The cancellation command (G54.2P0) moves the tool by a vector reverse to the current dynamic offset. If an axis motion command is given in the same block, the corresponding motion is performed from the current point to the ending point as designated with workpiece coordinates (a movement including the cancellation of the dynamic offsetting). The axis motion occurs according to the current modal function concerned (of G-code group 1). D. Manual interruption in the G54.2 mode The deviation vector does not change if automatic operation is stopped in the G54.2 mode (by single-block stop, etc.) and then a movement on the rotational axis carried out in manual mode. The re-calculation of the deviation vector for dynamic offsetting will not occur until a rotational axis motion command or another G54.2 command is given after setting the MDI or automatic operation mode. 5. Input and output of the reference dynamic offset A. Setting the reference dynamic offset by G10 G10 L21 Pn Xx Yy........... aa ; Use this format of programmed parameter input. Argument P (n) denotes a dynamic offset number (1 to 8). According to the data input mode, absolute (G90) or incremental (G91), the designated axis value overwrites, or is added to, the current one. B. Reading/writing the reference dynamic offset with system variables System variable number = 5500 + 20 × n + m n: Dynamic offset m: Axis number (1 to 6) number (1 Use system variable #5510 to read the selected dynamic offset number (1 to 8). 25-3 to 8) 25 DYNAMIC OFFSETTING II: G54.2P0, G54.2P1 - G54.2P8 (M640M 5X) C. Reading the machine coordinates of the center of table rotation with system variables #5141: X-coordinate of the center of table rotation (Machine parameter S5 X) #5142: Y-coordinate of the center of table rotation (Machine parameter S5 Y) 6. Other detailed precautions 1. When the related parameters and reference dynamic offset are modified in the G54.2 mode, the modifications will become valid for the next G54.2Pn command onward. 2. The following describes how some specific commands are executed in the G54.2 mode. (a) Machine coordinate system selection (G53) A G53 command temporarily suppresses the dynamic offset and the axis motion is performed to the ending point as designated in machine coordinates. The deviation vector is not re-calculated even when a value for the rotational axis is specified. The dynamic offsetting function will not be recovered until a motion command is given with workpiece coordinates. (b) Workpiece coordinate system change (G54 to G59, G54.1, G92, G52) Even when the workpiece coordinate system is changed in the G54.2 mode, the reference dynamic offset is not re-calculated and dynamic offsets are calculated according to the existing reference dynamic offset. The axis motion is carried out to the position obtained by adding the deviation vector to the ending point specified in the new workpiece coordinate system. (c) Commands related to zero point return (G27, G28, G29, G30, G30.n) The dynamic offsetting function is temporarily canceled for the path from the intermediate point to the reference point and recovered for the movement from there to a position specified in the workpiece coordinate system. (Similar to the processing of the commands related to zero point return in the tool length offset mode) 3. When the work offset data (workpiece origin) being used is modified by a G10 command in the G54.2 mode, the new work offset data will be valid for the next block onward. 4. As for the tool motion caused by a change only in the deviation vector, it is executed in the current mode of G-code group 1 and at the current rate of feed. If, however, the mode concerned is other than that of G0 or G1, e.g. a mode of circular interpolation (G2, G3, etc.), the tool is temporarily moved in the mode of linear interpolation (G1). 5. The type of the control axis for the turntable (C-axis) must be specified as “rotational”. The dynamic offsetting function II cannot be used for the C-axis specified as “linear type”. 6. The polar coordinate interpolation with the rotational axis (A- or C-axis) cannot be executed properly in the G54.2 mode. 7. The following function commands cannot be executed in the G54.2 mode: - Restarting the program - Mirror image (by G51.1 or control signal) - Scaling (G51) - Figure rotation (M98) - Coordinates rotation (G68) - G61.1, G5P0, G5P2 8. The workpiece coordinates read with system variables include dynamic offsets. 9. The component vectors of the current dynamic offset can be read using system variables #5121 (X-axis), #5122 (Y-axis) and #5123 (Z-axis). 25-4 DYNAMIC OFFSETTING II: G54.2P0, G54.2P1 - G54.2P8 (M640M 5X) 7. 25 Related alarms 936 OPTION NOT The dynamic offset II option is not installed. FOUND 959 WPC 0 POINT MISMATCH The origin of workpiece coordinates does not match the center of rotation of the turntable. 807 ILLEGAL FORMAT Argument P is missing in the block of G54.2. An incompatible G-code is used in the G54.2 mode or G54.2 is given in the mode of an incompatible G-code. 809 ILLEGAL NUMBER The value of P in the block of G54.2 is not proper. 8. INPUT Related parameters A. Rotational axis configuration Specify the type of rotational axis configuration of the machine to be operated. L81 = 0: = 1: = 2: = 3: Makes the dynamic Two rotational axes One rotational One rotational axis (C-axis) offsetting (C-axis axis function on invalid. A-axis) (A-axis) Specify “1” for the VARIAXIS 630. B. Dynamic offset type Specify whether or not the tool is to be offset by each change only in the deviation vector. F87 bit 0 = 0: Offset (the indication of both workpiece and machine coordinates changes.) = 1: Not offset (no change in the position indication at all) Normally set this parameter to “0”. C. Center of table rotation Specify the center of rotation of the table in machine coordinates. These parameters are also used in the Variaxis control for MAZATROL programs. The preset values refer to the factory adjustment at Mazak. S5 X, Y S12 Y, Z S11 Z D. Center of rotation of the turntable (Machine coordinates) Axis of rotation of the tilting table (Machine coordinates) Distance (length) from the tilting axis to the turntable surface (The turntable center must be in the direction of –Z from the tilting axis.) Workpiece origin mismatch check The origin of the selected workpiece coordinate system must correspond to the center of table rotation in order that the dynamic offsetting may effectively function. The following parameter is provided to check the condition in question for each G54.2 command. F87 bit 1 = 0: The mismatch check is conducted. = 1: The mismatch check is not conducted. Normally set this parameter to “0”. 25-5 25 DYNAMIC OFFSETTING II: G54.2P0, G54.2P1 - G54.2P8 (M640M 5X) 9. Mechanical requirements The dynamic offsetting function requires the following conditions to be satisfied: 1. The machine is equipped with a table of either two-axis rotational control (construction of a turntable on the tilting axis) or of a single rotational axis control (turntable or tilting table). The tilting and rotational axis must refer to rotating around the X- and Z-axis, respectively. Moreover, the construction must not be of the tilting axis mounted on the turntable. 2. The workpiece coordinate origin corresponds to the center of table rotation, and the X-, Y-, and Z-axes of workpiece coordinates are in parallell with, and the same direction as, the corresponding axes of machine coordinates. 3. The requirements for machining with table rotation: The machining contour is described using a workpiece coordinate system fixed in parallel with the machine coordinate system (not rotated with the table rotation) and microsegment command blocks of G1. 10. Operation description using a sample program The following describes the operation using a sample program (created for explanation only). A. Settings on the related displays WORK OFFSET (G54) X = –315.0, Y = –315.0, Z = 0.0, A = 0.0, C = 0.0 DYNAMIC OFFSET (P1) X = –1.0, Parameters B. Y=0.0, Z = 0.0, A = 0.0, C = 90.0 L81 = 1 (Rotational axis configuration: Two rotational axes; C-axis on A-axis) F87 bit 0 = 0 (Dynamic offset type: Offset) S5 X = –315000 S5 Y = –315000 Sample program (for explanation of operation) N1 G91 G28 X0 Y0 Z0 A0 C0 N2 G54 N3 G90 G00 X0 Y0 Z0 A0 C0 N4 G54.2P1 N5 G01 C180.0 F1000 N6 G01 X10.0 N7 G03 X0 Y10.0 R10.0 N8 G01 C240.0 C. Position indication and dynamic offset for each line of the program N-No. N1 N2 POSITION (workpiece coordinates) MACHINE (machine coordinates) Dynamic offset X Y Z A C X Y Z A C X Y Z 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 315.000 315.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 –315.000 –315.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 N3 0.000 0.000 0.000 0.000 N4 0.000 –1.000 0.000 0.000 0.000 0.000 –316.000 0.000 0.000 0.000 –1.000 0.000 N5 0.000 1.000 0.000 0.000 180.000 0.000 –314.000 0.000 0.000 180.000 0.000 1.000 0.000 N6 10.000 1.000 0.000 0.000 180.000 –305.000 –314.000 0.000 0.000 180.000 0.000 1.000 0.000 N7 0.000 11.000 0.000 0.000 180.000 –315.000 –304.000 0.000 0.000 180.000 0.000 1.000 0.000 N8 0.866 10.500 0.000 0.000 240.000 –314.134 –325.500 0.000 0.000 240.000 0.866 0.500 0.000 25-6 DYNAMIC OFFSETTING II: G54.2P0, G54.2P1 - G54.2P8 (M640M 5X) D. 25 Illustration of the sample program Measurement of the reference dynamic offset Let the position where the l mark on the table is aligned with the fixed position marked with ¡ be the zero point of the C-axis. The reference dynamic offset (arrow) = (–1, 0, 0) was measured with the table positioned at C = 90.0, as shown on the left. Workpiece Turntable (C-axis) N-No. N3 1 N4 2 N5 3 Illustration N-No. N6, N7 4 N8 N5 5 Illustration <Explanation> 1. N3 turns the table on the C-axis to l (C = 0) and positions the tool tip to the × point (X, Y, Z = 0, 0, 0). 2. N4 causes the tool tip to be shifted by the dynamic offset (arrow) for an angular position of C = 0 to the × point (X, Y, Z = 0, –1, 0). 3. N5 turns the table on the C-axis to l (C = 180) and causes the tool tip to be shifted by linear interpolation to the × point (X, Y, Z = 0, 1, 0) determined by the dynamic offset (arrow) for an angular position of C = 180. 4. N6 and N7 interpolate the linear and circular paths to the × point. 5. N8 turns the table on the C-axis to l and causes the tool tip to be shifted by linear interpolation to the × point. 25-7 25 DYNAMIC OFFSETTING II: G54.2P0, G54.2P1 - G54.2P8 (M640M 5X) - NOTE - 25-8 E