A photosensor comprises an emitter that emits light when a forward voltage is
applied
to a junction between semiconductor regions different in conduction type, wherein
the photosensor detects visible light from a current or a voltage from the emitter
based on the wavelength of the visible light applied to the emitter.