G84 tap cycle is one of the mostly used function of CNC machining centers.
This G84 tapping cycle example program illustrates the use of tapping in an easy to understand way.
G84 tapping cycle is a modal G-code, so is cancelled with G80 otherwise it will execute tap operation on every X and/or Y move.
G84 Tapping Cycle Format
G84 X_ Y_ Z_ R_ F_
X Y – Hole position data
Z – Z-depth (feed to Z-depth starting from R plane)
R – Position of the R plane
F – Cutting feedrate
A complete article about G84 read G84 Tapping Cycle – CNC Mill Programming
Another related article Deep Hole Tapping with Chipbreaking or Peck Tapping with G84
G84 Tapping Cycle Sample CNC Program
O100 (G84 R.H. Tapping Cycle) N1 T18 M06 N2 G90 G54 G00 X0.625 Y0.625 N3 S500 M03 N4 G43 H18 Z1. M08 N5 G84 G99 Z-0.65 R0.1 F35.7143 N6 X-0.625 Y-0.625 N7 G80 G00 Z1. M09 N8 G53 G49 Z0. M05 N9 M30