1.  Field of the Invention
The present invention relates to determining a flying height of a head in a hard disk drive. 
2.  Background Information
Hard disk drives contain a plurality of magnetic heads that are coupled to rotating disks.  The heads write and read information by magnetizing and sensing the magnetic fields of the disk surfaces.  Each head is attached to a flexure arm to create a subassembly commonly referred to as a head gimbal assembly (“HGA”).  The HGA's are suspended from an actuator arm.  The actuator arm has a voice coil motor that can move the heads across the surfaces of the disks. 
HGA transducers include three primary elements: a reader sensor, a writer structure and a head protrusion control element, also known as fly-on-demand (“FOD”).  The reader sensor is commonly made of a spinning tunneling MR structure.  The writer structure includes coils and magnetic flux path structure made with high permeability and high magnetization material.  The head protrusion control element (FOD device) is typically constructed of a header coil.  When a current is applied, the coil generates heat and causes the writer and reader elements to move closer to the media.  The FOD device is used to dynamically set writer spacing and reader spacing to the disk surface during the operation of the disk drive.  The calibration of such spacing is first done during an initialization process of the drive.  The initialization process involves measuring head spacing changes while the reader is moved closer to the disk with activation of the FOD device.  The FOD device moves the reader and writer closer to the disk until the H/M contact signal is detected.  The FOD device can be set to put the writer and the reader at desirable spacing when the head/media (“H/M”) contact point is the spacing reference (h=0). 
During operation, each head is separated from a corresponding disk surface by an air bearing.  The air bearing eliminates mechanical interference between the head and the disks.  The FOD device is used to further set reader and writer positions above the disk surface, based on the pre-calibrated target.  The strength of the magnetic field from the disk is inversely proportional (restrictly in a nonlinear fashion) to the height of the reader head spacing to the disk.  Reduced spacing results in a stronger magnetic field on the disk, and vice versa. 
The flying height of head (specially the flying height of the reader and writer) may vary during the operation of the drive.  For example, a shock load on the drive may create a vibration that causes the heads to mechanically resonate.  The vibration causes the heads to move toward and then away from the disk surfaces in an oscillating manner.  Particles or scratch ridges in the disk may also cause oscillating movement of the heads.  The oscillating movement may occur in either a vertical or in-plane direction relative to the flexure arm.  Environment changes, such as temperature and altitude can also cause a change in the head flying height. 
If oscillation of the heads occurs during a write routine of the drive, the resultant magnetic field from the writer on the disk will vary inversely relative to the flying height of the writer.  The varying magnetic field strength may result in poor writing of data.  Errors will occur when the signal is read back by the drive. 
Knowing and controlling the flying heights of the heads is the critical for both disk drive reliability and data integrity.  With the introduction of FOD technology, the disk drive can dynamically control head flying height.  To accurately operate the FOD device and achieve the desirable writer and reader spacings to the disk, flying height measurement technique are developed.  The most common technique is to use playback signal components in frequency domain, as shown as an example in the following file. 
The FOD device can be used to adjust head flying height in real time.  The relative flying change for a given FOD device condition can be accurately characterized.  If the head flying height relative to a desirable target can be measured, the offset can then be compensated by proper fine tuning of the FOD device setting (adjust either current or voltage).  The spacing error signal (SES) of a head is defined as an indicator of a spacing offset between an actual head position to a desirable head position.  The concept of SES is very similar to a position error signal (“PES”) of a disk drive servo system.  One can view SES as the PES of head in the direction perpendicular to the disk surface. 
There are various methods for creating spacing error signals (“SES”) that are used to control the flying height through feedback schemes.  Practical construction of spacing error signals (“SES”) is limited by available electrical/mechanical signals and disk drive hardware capability.  One type of SES is to use servo automatic gain control (“AGC”) signal where a signal (AGC) embedded into a dedicated field of a servo sector is read and used to calculate SES in accordance with an AGC process.  Servo AGC SES is susceptible to changes with temperature and may provide different results depending on whether the head is at the inner diameter or the outer diameter of the disk.  There are also schemes to utilize an AGC that reads data from a data field of the track sector.  Data AGC schemes are also susceptible to variations because of temperature.  Finally, SESs can be generated by analyzing the 1st and 3rd harmonics, or ratio of harmonics, from an embedded signal(s) in a dedicated track.  Such an approach requires a dedicated track that will reduce the data capacity of the drive.  It would be desirable to generate and use SESs without the deficiencies noted for prior art schemes.  The following table summarizes the existing schemes that are available for SES calculations:
TypeMechanismPro/ConsServoAGCAvailable nowChange with TemperatureAGCchangesMultiple samplesID to OD kfci changesas H/MAny whereVery large variationsspacingchangesDataAGCAvailable nowChange with TemperatureAGCchangesMultiple samplesData dependentwith H/MOn data regionspacingHarmonicHarmonic orAvailable nowOnly work on dedicated(1st/3rd)ratio ofUse resolutiontracksharmonicchange withH/M spacing