G10 L2 sets the origin of a numbered coordinate system in LinuxCNC by writing axis offsets measured from the machine origin established during homing. The P word selects the coordinate system (0 to 9) and the axis words give the new offset values, which replace existing offsets for the axes named; optional R sets rotation of the XY axes about Z. It only writes the offsets and does not switch the active coordinate system.
| Language | gcode |
|---|---|
| Code | G10 L2 |
| Group | coordinate system |
| Syntax | G10 L2 P- <axes R-> |
| Dialect | LinuxCNC |
| Name | Data type | Description |
|---|---|---|
| P | integer | Coordinate system (0-9). P0 is the active system; P1-P9 correspond to G54-G59.3. |
| axes | Axis words (X Y Z A B C U V W) giving the offset of the origin from the machine origin. Axis words not used are not changed. | |
| R | Optional rotation of the XY axis around the Z axis; direction is CCW as viewed from the positive end of the Z axis. |