The detection method according to the detection mechanism shown in FIG. 21 is a method for detecting the quantity of the displacement by detecting a light beam emitted from a light source 26 such as a semiconductor light emitting device (LED) or a semiconductor laser (LD) with a light receiving element 28.