EPR works by letting the sample undergo different orientations of the external magnetic field. The sample will thus be measured multiple times, each time with a different orientation of the magnetic field (by using a rotating support). Then it is each time radiated by an appropriated microwave frequency. From the peaks of these spectra, the g factors can be calculated.