Principle of operation
The sensor contains 2 elements - an infrared LED that constantly emits light in the infrared range, and a photocell sensitive to infrared radiation. If there is a reflective surface near the sensor, some of the light emitted by the LED is returned to the photocell. The closer the surface and the "whiter" it is, the more light is returned to the receiver and the higher the sensor readings.