Describe the difference between absolute and incremental positioning in G-code.
In absolute positioning, the coordinates given in the G-code commands are based on a fixed point on the machine, usually the machine's origin or zero point. In incremental positioning, the coordinates are relative to the current position of the tool.
How would you use G-code to perform a tool change?
A tool change can be performed using the M06 command followed by the T command with the number of the desired tool. For example, 'M06 T3' would change to tool number 3.
What are some common errors you might encounter when writing G-code and how would you troubleshoot them?
Common errors include syntax errors, incorrect coordinates, and incorrect tool selection. Troubleshooting would involve carefully reviewing the G-code program, checking the syntax and coordinates, and ensuring the correct tool is selected.
Describe the difference between G90 and G91 commands.
G90 and G91 commands are used to set the positioning mode. G90 sets the mode to absolute positioning, while G91 sets it to incremental positioning.
How would you write a G-code program to create a circular hole?
Creating a circular hole would involve using a G81 drilling cycle command, followed by the X and Y coordinates for the center of the hole, and the Z coordinate for the depth of the hole.