The V5 Optical Sensor is a combination of ambient light, color, proximity and gesture sensor.
Colour information is available as RGB, hue and saturation or grayscale. Color detection works best when the object is closer than 100mm.
The proximity sensor measures reflected light intensity, and as such, the values will change with ambient light and object reflectivity. The gesture sensor can detect one of four possible gestures, an object (hand or otherwise) moving up, down, left or right over the sensor.
The Optical Sensor has a white LED to assist color detection in low light conditions.