A medium processing device is provided having a front panel which is
formed with an aperture where a magnetic recording medium is inserted
into or ejected from and which partitions an outside of a device from an
inside of the device. A magnetic head is provided in the inside of the
device for writing or reading information in or from the magnetic
recording medium a shading filter is provided in at least one part of the
front panel for shading visible light and a foreign matter detecting
mechanism is provided on an inner side of the device with respect to the
shading filter for detecting a foreign matter that is attached to the
outside of the device.